Welcome to the new Gigaspaces XAP forum. To recover your account, please follow these instructions.

Ask Your Question
0

gigaspaces webui no session error

We got following error when checking an entry from GS WebUI either from the Queries or Types tabs in Spaces page. The entry has 2 collections and is loaded through initialLoad. The odd thing is a standard gs client can fetch the data correctly, but not through GS WebUI, which tries to fetch it from DB, which seems wrong. Also the error will disappear if the entry is directly written to the space instead of through initial loading.

Looks a GS WebUI bug or some config we missing. Thanks in advance any insights on this.

2018-02-05 15:41:20,993 SEVERE [com.gigaspaces.webui.common] - org.hibernate.LazyInitializationException: failed to lazily initialize a collection, could not initialize proxy - no Session; Caused by: org.hibernate.LazyInitializationException: failed to lazily initialize a collection, could not initialize proxy - no Session at org.hibernate.collection.internal.AbstractPersistentCollection.throwLazyInitializationException(AbstractPersistentCollection.java:566) at org.hibernate.collection.internal.AbstractPersistentCollection.withTemporarySessionIfNeeded(AbstractPersistentCollection.java:186) at org.hibernate.collection.internal.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:545) at org.hibernate.collection.internal.PersistentSet.add(PersistentSet.java:206) at com.gigaspaces.document.DocumentObjectConverter.toDocumentCollectionIfNeeded(DocumentObjectConverter.java:434) at com.gigaspaces.document.DocumentObjectConverter.toDocumentIfNeededInternal(DocumentObjectConverter.java:219) at com.gigaspaces.document.DocumentObjectConverter.toDocumentIfNeeded(DocumentObjectConverter.java:209) at com.gigaspaces.internal.document.DocumentObjectConverterInternal.toDocumentIfNeeded(DocumentObjectConverterInternal.java:46) at com.gigaspaces.internal.document.DocumentObjectConverterInternal.toDocumentIfNeeded(DocumentObjectConverterInternal.java:178) at com.gigaspaces.internal.document.DocumentObjectConverterInternal.convertNonPrimitiveFixedPropertiesToDocuments(DocumentObjectConverterInternal.java:113) at com.gigaspaces.internal.document.DocumentObjectConverterInternal.convertNonPrimitivePropertiesToDocuments(DocumentObjectConverterInternal.java:71) at com.gigaspaces.internal.server.space.SpaceImpl.applyEntryPacketOutFilter(SpaceImpl.java:2334) at com.gigaspaces.internal.server.space.SpaceImpl.readNew(SpaceImpl.java:2176) at com.gigaspaces.internal.server.space.operations.ReadTakeEntrySpaceOperation.execute(ReadTakeEntrySpaceOperation.java:33) at com.gigaspaces.internal.server.space.operations.ReadTakeEntrySpaceOperation.execute(ReadTakeEntrySpaceOperation.java:23) at com.gigaspaces.internal.server.space.operations.SpaceOperationsExecutor.executeOperation(SpaceOperationsExecutor.java:78) at com.gigaspaces.internal.server.space.SpaceImpl.executeOperation(SpaceImpl.java:1826) at com.gigaspaces.internal.server.space.SpaceImpl.executeOperationAsync(SpaceImpl.java:1833) at com.gigaspaces.internal.remoting.RemoteOperationsExecutorGigaspacesMethodinternalInvoke3.internalInvoke(Unknown Source) at com.gigaspaces.internal.reflection.fast.AbstractMethod.invoke(AbstractMethod.java:41) at com.gigaspaces.lrmi.LRMIRuntime.invoked(LRMIRuntime.java:477) at com.gigaspaces.lrmi.nio.Pivot.consumeAndHandleRequest(Pivot.java:573) at com.gigaspaces.lrmi.nio.Pivot.handleRequest(Pivot.java:667) at com.gigaspaces.lrmi.nio.Pivot$ChannelEntryTask.run(Pivot.java:196) 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)

asked 2018-02-05 16:01:36 -0500

zhoujus gravatar image
edit retag flag offensive close merge delete

4 Answers

Sort by ยป oldest newest most voted
0

Hi Justin, You can try to add the related jars to the web-ui class path, by design we indeed avoid class loading and read space pojos as documents .

Regards, Ester.

answered 2018-02-15 07:02:14 -0500

Ester gravatar image
edit flag offensive delete link more
0

H Ester,

After trying a few things, we realized this could be the limitation of gs-webui. Seems like it could not handle non-standard Date and Set types. In our case they are org.hibernate.collection.internal.PersistentSet for the collections and com.sybase.jdbc4.tds.SybTimestamp for the Date. The gwt based ui could not handle those subclasses. We hacked the getter method to get around this, but with a performance hit. The setter hack does not work somehow.

Can gs webui be changed to handle those sub-types or the limitation is by design?

Thanks,

Justin

answered 2018-02-14 17:02:56 -0500

zhoujus gravatar image
edit flag offensive delete link more
0

Hi, Yes, it seems a bug pleas use our support portal to report it, so we can priority it and send a patch on a fix will be available.

Regards, Ester.

answered 2018-02-08 07:10:43 -0500

Ester gravatar image
edit flag offensive delete link more
0

Hi, Do you use oneToMany hibernate annotation on this field? (If so you might test the same using regular client with query result type Document and see if you get same issue)

Thanks, Ester.

answered 2018-02-06 07:02:36 -0500

Ester gravatar image
edit flag offensive delete link more

Comments

Hi Ester,

Thanks for the reply. Yes, the class has 2 unidirectional one-to-many collections.

I tried querying by document from a regular client as you suggested. It produced the same error:

gigaSpace.read(new SQLQuery<spacedocument>(SomePojoWithOneToManyCollections.class.getName(), "id = 94177", QueryResultType.DOCUMENT));

org.openspaces.core.ObjectConversionException: org.hibernate.LazyInitializationException: failed to lazily initialize a collection, could not initialize proxy - no Session; nested exception is com.gigaspaces.internal.metadata.converter.ConversionException: org.hibernate.LazyInitializationException: failed to lazily initialize a collection, could not initialize proxy - no Session

Is this a GS WebUI bug then?

Thanks,

Justin

zhoujus gravatar imagezhoujus ( 2018-02-07 10:51:19 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2018-02-05 16:01:36 -0500

Seen: 176 times

Last updated: Feb 15