[jboss-dev-forums] [JBoss ESB Development] - deducing host and port in new HTTP Gateway
dward
do-not-reply at jboss.com
Thu Sep 10 17:48:28 EDT 2009
regarding https://jira.jboss.org/jira/browse/JBESB-2824 ...
It's super easy to register a new HTTPEpr to the registry in HttpGatewayServlet.init() and unregister it in destroy(). I even added a loadOnStartup flag to the Servlet model so as soon as this servlet deploys the init is called.
I get the scheme based on how the user configured this
http://www.jboss.org/community/wiki/HTTPGateway#Security
for transport guarantee.
I get the context path easily enough in it from config.getServletContext().getContextPath().
I re-use the logic in HttpGatewayDeploymentFactory to figure out the url-pattern for the servlet path.
I have all the makings of a complete endpoint address, however what I'm scratching my head about is how to deduce the host and port. Looking up the tomcat Connector in the JMX MBean Server is not gonna work because the MBean Object Name has the darn port embedded in it: a Catch-22.
Any ideas? The rest of this is brain-dead easy... Thanks!
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4254601#4254601
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4254601
More information about the jboss-dev-forums
mailing list