Author: thomas.diesler(a)jboss.com
Date: 2007-08-24 05:05:20 -0400 (Fri, 24 Aug 2007)
New Revision: 4496
Modified:
framework/trunk/src/main/java/org/jboss/wsf/framework/management/ServerConfigFactoryImpl.java
Log:
Throw ILSE when server config cannot be found
Modified:
framework/trunk/src/main/java/org/jboss/wsf/framework/management/ServerConfigFactoryImpl.java
===================================================================
---
framework/trunk/src/main/java/org/jboss/wsf/framework/management/ServerConfigFactoryImpl.java 2007-08-23
14:47:05 UTC (rev 4495)
+++
framework/trunk/src/main/java/org/jboss/wsf/framework/management/ServerConfigFactoryImpl.java 2007-08-24
09:05:20 UTC (rev 4496)
@@ -33,6 +33,10 @@
{
public ServerConfig getServerConfig()
{
- return new KernelAwareSPIFactory().getKernelProvidedSPI(ServerConfig.BEAN_NAME,
ServerConfig.class);
+ ServerConfig serverConfig = new
KernelAwareSPIFactory().getKernelProvidedSPI(ServerConfig.BEAN_NAME, ServerConfig.class);
+ if (serverConfig == null)
+ throw new IllegalStateException("Cannot obtain ServerConfig for bean name:
" + ServerConfig.BEAN_NAME);
+
+ return serverConfig;
}
}
Show replies by date