Add forcereset to SOAP Join AC Request for force reset session
This commit is contained in:
parent
90eaf9d41e
commit
89547e1b67
@ -27,7 +27,7 @@ struct ac_backend_t {
|
|||||||
static struct ac_backend_t g_ac_backend;
|
static struct ac_backend_t g_ac_backend;
|
||||||
|
|
||||||
/* */
|
/* */
|
||||||
static int ac_backend_soap_join(void) {
|
static int ac_backend_soap_join(int forcereset) {
|
||||||
int result = 0;
|
int result = 0;
|
||||||
struct ac_soap_request* request;
|
struct ac_soap_request* request;
|
||||||
struct ac_http_soap_server* server;
|
struct ac_http_soap_server* server;
|
||||||
@ -47,6 +47,7 @@ static int ac_backend_soap_join(void) {
|
|||||||
if (request) {
|
if (request) {
|
||||||
ac_soapclient_add_param(request, "xs:string", "acid", g_ac.backendacid);
|
ac_soapclient_add_param(request, "xs:string", "acid", g_ac.backendacid);
|
||||||
ac_soapclient_add_param(request, "xs:string", "version", g_ac.backendversion);
|
ac_soapclient_add_param(request, "xs:string", "version", g_ac.backendversion);
|
||||||
|
ac_soapclient_add_param(request, "xs:boolean", "forcereset", (forcereset ? "true" : "false"));
|
||||||
g_ac_backend.soaprequest = ac_soapclient_prepare_request(request, server);
|
g_ac_backend.soaprequest = ac_soapclient_prepare_request(request, server);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -137,10 +138,10 @@ static int ac_backend_soap_waitevent(void) {
|
|||||||
struct ac_soap_response* response = ac_soapclient_recv_response(g_ac_backend.soaprequest);
|
struct ac_soap_response* response = ac_soapclient_recv_response(g_ac_backend.soaprequest);
|
||||||
if (response) {
|
if (response) {
|
||||||
/* Wait event result */
|
/* Wait event result */
|
||||||
/*if ((response->responsecode == HTTP_RESULT_OK) && response->xmlResponseReturn) {
|
if ((response->responsecode == HTTP_RESULT_OK) && response->xmlResponseReturn) {
|
||||||
TODO
|
/* TODO */
|
||||||
}*/
|
result = 0;
|
||||||
result = 0;
|
}
|
||||||
|
|
||||||
/* */
|
/* */
|
||||||
ac_soapclient_free_response(response);
|
ac_soapclient_free_response(response);
|
||||||
@ -217,6 +218,7 @@ static void ac_backend_soap_leave(void) {
|
|||||||
static void ac_backend_run(void) {
|
static void ac_backend_run(void) {
|
||||||
int result;
|
int result;
|
||||||
int connected = 0;
|
int connected = 0;
|
||||||
|
int forcereset = 1;
|
||||||
|
|
||||||
capwap_lock_enter(&g_ac_backend.backendlock);
|
capwap_lock_enter(&g_ac_backend.backendlock);
|
||||||
|
|
||||||
@ -242,11 +244,12 @@ static void ac_backend_run(void) {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
/* Join with a Backend Server */
|
/* Join with a Backend Server */
|
||||||
if (ac_backend_soap_join()) {
|
if (ac_backend_soap_join(forcereset)) {
|
||||||
capwap_logging_debug("Joined with Backend Server");
|
capwap_logging_debug("Joined with Backend Server");
|
||||||
|
|
||||||
/* Join Complete */
|
/* Join Complete */
|
||||||
connected = 1;
|
connected = 1;
|
||||||
|
forcereset = 0;
|
||||||
g_ac_backend.backendstatus = 1;
|
g_ac_backend.backendstatus = 1;
|
||||||
g_ac_backend.errorjoinbackend = 0;
|
g_ac_backend.errorjoinbackend = 0;
|
||||||
capwap_lock_exit(&g_ac_backend.backendlock);
|
capwap_lock_exit(&g_ac_backend.backendlock);
|
||||||
@ -260,6 +263,7 @@ static void ac_backend_run(void) {
|
|||||||
capwap_logging_debug("Unable to join with Backend Server");
|
capwap_logging_debug("Unable to join with Backend Server");
|
||||||
|
|
||||||
/* */
|
/* */
|
||||||
|
forcereset = 1;
|
||||||
g_ac_backend.backendstatus = 0;
|
g_ac_backend.backendstatus = 0;
|
||||||
g_ac_backend.errorjoinbackend = 0;
|
g_ac_backend.errorjoinbackend = 0;
|
||||||
|
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
<wsdl:message name="joinBackend">
|
<wsdl:message name="joinBackend">
|
||||||
<wsdl:part name="acid" type="xs:string"/>
|
<wsdl:part name="acid" type="xs:string"/>
|
||||||
<wsdl:part name="version" type="xs:string"/>
|
<wsdl:part name="version" type="xs:string"/>
|
||||||
|
<wsdl:part name="forcereset" type="xs:boolean"/>
|
||||||
</wsdl:message>
|
</wsdl:message>
|
||||||
<wsdl:message name="joinBackendResponse">
|
<wsdl:message name="joinBackendResponse">
|
||||||
<wsdl:part name="return" type="xs:string"/>
|
<wsdl:part name="return" type="xs:string"/>
|
||||||
@ -18,7 +19,9 @@
|
|||||||
<wsdl:message name="waitBackendEvent">
|
<wsdl:message name="waitBackendEvent">
|
||||||
<wsdl:part name="sessionid" type="xs:string"/>
|
<wsdl:part name="sessionid" type="xs:string"/>
|
||||||
</wsdl:message>
|
</wsdl:message>
|
||||||
<wsdl:message name="waitBackendEventResponse"/>
|
<wsdl:message name="waitBackendEventResponse">
|
||||||
|
<wsdl:part name="return" type="xs:string"/>
|
||||||
|
</wsdl:message>
|
||||||
<wsdl:message name="authorizeJoin">
|
<wsdl:message name="authorizeJoin">
|
||||||
<wsdl:part name="sessionid" type="xs:string"/>
|
<wsdl:part name="sessionid" type="xs:string"/>
|
||||||
<wsdl:part name="wtpid" type="xs:string"/>
|
<wsdl:part name="wtpid" type="xs:string"/>
|
||||||
|
Loading…
Reference in New Issue
Block a user