ServiceController<?> hornetqService = context.getController().getServiceContainer().getService(MessagingServices.getHornetQServiceName(hornetQServerName));
HornetQServer hornetQServer = HornetQServer.class.cast(hornetqService.getValue());
injectedRegistry.getValue().addProtocol(HORNETQ_REMOTING,
switchToHornetQProtocol(hornetQServer, acceptorName),
new SimpleHttpUpgradeHandshake(MAGIC_NUMBER, SEC_HORNETQ_REMOTING_KEY, SEC_HORNETQ_REMOTING_ACCEPT) {
/**
* override the default upgrade handshake to take into account the {@code TransportConstants.HTTP_UPGRADE_ENDPOINT_PROP_NAME} header
* to select the correct acceptors among all that are configured in HornetQ.
*
* If the request does not have this header, the first acceptor will be used.