I get this exception while determining whether there are more elements (Enumeration) to be caught and handled by the application.
com.app.fr.chrom.batch.model.exception.ReaderException: com.app.fr.chrom.model.exception.TechnicalException: javax.naming.CommunicationException: Request: 2 cancelled
at com.app.fr.chrom.batch.ldap.reader.LdapItemReader.open(LdapItemReader.java:79)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:132)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:120)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy32.open(Unknown Source)
at org.springframework.batch.item.support.CompositeItemStream.open(CompositeItemStream.java:96)
at org.springframework.batch.core.step.tasklet.TaskletStep.open(TaskletStep.java:306)
at org.springframework.batch.core.step.AbstractStep.execute(AbstractStep.java:192)
at org.springframework.batch.core.job.SimpleStepHandler.handleStep(SimpleStepHandler.java:141)
at org.springframework.batch.core.job.flow.JobFlowExecutor.executeStep(JobFlowExecutor.java:64)
at org.springframework.batch.core.job.flow.support.state.StepState.handle(StepState.java:60)
at org.springframework.batch.core.job.flow.support.SimpleFlow.resume(SimpleFlow.java:151)
at org.springframework.batch.core.job.flow.support.SimpleFlow.start(SimpleFlow.java:130)
at org.springframework.batch.core.job.flow.FlowJob.doExecute(FlowJob.java:135)
at org.springframework.batch.core.job.AbstractJob.execute(AbstractJob.java:301)
at org.springframework.batch.core.launch.support.SimpleJobLauncher$1.run(SimpleJobLauncher.java:134)
at org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
at org.springframework.batch.core.launch.support.SimpleJobLauncher.run(SimpleJobLauncher.java:127)
at com.app.fr.c4batch.C4Batch.launch(C4Batch.java:136)
at com.app.fr.c4batch.BatchLauncher.main(BatchLauncher.java:54)
Caused by: com.app.fr.chrom.model.exception.TechnicalException: com.app.fr.chrom.model.exception.TechnicalException: javax.naming.CommunicationException: Request: 2 cancelled
at com.app.fr.chrom.batch.service.impl.CollabLdapService.retrieveModifiedCollaborateur(CollabLdapService.java:116)
at com.app.fr.chrom.batch.ldap.reader.LdapItemReader.open(LdapItemReader.java:77)
... 27 more
Caused by: com.app.fr.chrom.model.exception.TechnicalException: javax.naming.CommunicationException: Request: 2 cancelled
at com.app.fr.chrom.dao.ldapimpl.RetrieveCollaborateurLdap.retrieveLastModified(RetrieveCollaborateurLdap.java:142)
at com.app.fr.chrom.batch.service.impl.CollabLdapService.retrieveModifiedCollaborateur(CollabLdapService.java:82)
... 28 more
Caused by: javax.naming.CommunicationException: Request: 2 cancelled
at com.sun.jndi.ldap.LdapRequest.getReplyBer(LdapRequest.java:105)
at com.sun.jndi.ldap.Connection.readReply(Connection.java:452)
at com.sun.jndi.ldap.LdapClient.getSearchReply(LdapClient.java:638)
at com.sun.jndi.ldap.LdapClient.getSearchReply(LdapClient.java:606)
at com.sun.jndi.ldap.LdapCtx.getSearchReply(LdapCtx.java:1920)
at com.sun.jndi.ldap.LdapNamingEnumeration.getNextBatch(LdapNamingEnumeration.java:129)
at com.sun.jndi.ldap.LdapNamingEnumeration.hasMoreImpl(LdapNamingEnumeration.java:216)
at com.sun.jndi.ldap.LdapNamingEnumeration.hasMore(LdapNamingEnumeration.java:189)
at com.app.fr.chrom.dao.ldapimpl.RetrieveCollaborateurLdap.retrieveLastModified(RetrieveCollaborateurLdap.java:97)
... 29 more
This my code:
<pre>
InitialDirContext ctxLdap = new InitialDirContext(envLdap);
final NamingEnumeration<?> userSearch = ctxLdap.search(getUsersSuffixDN(), searchFilter, searchControls);
while (userSearch.hasMore()) {...} // <b>The HasMore method throws <i>javax.naming.CommunicationException</i></b>
this exception is rarely thrown by this method but i want to know why it happened. Thanks for your help
This may happen when you have a registered user and you try to register it again.
Related
I have a mod that is not executing receive packet events when I run
#Cancelable public class ReceivePacketEvent extends Event { public Packet<?> packet; public ReceivePacketEvent(Packet<?> packet) { System.out.println("PKT"); this.packet = packet; } }
Nothing will happen. Other events will work like on render or tick event but packet wont work. for reference I'm using this mod in a server
I get an error seemingly randomly that looks like this and im not sure where it comes from or if it affects the packet event so id say im lost
[01:22:45] [main/FATAL] (Minecraft) Error executing task
java.util.concurrent.ExecutionException: java.lang.NullPointerException
at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[?:1.8.0_351]
at java.util.concurrent.FutureTask.get(FutureTask.java:192) ~[?:1.8.0_351]
at net.minecraft.util.Util.runTask(Util.java:43) [Util.class:?]
at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:987) [Minecraft.class:?]
at net.minecraft.client.Minecraft.run(Minecraft.java:443) [Minecraft.class:?]
at net.minecraft.client.main.Main.main(Main.java:111) [Main.class:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_351]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_351]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_351]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_351]
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
at net.fabricmc.devlaunchinjector.Main.main(Main.java:86) [dev-launch-injector-0.2.1+build.8.jar:?]
Caused by: java.lang.NullPointerException
at net.minecraft.scoreboard.Scoreboard.removeTeam(Scoreboard.java:240) ~[Scoreboard.class:?]
at net.minecraft.client.network.NetHandlerPlayClient.handleTeams(NetHandlerPlayClient.java:1452) ~[NetHandlerPlayClient.class:?]
at net.minecraft.network.play.server.S3EPacketTeams.processPacket(S3EPacketTeams.java:114) ~[S3EPacketTeams.class:?]
at net.minecraft.network.play.server.S3EPacketTeams.processPacket(S3EPacketTeams.java:36) ~[S3EPacketTeams.class:?]
at net.minecraft.network.PacketThreadUtil$1.run(PacketThreadUtil.java:24) ~[PacketThreadUtil$1.class:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_351]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_351]
at net.minecraft.util.Util.runTask(Util.java:42) ~[Util.class:?]
... 10 more
I have a partitioned job that reads from and writes to a DB. I have a chunking size of 10. If a partition fails and i want the restart to happen from the last commit, I have overwritten the checkpointinfo method and wrote my logic according to my application requirement. whenever i try to restart the failed job, i am getting an exception that there is failure in Read-Process-Write Loop
Here is the exception logs:
[3/1/18 19:18:09:004 IST] [process partition0] com.ibm.ws.batch.JobLogger CWWKY0030I: An exception occurred while running the step process.
com.ibm.jbatch.container.exception.BatchContainerRuntimeException: Failure in Read-Process-Write Loop
at com.ibm.jbatch.container.controller.impl.ChunkStepControllerImpl.invokeChunk(ChunkStepControllerImpl.java:704)
at com.ibm.jbatch.container.controller.impl.ChunkStepControllerImpl.invokeCoreStep(ChunkStepControllerImpl.java:795)
at com.ibm.jbatch.container.controller.impl.BaseStepControllerImpl.execute(BaseStepControllerImpl.java:293)
at com.ibm.jbatch.container.controller.impl.ExecutionTransitioner.doExecutionLoop(ExecutionTransitioner.java:118)
at com.ibm.jbatch.container.controller.impl.WorkUnitThreadControllerImpl.executeCoreTransitionLoop(WorkUnitThreadControllerImpl.java:93)
at com.ibm.jbatch.container.controller.impl.WorkUnitThreadControllerImpl.executeWorkUnit(WorkUnitThreadControllerImpl.java:155)
at com.ibm.jbatch.container.controller.impl.WorkUnitThreadControllerImpl$AbstractControllerHelper.runExecutionOnThread(WorkUnitThreadControllerImpl.java:480)
at com.ibm.jbatch.container.controller.impl.WorkUnitThreadControllerImpl.runExecutionOnThread(WorkUnitThreadControllerImpl.java:89)
at com.ibm.jbatch.container.util.BatchWorkUnit.run(BatchWorkUnit.java:117)
at com.ibm.ws.context.service.serializable.ContextualRunnable.run(ContextualRunnable.java:79)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: com.ibm.jbatch.container.exception.BatchContainerRuntimeException: java.lang.ClassNotFoundException: [B
at com.ibm.jbatch.container.util.TCCLObjectInputStream.resolveClass(TCCLObjectInputStream.java:40)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1620)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1521)
at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1671)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1347)
at java.io.ObjectInputStream.access$300(ObjectInputStream.java:208)
at java.io.ObjectInputStream$GetFieldImpl.readFields(ObjectInputStream.java:2182)
at java.io.ObjectInputStream.readFields(ObjectInputStream.java:543)
at java.math.BigInteger.readObject(BigInteger.java:4406)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1909)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1808)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:373)
at java.util.HashMap.readObject(HashMap.java:1404)
at sun.reflect.GeneratedMethodAccessor57.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1909)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1808)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:373)
at java.util.HashMap.readObject(HashMap.java:1404)
at sun.reflect.GeneratedMethodAccessor57.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1909)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1808)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2018)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1942)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1808)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:373)
at com.ibm.jbatch.container.persistence.CheckpointData.<init>(CheckpointData.java:47)
at com.ibm.jbatch.container.persistence.jpa.StepThreadInstanceEntity.getCheckpointData(StepThreadInstanceEntity.java:131)
at com.ibm.jbatch.container.controller.impl.ChunkStepControllerImpl.openReaderAndWriter(ChunkStepControllerImpl.java:935)
at com.ibm.jbatch.container.controller.impl.ChunkStepControllerImpl.invokeChunk(ChunkStepControllerImpl.java:599)
... 14 more
Caused by: java.lang.ClassNotFoundException: [B
at com.ibm.ws.classloading.internal.UnifiedClassLoader.findClass(UnifiedClassLoader.java:119)
at com.ibm.ws.classloading.internal.ThreadContextClassLoader.findClass(ThreadContextClassLoader.java:120)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at com.ibm.ws.classloading.internal.UnifiedClassLoader.loadClass0(UnifiedClassLoader.java:107)
at com.ibm.ws.classloading.internal.UnifiedClassLoader$Delegation.loadClass(UnifiedClassLoader.java:78)
at com.ibm.ws.classloading.internal.UnifiedClassLoader.loadClass(UnifiedClassLoader.java:102)
at com.ibm.ws.classloading.internal.ThreadContextClassLoader.loadClass(ThreadContextClassLoader.java:136)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at com.ibm.jbatch.container.util.TCCLObjectInputStream.resolveClass(TCCLObjectInputStream.java:38)
... 57 more
[3/1/18 19:18:09:005 IST] [process partition0] com.ibm.ws.batch.JobLogger CWWKY0014W: Partition 0 failed with batch status FAILED and exit status null for step process for job instance 105,001 and job execution 105,008.
[3/1/18 19:18:15:588 IST] [process partition0] com.ibm.ws.batch.JobLogger
Here are my code snippet
Item Reader
#Override
public Serializable checkpointInfo() throws Exception {
Checkpoint checkpoint=new Checkpoint();
for (CheckpointProperty prop:dbOp.getCheckpointInfo().getProperty()) {
final Object result = ExprUtils.evaluate(newProps,prop.getCheckpointValue().toString());
checkpoint.addCheckPoint(prop.getName(), result); } return checkpoint;
}
Item writer
#Override
public Serializable checkpointInfo() throws Exception {
final Properties checkpointInfo = new Properties();
for (String key : checkpointProps.stringPropertyNames()) {
final String expr = checkpointProps.getProperty(key);
final Object result = ExprUtils.evaluate(dataMap, expr);
checkpointInfo.setProperty(key, result.toString());
}
return checkpointInfo;
}
Checkpoint class
----------------------
public class Checkpoint implements Serializable {
private HashMap<String, Object> checkpoints = new HashMap();
public void reset() {
this.checkpoints.clear();
}
public void addCheckPoint(String stream, Object position) {
this.checkpoints.put(stream, position);
}
public Object get(String stream) {
return this.checkpoints.get(stream);
}
public HashMap<String, Object> getCheckpoints() {
return this.checkpoints;
}
}
This is because of the BigInteger Datatype used in oracle.
This appears to be a bug in Liberty. Opened issue #2792.
I think it will happen with any array type, and that you could workaround by using an ArrayList in place of an array.
UPDATE: A fix for this issue was delivered in 18.0.0.2.
Hi I currently have an WAS 7.0.29 and we've planned to update it to fix pack 41.
Upon the installation of the Fix pack I have encountered this:
[11/10/16 19:32:24:505 SGT] 00000000 UserRegistryC E SECJ0281E: Error creating user registry object. The exception is java.lang.NoClassDefFoundError: com.dummy.registry.CustomRegistry (initialization failure)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:139)
at java.lang.Class.forName(Class.java:294)
at com.ibm.ws.security.registry.UserRegistryImpl.initialize(UserRegistryImpl.java:225)
at com.ibm.ws.security.config.UserRegistryConfigImpl.do_createRegistryObjects(UserRegistryConfigImpl.java:686)
at com.ibm.ws.security.config.UserRegistryConfigImpl.createRegistryObjects(UserRegistryConfigImpl.java:643)
at com.ibm.ws.security.config.UserRegistryConfigImpl.getUserRegistryImpl(UserRegistryConfigImpl.java:628)
at com.ibm.ws.security.config.UserRegistryConfigImpl.getString(UserRegistryConfigImpl.java:850)
at com.ibm.ws.security.config.UserRegistryConfigImpl.getPrincipalName(UserRegistryConfigImpl.java:577)
at com.ibm.ws.security.config.CSIv2ConfigImpl.initializeOnServer(CSIv2ConfigImpl.java:723)
at com.ibm.ws.security.config.CSIv2ConfigImpl.initialize(CSIv2ConfigImpl.java:1151)
at com.ibm.ws.security.config.CSIv2ConfigImpl.<init>(CSIv2ConfigImpl.java:100)
at com.ibm.ws.security.config.SecurityConfigObjectFactoryImpl.createCSIv2Config(SecurityConfigObjectFactoryImpl.java:116)
at com.ibm.ws.security.config.SecurityObjectLocator.do_getCSIv2Config(SecurityObjectLocator.java:852)
at com.ibm.ejs.ras.RasHelper.printStackTrace(RasHelper.java:368)
at com.ibm.ejs.ras.RasHelper.throwableToString(RasHelper.java:349)
at com.ibm.ejs.ras.MessageEvent6.convertParameters(MessageEvent6.java:346)
at com.ibm.ejs.ras.MessageEvent6.<init>(MessageEvent6.java:221)
at com.ibm.ejs.ras.Tr.fireMessageEvent(Tr.java:1538)
at com.ibm.ejs.ras.Tr.error(Tr.java:733)
at com.ibm.ws.security.config.UserRegistryConfigImpl.do_createRegistryObjects(UserRegistryConfigImpl.java:696)
at com.ibm.ws.security.config.UserRegistryConfigImpl.createRegistryObjects(UserRegistryConfigImpl.java:643)
at com.ibm.ws.security.config.UserRegistryConfigImpl.getUserRegistryImpl(UserRegistryConfigImpl.java:628)
at com.ibm.ws.security.config.UserRegistryConfigImpl.getString(UserRegistryConfigImpl.java:850)
at com.ibm.ws.security.config.UserRegistryConfigImpl.getPrincipalName(UserRegistryConfigImpl.java:577)
at com.ibm.ws.security.config.CSIv2ConfigImpl.initializeOnServer(CSIv2ConfigImpl.java:723)
at com.ibm.ws.security.config.CSIv2ConfigImpl.initialize(CSIv2ConfigImpl.java:1151)
at com.ibm.ws.security.config.CSIv2ConfigImpl.<init>(CSIv2ConfigImpl.java:100)
at com.ibm.ws.security.config.SecurityConfigObjectFactoryImpl.createCSIv2Config(SecurityConfigObjectFactoryImpl.java:116)
at com.ibm.ws.security.config.SecurityObjectLocator.do_getCSIv2Config(SecurityObjectLocator.java:852)
at com.ibm.ws.security.config.SecurityObjectLocator.getCSIv2Config(SecurityObjectLocator.java:882)
at com.ibm.ws.security.config.SecurityObjectLocator.getCSIv2Config(SecurityObjectLocator.java:873)
at com.ibm.ws.security.auth.ContextManagerImpl.getProperty(ContextManagerImpl.java:2102)
at com.ibm.ws.security.auth.ContextManagerImpl.getProperty(ContextManagerImpl.java:2141)
at com.ibm.websphere.security.WSSecurityException.printStackTrace(WSSecurityException.java:230)
at com.ibm.ffdc.util.formatting.IncidentReportHeader.writeTo(IncidentReportHeader.java:77)
at com.ibm.ffdc.util.provider.IncidentStream.write(IncidentStream.java:207)
at com.ibm.ffdc.util.provider.IncidentLogger.writeHeader(IncidentLogger.java:70)
at com.ibm.ffdc.util.provider.IncidentLogger.writeIncidentTo(IncidentLogger.java:61)
at com.ibm.ws.ffdc.impl.FfdcProvider.logIncident(FfdcProvider.java:206)
at com.ibm.ws.ffdc.impl.FfdcProvider.logIncident(FfdcProvider.java:135)
at com.ibm.ffdc.util.provider.FfdcProvider.log(FfdcProvider.java:259)
at com.ibm.ws.ffdc.impl.FfdcProvider.log(FfdcProvider.java:148)
at com.ibm.ffdc.util.provider.IncidentEntry.log(IncidentEntry.java:105)
at com.ibm.ffdc.util.provider.Ffdc.log(Ffdc.java:90)
at com.ibm.ws.ffdc.FFDCFilter.processException(FFDCFilter.java:114)
at com.ibm.ws.security.config.UserRegistryConfigImpl.do_createRegistryObjects(UserRegistryConfigImpl.java:694)
at com.ibm.ws.security.config.UserRegistryConfigImpl.createRegistryObjects(UserRegistryConfigImpl.java:643)
at com.ibm.ws.security.config.UserRegistryConfigImpl.getUserRegistryImpl(UserRegistryConfigImpl.java:628)
at com.ibm.ws.security.core.distSecurityComponentImpl.getRealmFromUserRegistry(distSecurityComponentImpl.java:2808)
at com.ibm.ws.security.core.distSecurityComponentImpl.initialize(distSecurityComponentImpl.java:356)
at com.ibm.ws.security.core.SecurityComponentImpl.initialize(SecurityComponentImpl.java:94)
at com.ibm.ws.runtime.component.ContainerHelper.initWsComponent(ContainerHelper.java:1191)
at com.ibm.ws.runtime.component.ContainerHelper.initializeComponent(ContainerHelper.java:1098)
at com.ibm.ws.runtime.component.ContainerHelper.initializeComponents(ContainerHelper.java:900)
at com.ibm.ws.runtime.component.ContainerImpl.initializeComponents(ContainerImpl.java:776)
at com.ibm.ws.runtime.component.ContainerImpl.initializeComponents(ContainerImpl.java:750)
at com.ibm.ws.runtime.component.ServerImpl.initialize(ServerImpl.java:349)
at com.ibm.ws.runtime.WsServerImpl.bootServerContainer(WsServerImpl.java:280)
at com.ibm.ws.runtime.WsServerImpl.start(WsServerImpl.java:214)
at com.ibm.ws.runtime.WsServerImpl.main(WsServerImpl.java:666)
at com.ibm.ws.runtime.WsServer.main(WsServer.java:59)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
at java.lang.reflect.Method.invoke(Method.java:611)
at com.ibm.wsspi.bootstrap.WSLauncher.launchMain(WSLauncher.java:213)
at com.ibm.wsspi.bootstrap.WSLauncher.main(WSLauncher.java:93)
at com.ibm.wsspi.bootstrap.WSLauncher.run(WSLauncher.java:74)
at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
at java.lang.reflect.Method.invoke(Method.java:611)
at org.eclipse.core.launcher.Main.invokeFramework(Main.java:340)
at org.eclipse.core.launcher.Main.basicRun(Main.java:282)
at org.eclipse.core.launcher.Main.run(Main.java:981)
at com.ibm.wsspi.bootstrap.WSPreLauncher.launchEclipse(WSPreLauncher.java:341)
at com.ibm.wsspi.bootstrap.WSPreLauncher.main(WSPreLauncher.java:111)
Caused by: java.lang.ExceptionInInitializerError
at java.lang.J9VMInternals.initialize(J9VMInternals.java:221)
at com.ibm.websphere.ras.Manager.createRASTraceLogger(Manager.java:241)
at com.dummy.registry.CustomRegistry.<clinit>(CustomRegistry.java:126)
at java.lang.J9VMInternals.initializeImpl(Native Method)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:199)
at java.lang.Class.forName(Class.java:294)
at com.ibm.ws.security.registry.UserRegistryImpl.initialize(UserRegistryImpl.java:225)
at com.ibm.ws.security.config.UserRegistryConfigImpl.do_createRegistryObjects(UserRegistryConfigImpl.java:686)
... 36 more
Caused by: java.security.AccessControlException: Access denied (java.util.PropertyPermission com.ibm.ws.ffdc.SupportORBFFDC read)
at java.security.AccessController.throwACE(AccessController.java:121)
at java.security.AccessController.checkPermission(AccessController.java:194)
at java.lang.SecurityManager.checkPermission(SecurityManager.java:544)
at java.lang.SecurityManager.checkPropertyAccess(SecurityManager.java:1293)
at java.lang.System.getProperty(System.java:404)
at java.lang.System.getProperty(System.java:388)
at com.ibm.websphere.ras.WsJrasTraceLogger.<clinit>(WsJrasTraceLogger.java:98)
at java.lang.J9VMInternals.initializeImpl(Native Method)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:199)
... 43 more
.
My guess is that the issue is in the CustomRegistry that we have made which looks like this:
public class CustomRegistry implements UserRegistry {
protected static RASTraceLogger traceLogger;
private static RASMessageLogger msgLogger;
static {
Manager mgr = Manager.getManager();
traceLogger = mgr.createRASTraceLogger("MyWebsite", "Authentication", "Registry", CustomRegistry.class.getName());
msgLogger = mgr.createRASMessageLogger("MyWebsite", "Authentication", "Registry", CustomRegistry.class.getName());
msgLogger.setMessageFile("com.dummy.registry.RegistryMessages");
}
It points the usage of mgr.createRASTraceLogger in the CustomRegistry but I'm not sure what is the right approach for it.
Right now, I can't even start my server.
Your suggestions will be a great help! :)
Code which is generating exception is :
SystemManager sm = SystemManager.getInstance();
String naming = sm.getProperty("server.name");
System.out.println("naming is :"+naming);
tc = (TransactionController)Naming.lookup(naming);
output:
java.rmi.UnmarshalException: error unmarshalling return; nested exception is:
java.lang.ClassNotFoundException: espresso.server.TransactionControllerImpl_Stub (no security manager: RMI class loader disabled)
at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
at java.rmi.Naming.lookup(Naming.java:101)
at espresso.client.RemoteClientImpl.getConnection(RemoteClientImpl.java: 59)
at espresso.client.RemoteClientImpl.<init>(RemoteClientImpl.java:38)
at espresso.client.MainWinCopy.sendCTRButtonActionPerformed(MainWinCopy.java:75)
at dynamicProject.CustomerImplementation.createCustomer(CustomerImplementation.java:83)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:454)
at ...
I am getting the error at the point I try to save an entity. I only get this error when I have booted up my server, not when I run my unit tests using dbunit.
I am trying to save an association. My unit test should be the exact same condition as that which I am encountering when manually testing. I am adding a new entity on one end of the relationship where no relationships existed before.
I am using HSQLDB with the unit tests and the web app is using SQL Server.
The searches I have performed have not proved fruitful. An explanation of the message would prove very useful.
Here is the test case (that works just fine!):
#Test
#DatabaseSetup(value="MobileWebsiteTest.saveMobilewebsiteMobilecolorswatchmapuserdefined_NewUserSwatch.xml", type=DatabaseOperation.REFRESH)
public void saveMobilewebsiteMobilecolorswatchmapuserdefined_NewUserSwatch() {
// given
Integer mobileWebsiteId = 569;
Mobilecolorswatchmapuserdefined expected = MobilecolorswatchmapuserdefinedBuilder.init().build();
// when
Mobilewebsite result = service.saveMobilewebsiteMobilecolorswatchmapuserdefined(mobileWebsiteId, expected);
// then
assertNotNull("The Mobilewebsite user defined swatch should not be null", result.getMobilecolorswatchmapuserdefined());
assertNotNull("The Mobilewebsite user defined swatch id should not be null.", result.getMobilecolorswatchmapuserdefined().getMobileColorSwatchMapUserDefinedId());
assertEquals("The result aside property should be equivalent to the expected aside property.", expected.getAside(), result.getMobilecolorswatchmapuserdefined().getAside());
assertEquals("The result SiteName property should be equivalent to the expected SiteName property.", expected.getSiteName(), result.getMobilecolorswatchmapuserdefined().getSiteName());
}
Here is the service (note: I am currently doing a delete/save under the condition that there is already an association - this should be one-to-one, but is legacy):
#Override
#Transactional
public Mobilewebsite saveMobilewebsiteMobilecolorswatchmapuserdefined(Integer mobileWebsiteId, Mobilecolorswatchmapuserdefined related_swatchmap) {
log.debug("saveMobilewebsiteMobilecolorswatchmapuserdefined(Integer mobileWebsiteId=[" + mobileWebsiteId + "], Mobilecolorswatchmapuserdefined related_swatchmap=[" + related_swatchmap + "])");
Mobilewebsite mobilewebsite = mobilewebsiteDAO.findMobilewebsiteByPrimaryKey(mobileWebsiteId, -1, -1);
Calendar now = Calendar.getInstance();
if (mobilewebsite.getMobilecolorswatchmapuserdefined() != null) {
this.deleteMobilewebsiteMobilecolorswatchmapuserdefined(mobilewebsite.getMobileWebsiteId(), mobilewebsite.getMobilecolorswatchmapuserdefined().getMobileColorSwatchMapUserDefinedId());
}
related_swatchmap.setCreatedDtstamp(now);
related_swatchmap.setLastUpdatedDtstamp(now);
related_swatchmap.addToMobilewebsites(mobilewebsite);
**related_swatchmap = mobilecolorswatchmapuserdefinedDAO.store(related_swatchmap);**
mobilewebsite.setMobilecolorswatchmapuserdefined(related_swatchmap);
mobilewebsite = mobilewebsiteDAO.store(mobilewebsite);
mobilewebsiteDAO.flush();
return mobilewebsite;
}
The stack trace points to the highlighted line above: mobilecolorswatchmapuserdefinedDAO.store(related_swatchmap);.
The stacktrace is:
2012-12-11 15:14:11.192 59464 [http-8080-2] ERROR - Unexpected error occurred
org.apache.wicket.WicketRuntimeException: Method onFormSubmitted of interface org.apache.wicket.markup.html.form.IFormSubmitListener targeted at [ [Component id = form1]] on component [ [Component id = form1]] threw an exception
at org.apache.wicket.RequestListenerInterface.internalInvoke(RequestListenerInterface.java:270)
at org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:216)
at org.apache.wicket.request.handler.ListenerInterfaceRequestHandler.invokeListener(ListenerInterfaceRequestHandler.java:248)
at org.apache.wicket.request.handler.ListenerInterfaceRequestHandler.respond(ListenerInterfaceRequestHandler.java:234)
at org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:781)
at org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64)
at org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:255)
at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:212)
at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:283)
at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:185)
at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:241)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:602)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.wicket.RequestListenerInterface.internalInvoke(RequestListenerInterface.java:260)
... 22 more
**Caused by: java.lang.NullPointerException: null entities are not supported by org.hibernate.event.def.EventCache**
at org.hibernate.event.def.EventCache.containsKey(EventCache.java:80)
at org.hibernate.event.def.DefaultMergeEventListener.mergeTransientEntity(DefaultMergeEventListener.java:361)
at org.hibernate.event.def.DefaultMergeEventListener.entityIsTransient(DefaultMergeEventListener.java:303)
at org.hibernate.event.def.DefaultMergeEventListener.onMerge(DefaultMergeEventListener.java:258)
at org.hibernate.event.def.DefaultMergeEventListener.onMerge(DefaultMergeEventListener.java:84)
at org.hibernate.impl.SessionImpl.fireMerge(SessionImpl.java:859)
at org.hibernate.impl.SessionImpl.merge(SessionImpl.java:843)
at org.hibernate.impl.SessionImpl.merge(SessionImpl.java:847)
at org.hibernate.ejb.AbstractEntityManagerImpl.merge(AbstractEntityManagerImpl.java:682)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.springframework.orm.jpa.ExtendedEntityManagerCreator$ExtendedEntityManagerInvocationHandler.invoke(ExtendedEntityManagerCreator.java:365)
at $Proxy44.merge(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.springframework.orm.jpa.SharedEntityManagerCreator$SharedEntityManagerInvocationHandler.invoke(SharedEntityManagerCreator.java:240)
at $Proxy44.merge(Unknown Source)
at org.skyway.spring.util.dao.AbstractJpaDao.merge(AbstractJpaDao.java:61)
at org.skyway.spring.util.dao.AbstractJpaDao.store(AbstractJpaDao.java:48)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:309)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:110)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy76.store(Unknown Source)
**at com.telventdtn.aghostmobile.service.MobilewebsiteServiceImpl.saveMobilewebsiteMobilecolorswatchmapuserdefined(MobilewebsiteServiceImpl.java:342)**
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:309)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:110)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy77.saveMobilewebsiteMobilecolorswatchmapuserdefined(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.wicket.proxy.LazyInitProxyFactory$JdkHandler.invoke(LazyInitProxyFactory.java:416)
at org.apache.wicket.proxy.$Proxy4.saveMobilewebsiteMobilecolorswatchmapuserdefined(Unknown Source)
at com.telventdtn.aghostmobile.ArrangeColorsThemePage$SubmitButtonHandler.onSubmit(ArrangeColorsThemePage.java:126)
at com.telventdtn.aghostmobile.markup.html.form.ObservableButton.notifyObservers(ObservableButton.java:20)
at com.telventdtn.aghostmobile.markup.html.form.ButtonFactory$1.onSubmit(ButtonFactory.java:34)
at org.apache.wicket.markup.html.form.Form.delegateSubmit(Form.java:1151)
at org.apache.wicket.markup.html.form.Form.process(Form.java:834)
at org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:762)
at org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:692)
... 27 more
I have had similar experience wherein the table defined a nullable column, but the domain class marked it as not nullable. An attempt was made to save the object with nulls, and indeed it was persisted, but then failed with that error. Hope this helps.