protected ContainerMethodExecutor getContainerMethodExecutor(Context context) {
JBossAsContainerConfiguration config = context.get(Configuration.class).getContainerConfig(JBossAsContainerConfiguration.class);
if (config.isExecuteWithServlet()) {
try {
return new ServletMethodExecutor(new URL("http", config.getBindAddress().getHostName(), config.getHttpPort(), "/"));
} catch (MalformedURLException e) {
// AutoGenerated
throw new RuntimeException(e);
}
} else {