MXS-2196: Split session startup into two parts
The session allocation now has two distinct parts: the initialization of the session itself and the creation of the router and filter sessions. This allows sessions to be allocated the moment a client DCB is created instead of only after the authentication is complete. With this change, the need for the dummy session is removed.
This commit is contained in:
@ -303,6 +303,19 @@ MXS_SESSION* session_alloc(SERVICE*, DCB*);
|
||||
*/
|
||||
MXS_SESSION* session_alloc_with_id(SERVICE*, DCB*, uint64_t);
|
||||
|
||||
/**
|
||||
* Start the session
|
||||
*
|
||||
* Called after the session is initialized and authentication is complete. This creates the router and filter
|
||||
* sessions.
|
||||
*
|
||||
* @param session Session to start
|
||||
* @param service The service where the session is started
|
||||
*
|
||||
* @return True if session was started successfully
|
||||
*/
|
||||
bool session_start(MXS_SESSION* session, SERVICE* service);
|
||||
|
||||
MXS_SESSION* session_set_dummy(DCB*);
|
||||
|
||||
static inline bool session_is_dummy(MXS_SESSION* session)
|
||||
|
||||
Reference in New Issue
Block a user