[jboss-jira] [JBoss JIRA] (WFLY-2706) ServletContext.getServerInfo: Undertow instead of JBoss or Wildfly
Stuart Douglas (JIRA)
issues at jboss.org
Wed Feb 5 02:04:28 EST 2014
[ https://issues.jboss.org/browse/WFLY-2706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Stuart Douglas resolved WFLY-2706.
----------------------------------
Resolution: Done
> ServletContext.getServerInfo: Undertow instead of JBoss or Wildfly
> ------------------------------------------------------------------
>
> Key: WFLY-2706
> URL: https://issues.jboss.org/browse/WFLY-2706
> Project: WildFly
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: Web (Undertow)
> Affects Versions: 8.0.0.CR1
> Environment: CentOS, OpenJDK7
> Reporter: Andre Pankraz
> Assignee: Stuart Douglas
>
> javax.servlet.ServletContext.getServerInfo() identifies Wildfly with:
> "Undertow" and not with JBoss or Wildfly. Is this intentional?
> Some frameworks or extensions (e.g. JavaMelody) use this server info to provide application server specific behaviour.
> So Wildfly (or the newer JBoss AS) is quite different to past versions and this must not be the wrong step to tell something different here, but providing the embedded Servlet Container "Undertow" as response might not be intentional?
> I would suggest to show something with "JBoss" even though Wildfly is the community version name (BTW great move...who wants to have wild flies in his data center...where is our swatter)
> JavaMelody example code, triggered by HttpSessionListener.contextInitialized(ServletContextEvent event) -> initServletContext(event.getServletContext()):
> void initServletContext(ServletContext context) {
> assert context != null;
> this.servletContext = context;
> final String serverInfo = servletContext.getServerInfo();
> jboss = serverInfo.contains("JBoss") ;
> glassfish = serverInfo.contains("GlassFish")
> || serverInfo.contains("Sun Java System Application Server");
> weblogic = serverInfo.contains("WebLogic");
> jonas = System.getProperty("jonas.name") != null;
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list