{"action":"created","issue":{"url":"https://api.github.com/repos/wandenberg/nginx-push-stream-module/issues/110","labels_url":"https://api.github.com/repos/wandenberg/nginx-push-stream-module/issues/110/labels{/name}","comments_url":"https://api.github.com/repos/wandenberg/nginx-push-stream-module/issues/110/comments","events_url":"https://api.github.com/repos/wandenberg/nginx-push-stream-module/issues/110/events","html_url":"https://github.com/wandenberg/nginx-push-stream-module/issues/110","id":22394494,"number":110,"title":"Send multiple different messages to multiple subscribers","user":{"login":"5lava","id":63829,"avatar_url":"https://avatars.githubusercontent.com/u/63829?v=3","gravatar_id":"","url":"https://api.github.com/users/5lava","html_url":"https://github.com/5lava","followers_url":"https://api.github.com/users/5lava/followers","following_url":"https://api.github.com/users/5lava/following{/other_user}","gists_url":"https://api.github.com/users/5lava/gists{/gist_id}","starred_url":"https://api.github.com/users/5lava/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/5lava/subscriptions","organizations_url":"https://api.github.com/users/5lava/orgs","repos_url":"https://api.github.com/users/5lava/repos","events_url":"https://api.github.com/users/5lava/events{/privacy}","received_events_url":"https://api.github.com/users/5lava/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2013-11-09T21:46:49Z","updated_at":"2015-07-11T21:41:13Z","closed_at":"2015-07-11T21:41:13Z","body":"**push_stream_channels_path** allows to send a message to multiple subscribers, which is undoubtedly awesome. But it also would be very convenient and efficient to be able to send multiple _different_ messages to multiple subscribers in one request.\r\n\r\nMy suggestion is to split POST data to multiple messages, that can be done by specifying message lengths (syntactically similarly to how **push_stream_channels_path** allows to specify number of backtrack messages). For example, to send 3 messages we would specify 3 channel ids and 3 message lengths:\r\n`/channel1.L50/channel2.L20/channel3.L100`\r\n(actually, specifying a length of last message is unnecessary, it's always a tail of POST data).\r\n\r\nFor example:\r\npush_stream_channels_path: `/channel1.L3/channel2.L5/channel3.L1`\r\nPOST data: `aaabbbbbc`\r\nExpected messages to be sent: `aaa` to channel1, `bbbbb` to channel2, `c` to channel3.\r\n\r\nThank you."},"comment":{"url":"https://api.github.com/repos/wandenberg/nginx-push-stream-module/issues/comments/120663035","html_url":"https://github.com/wandenberg/nginx-push-stream-module/issues/110#issuecomment-120663035","issue_url":"https://api.github.com/repos/wandenberg/nginx-push-stream-module/issues/110","id":120663035,"user":{"login":"wandenberg","id":89909,"avatar_url":"https://avatars.githubusercontent.com/u/89909?v=3","gravatar_id":"","url":"https://api.github.com/users/wandenberg","html_url":"https://github.com/wandenberg","followers_url":"https://api.github.com/users/wandenberg/followers","following_url":"https://api.github.com/users/wandenberg/following{/other_user}","gists_url":"https://api.github.com/users/wandenberg/gists{/gist_id}","starred_url":"https://api.github.com/users/wandenberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wandenberg/subscriptions","organizations_url":"https://api.github.com/users/wandenberg/orgs","repos_url":"https://api.github.com/users/wandenberg/repos","events_url":"https://api.github.com/users/wandenberg/events{/privacy}","received_events_url":"https://api.github.com/users/wandenberg/received_events","type":"User","site_admin":false},"created_at":"2015-07-11T21:41:13Z","updated_at":"2015-07-11T21:41:13Z","body":"This kind of thing adds a big complexity to develop and to use the module. And also is not suitable to the majority.\r\nIs better to keep the way messages are published.\r\nYou can use keep alive connections to have a better performance while publishing messages."}}