wandenberg / nginx-push-stream-module

A pure stream http push technology for your Nginx setup. Comet made easy and really scalable.
Other
2.22k stars 295 forks source link

push_stream_channels_statistics 404 #242

Closed maksym-iv closed 8 years ago

maksym-iv commented 8 years ago

Hello,

I've faced an issue with push_stream_channels_statistics and 404 error. All request returns 404 code with empty page.

HTTP/1.1 404 Not Found
Cache-Control: no-cache, no-store, must-revalidate
Connection: keep-alive
Content-Length: 0
Date: Tue, 12 Jul 2016 10:28:00 GMT
Expires: Thu, 01 Jan 1970 00:00:01 GMT
Server: nginx
X-Nginx-PushStream-Commit: 5566c365977fbe4211b5c3757427b82604891a10
X-Nginx-PushStream-Tag: 0.5.0

versions:

config:

location /channels-stats {

        #auth_basic "closed website";
        #auth_basic_user_file /etc/nginx/passwd/htpasswd;
        # activate channels statistics mode for this location
        push_stream_channels_statistics;
        # query string based channel id
        set $push_stream_channel_id             $arg_id;
    }

Seems to be very strange, cause after publishing message to channel I see stats.

Can't figure out if it is my config mistake or bug in module.

wandenberg commented 8 years ago

@xmackex The stats for a specific channel is available only after the first message was published to it or the first client subscribe it. Before one of these two actions the channel does not exists, so a 404 is expected.

Seems also that you are using a very old configuration format or you remove some lines on your example. Take a look here and you will see that the channel id is set using the push_stream_channels_path directive.