Why the communication between alljoyn gateway management app and connector doesn't work ?

asked 2015-06-21 20:20:34 -0800

Jessica gravatar image

Hi, I traced the gateway management app and connector's source code and found that they communicate with each other by using below signal and method.

  • Signal : "MergedAclUpdated" and "ShutdownApp"
  • Method : "GetMergedAcl" and "UpdateConnectionStatus"

Question 1 : Why the connector doesn't receive the signal from gateway management app ? Are there any incorrect procedures in the below testing ?

For signal case (using ShutdownApp signal for example),

  1. Connector register "ShutdownApp" signal handler in the GatewayConnector::init() function.
  2. Gateway management app use the following steps to send the signal to connector : (a) In the AppBusObject::createAppConnectorInterface function, m_ShutdownApp = interfaceDescription->GetMember(AJ_SIGNAL_SHUTDOWN_APP.c_str()); (b) In the AppBusObject::SendShutdownAppSignal() function, qcc::String destination = AJ_GW_APP_WKN_PREFIX + m_ConnectorApp->getConnectorId(); status = Signal(destination.c_str(), 0, *m_ShutdownApp);

I add some logs in the "ShutdownApp" signal handler function in the connector and use "Signal" API to send "ShutdownApp" signal to the connector in the gateway management app. After running the test code, the management app send the signal to connector without error, but there are no logs be printed in the signal handler function. It means that connector doesn't receive the signal.

Question 2 : Why the gateway management app doesn't receive the method from connector ? Are there any incorrect procedures in the below testing ?

For method case (using "UpdateConnectionStatus" for example),

  1. Connector use the following steps to send method to the gateway management app: (a) In the GatewayConnector::initInterface function, Connector create one interface description and add "UpdateConnectionStatus" method. (b) Sending "UpdateConnectionStatus" method by using "myApp.updateConnectionStatus" API
  2. Gateway management app add one "UpdateConnectionStatus" method handler in the AppBusObject::createAppConnectorInterface function.

I add some logs in the "UpdateConnectionStatus" method handler function in the gateway management app and use "myApp.updateConnectionStatus" API to send "UpdateConnectionStatus" method to the management app in the connector. After running the test code, the connector send the method to management app without error, but there are no logs be printed in the method handler function. It means that management app doesn't receive the method.

Thanks ! Jessica

edit retag flag offensive close merge delete