added SendPendingRPC transport msg
This commit is contained in:
parent
f1f41851cc
commit
a44bc1ba93
@ -322,29 +322,34 @@ class DeviceActorMessageProcessor extends AbstractContextAwareMsgProcessor {
|
|||||||
void process(TbActorCtx context, TransportToDeviceActorMsgWrapper wrapper) {
|
void process(TbActorCtx context, TransportToDeviceActorMsgWrapper wrapper) {
|
||||||
TransportToDeviceActorMsg msg = wrapper.getMsg();
|
TransportToDeviceActorMsg msg = wrapper.getMsg();
|
||||||
TbCallback callback = wrapper.getCallback();
|
TbCallback callback = wrapper.getCallback();
|
||||||
|
var sessionInfo = msg.getSessionInfo();
|
||||||
|
|
||||||
if (msg.hasSessionEvent()) {
|
if (msg.hasSessionEvent()) {
|
||||||
processSessionStateMsgs(msg.getSessionInfo(), msg.getSessionEvent());
|
processSessionStateMsgs(sessionInfo, msg.getSessionEvent());
|
||||||
}
|
}
|
||||||
if (msg.hasSubscribeToAttributes()) {
|
if (msg.hasSubscribeToAttributes()) {
|
||||||
processSubscriptionCommands(context, msg.getSessionInfo(), msg.getSubscribeToAttributes());
|
processSubscriptionCommands(context, sessionInfo, msg.getSubscribeToAttributes());
|
||||||
}
|
}
|
||||||
if (msg.hasSubscribeToRPC()) {
|
if (msg.hasSubscribeToRPC()) {
|
||||||
processSubscriptionCommands(context, msg.getSessionInfo(), msg.getSubscribeToRPC());
|
processSubscriptionCommands(context, sessionInfo, msg.getSubscribeToRPC());
|
||||||
|
}
|
||||||
|
if (msg.hasSendPendingRPC()) {
|
||||||
|
sendPendingRequests(context, getSessionId(sessionInfo), sessionInfo);
|
||||||
}
|
}
|
||||||
if (msg.hasGetAttributes()) {
|
if (msg.hasGetAttributes()) {
|
||||||
handleGetAttributesRequest(context, msg.getSessionInfo(), msg.getGetAttributes());
|
handleGetAttributesRequest(context, sessionInfo, msg.getGetAttributes());
|
||||||
}
|
}
|
||||||
if (msg.hasToDeviceRPCCallResponse()) {
|
if (msg.hasToDeviceRPCCallResponse()) {
|
||||||
processRpcResponses(context, msg.getSessionInfo(), msg.getToDeviceRPCCallResponse());
|
processRpcResponses(context, sessionInfo, msg.getToDeviceRPCCallResponse());
|
||||||
}
|
}
|
||||||
if (msg.hasSubscriptionInfo()) {
|
if (msg.hasSubscriptionInfo()) {
|
||||||
handleSessionActivity(context, msg.getSessionInfo(), msg.getSubscriptionInfo());
|
handleSessionActivity(context, sessionInfo, msg.getSubscriptionInfo());
|
||||||
}
|
}
|
||||||
if (msg.hasClaimDevice()) {
|
if (msg.hasClaimDevice()) {
|
||||||
handleClaimDeviceMsg(context, msg.getSessionInfo(), msg.getClaimDevice());
|
handleClaimDeviceMsg(context, sessionInfo, msg.getClaimDevice());
|
||||||
}
|
}
|
||||||
if (msg.hasPersistedRpcResponseMsg()) {
|
if (msg.hasPersistedRpcResponseMsg()) {
|
||||||
processPersistedRpcResponses(context, msg.getSessionInfo(), msg.getPersistedRpcResponseMsg());
|
processPersistedRpcResponses(context, sessionInfo, msg.getPersistedRpcResponseMsg());
|
||||||
}
|
}
|
||||||
callback.onSuccess();
|
callback.onSuccess();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -318,6 +318,9 @@ message SubscribeToRPCMsg {
|
|||||||
SessionType sessionType = 2;
|
SessionType sessionType = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
message SendPendingRPCMsg {
|
||||||
|
}
|
||||||
|
|
||||||
message ToDeviceRpcRequestMsg {
|
message ToDeviceRpcRequestMsg {
|
||||||
int32 requestId = 1;
|
int32 requestId = 1;
|
||||||
string methodName = 2;
|
string methodName = 2;
|
||||||
@ -440,11 +443,12 @@ message TransportToDeviceActorMsg {
|
|||||||
GetAttributeRequestMsg getAttributes = 3;
|
GetAttributeRequestMsg getAttributes = 3;
|
||||||
SubscribeToAttributeUpdatesMsg subscribeToAttributes = 4;
|
SubscribeToAttributeUpdatesMsg subscribeToAttributes = 4;
|
||||||
SubscribeToRPCMsg subscribeToRPC = 5;
|
SubscribeToRPCMsg subscribeToRPC = 5;
|
||||||
ToDeviceRpcResponseMsg toDeviceRPCCallResponse = 6;
|
SendPendingRPCMsg sendPendingRPC = 6;
|
||||||
SubscriptionInfoProto subscriptionInfo = 7;
|
ToDeviceRpcResponseMsg toDeviceRPCCallResponse = 7;
|
||||||
ClaimDeviceMsg claimDevice = 8;
|
SubscriptionInfoProto subscriptionInfo = 8;
|
||||||
ProvisionDeviceRequestMsg provisionDevice = 9;
|
ClaimDeviceMsg claimDevice = 9;
|
||||||
ToDevicePersistedRpcResponseMsg persistedRpcResponseMsg = 10;
|
ProvisionDeviceRequestMsg provisionDevice = 10;
|
||||||
|
ToDevicePersistedRpcResponseMsg persistedRpcResponseMsg = 11;
|
||||||
}
|
}
|
||||||
|
|
||||||
message TransportToRuleEngineMsg {
|
message TransportToRuleEngineMsg {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user