In order to know whether or not the websocket session is up to date, the session is saved when opening a websocket connection. Then, for each incoming/outgoing message, we check if the session still exists on the file system. When it does not exist anymore, the websocket connection is refreshed. This ensures the session is always up to date. Odoo sh proxies the websocket connection and needs a way to tell when a websocket session is expired. This commit adds the same check that is done for each incoming websocket message in the websocket peek route in order to raise a `SessionExpiredException` when the session is outdated. This will allow odoo sh to catch this error and to refresh their websocket connection accordingly. closes odoo/odoo#100416 Signed-off-by: Julien Castiaux <juc@odoo.com>
8 lines
231 B
Python
8 lines
231 B
Python
from . import common
|
|
from . import test_assetsbundle
|
|
from . import test_health
|
|
from . import test_ir_websocket
|
|
from . import test_websocket_caryall
|
|
from . import test_websocket_controller
|
|
from . import test_websocket_rate_limiting
|