Move most readwritesplit functions into classes

Most of the funtionality is now a member function of either the RWSplit or
RWSplitSession class. This removes the need to pass the router and session
parameters to all functions.
This commit is contained in:
Markus Mäkelä
2018-04-03 23:18:57 +03:00
parent ce500d782a
commit 15f15be49d
11 changed files with 360 additions and 470 deletions

View File

@ -12,7 +12,6 @@
*/
#include "rwsplitsession.hh"
#include "rwsplit_internal.hh"
#include "routeinfo.hh"
#include <cmath>
@ -69,8 +68,8 @@ RWSplitSession* RWSplitSession::create(RWSplit* router, MXS_SESSION* session)
SRWBackend master;
if (select_connect_backend_servers(router, session, backends, master,
NULL, NULL, connection_type::ALL))
if (router->select_connect_backend_servers(session, backends, master, NULL,
NULL, connection_type::ALL))
{
if ((rses = new RWSplitSession(router, session, backends, master)))
{