<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">

<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>

                                <td>

                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="http://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">Community</a></h1>
                                                                </td>

                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px;  -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
    @Service loading resource file fails
</h3>
<span style="margin-bottom: 10px;">
    reply from <a href="http://community.jboss.org/people/osnetwork">Luca Merolla</a> in <i>EJB 3.0</i> - <a href="http://community.jboss.org/message/547439#547439">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>ok here is the code and the stacktrace.</p><blockquote class="jive-quote"><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><div id="_mcePaste">try {</div><div id="_mcePaste">&#160;&#160;&#160;&#160; manager = new DefaultCacheManager("/cache-config.xml");</div><div id="_mcePaste">} catch (IOException e) {</div><div id="_mcePaste">&#160;&#160;&#160;&#160; log.error("Cannot load the cache configuration");</div><div id="_mcePaste">&#160;&#160;&#160;&#160; log.debug("Cannot load the cache configuration", e);</div><div id="_mcePaste">}</div><div id="_mcePaste">cache = manager.getCache("gametableCache");</div><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p></blockquote><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>The last line of the code is the line 35.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Here is the stacktrace:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><div> </div><div id="_mcePaste"> </div><div id="_mcePaste"> </div><blockquote class="jive-quote"><p><div id="_mcePaste">20:26:55,920 ERROR [CacheService] Cannot load the cache configuration</div><div id="_mcePaste">20:26:55,921 ERROR [AbstractKernelController] Error installing to Create: name=jboss.j2ee:ear=ggPokerFruit.ear,jar=ggCore.jar,name=CacheService,service=EJB3 state=Configured</div><div id="_mcePaste">java.lang.NullPointerException</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at com.os.ggCore.cache.CacheService.&lt;init&gt;(CacheService.java:35)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at java.lang.reflect.Constructor.newInstance(Constructor.java:513)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at java.lang.Class.newInstance0(Class.java:355)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at java.lang.Class.newInstance(Class.java:308)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.ejb3.EJBContainer.construct(EJBContainer.java:844)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.ejb3.service.ServiceContainer.create(ServiceContainer.java:202)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at java.lang.reflect.Method.invoke(Method.java:597)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.reflect.plugins.introspection.ReflectionUtils.invoke(ReflectionUtils.java:59)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.reflect.plugins.introspection.ReflectMethodInfoImpl.invoke(ReflectMethodInfoImpl.java:150)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.joinpoint.plugins.BasicMethodJoinPoint.dispatch(BasicMethodJoinPoint.java:66)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.kernel.plugins.dependency.KernelControllerContextAction$JoinpointDispatchWrapper.execute(KernelControllerContextAction.java:241)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.kernel.plugins.dependency.ExecutionWrapper.execute(ExecutionWrapper.java:47)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchExecutionWrapper(KernelControllerContextAction.java:109)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchJoinPoint(KernelControllerContextAction.java:70)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.kernel.plugins.dependency.LifecycleAction.installActionInternal(LifecycleAction.java:221)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:54)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:42)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:774)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:540)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:121)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:51)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:171)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1439)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1157)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1178)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1210)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1098)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)</div><div id="_mcePaste">&#160;&#160;&#160;&#160;&#160;&#160;&#160; at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)</div></p></blockquote></div>

<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
    <p style="margin: 0;">Reply to this message by <a href="http://community.jboss.org/message/547439#547439">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in EJB 3.0 at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2029">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>