Either<Boolean, HChannel> result =
sChannelManager.storeSubscriptionChannel(ts, pubSubData, hChannel);
if (result.left()) {
return Either.of(StatusCode.SUCCESS, result.right());
} else {
StatusCode code;
if (pubSubData.isResubscribeRequest()) {
code = StatusCode.RESUBSCRIBE_EXCEPTION;
} else {
code = StatusCode.CLIENT_ALREADY_SUBSCRIBED;
}