Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I notice that if I run the server with the odoo.py, using the workers parameter, I also get an additional process using the openerp-gevent script with runs at port 8072.
A couple of questions:
1. Can I change the gevent port number? If I want to run several instances of odoo in one server, they are going to try to use the same port for gevent.
2. Do I use the gevent port for users? If I do so, do this gevent process uses the other processes? The main question is, how can I use the live chat and maintain multi-process capability for my users?
I found the answer and I didn't want to let the question unanswered, so here it is:
You start the server with --workers > 0 (depending on your hardware), so you have that many threads on port 8069. You will also have a couple of cron threads on 8069 (configurable with --max-cron-threads) and one gevent thread on port 8072 (configurable with --longpolling-port).
You have to setup a reverse proxy (apache2 or nginx will do the job), and map your 8069 port to the external 80.
Here is the important part: you also have to reverse proxy your 8072 port to the external 80, but only for location /longpolling (in nginx this is done with a second location).
That way you have your users using the workers normally and the gevent thread only for getting the bus messages.
I will post soon a complete installation and configuration guide for v8.0 with all the details usually missing in available guides.
My question is even when I set worker > 0, there no gevent process listen to 8072.
And I found in source code only one line will use longpolling_port, which is in the __init__() of GeventServer, and only when the odoo is configured to user gevent server, the GeventServer will be constructed instead of PreforkServer.
So I am totally confused, which port will be used for longpolling under multiprocess mode?