答复: unit statistics

Zhidao HONG z.hong at f5.com
Fri Sep 23 09:06:17 UTC 2022


Hi Tobias,

We are working on it and we have found the cause of the issue.
Likely, we will create an issue on GitHub and share the fixing patch next week.

Thanks for your report.

发件人: Tobias Genannt <tobias.genannt at kappa-velorum.net>
日期: 星期三, 2022年9月21日 01:17
收件人: unit at nginx.org <unit at nginx.org>
主题: unit statistics
EXTERNAL MAIL: unit-bounces at nginx.org

Hello,

I was just testing the new statistics feature, which looks really nice.
I'm using Unit inside a docker container and the configuration API
should only be visible inside the container, but I would like to see the
statistics from the outside. So to solve the problem I added a route
like this:

{
     "match": {
         "uri": "/status/*"
     },

     "action": {
         "proxy": "http://unix:/opt/unit/unit.sock"
     }
}

This works as expected but now all calls to the /status/ will change the
stats. So it would be nice if the stats could be disabled for a route or
if this is not possible for a listener.

I also noticed that my connections object looks like this:
connections": {
     "accepted": 8,
     "active": -41,
     "idle": 0,
     "closed": 49
}

Notice the negative number for "active". For reference the complete
configuration is this:
https://nam02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnetbox-community%2Fnetbox-docker%2Fblob%2Frelease%2Fdocker%2Fnginx-unit.json&data=05%7C01%7Cz.hong%40f5.com%7C7fe304e29c694284951408da9b2c08e4%7Cdd3dfd2f6a3b40d19be0bf8327d81c50%7C0%7C0%7C637992910721327110%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=%2BEAQVO1v1rCLMK5duflAswy0Y8l4wQLMaiWOSY6OIzA%3D&reserved=0
+ the additional route as seen above.


Greetings,
Tobias
_______________________________________________
unit mailing list -- unit at nginx.org
To unsubscribe send an email to unit-leave at nginx.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/unit/attachments/20220923/17d16d03/attachment.htm>


More information about the unit mailing list