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

Ask Your Question
0

an entry with the same index value already in space

UID of entry being persisted : 1328832648^42^2e9d4309-430d-4763-b962-022980a3ec63^0^0 Other UID : -1328832648^42^cb497c4e-08cf-4cdd-b646-b7ad7abfd441^0^0

IDs for above UIDs are 2e9d4309-430d-4763-b962-022980a3ec63 and cb497c4e-08cf-4cdd-b646-b7ad7abfd441 respectively.

Mirror is not persisting, complaining that the entry is duplicate. If you see above UID's, they are different values? Cannot figure out the reason.

Question : How is UID constructed and how will gigaspaces compare the 2 UIDs?

Caused by: com.j_spaces.core.client.DuplicateIndexValueException: Entry UID=-1328832648^42^2e9d4309-430d-4763-b962-022980a3ec63^0^0 class=com.csx.tp.shipment.space.model.ShipmentSO index=id value=2e9d4309-430d-4763-b962-022980a3ec63 rejected: an entry with the same index value already in space. otheruid=-1328832648^42^cb497c4e-08cf-4cdd-b646-b7ad7abfd441^0^0 at com.j_spaces.core.cache.TypeDataIndex.insertEntryIndexedField_impl(TypeDataIndex.java:439) ~[xap-datagrid.jar:?] at com.j_spaces.core.cache.TypeDataIndex.insertEntryIndexedField(TypeDataIndex.java:398) ~[xap-datagrid.jar:?] at com.j_spaces.core.cache.CacheManager.insertEntryReferences(CacheManager.java:3506) ~[xap-datagrid.jar:?] at com.j_spaces.core.cache.CacheManager.internalInsertEntryToCache(CacheManager.java:3403) ~[xap-datagrid.jar:?] at com.j_spaces.core.cache.CacheManager.insertEntryToCache(CacheManager.java:3252) ~[xap-datagrid.jar:?] at com.j_spaces.core.cache.CacheManager.insertEntry(CacheManager.java:1355) ~[xap-datagrid.jar:?] at com.j_spaces.core.server.processor.Processor.insertEntryToSpace(Processor.java:310) ~[xap-datagrid.jar:?] at com.j_spaces.core.server.processor.Processor.insertToSpaceLoop(Processor.java:257) ~[xap-datagrid.jar:?] at com.j_spaces.core.server.processor.Processor.handleDirectWriteSA(Processor.java:183) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.SpaceEngine.write(SpaceEngine.java:816) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.SpaceEngine.write(SpaceEngine.java:731) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.SpaceEngine.updateOrWrite(SpaceEngine.java:2264) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.SpaceEngine.updateOrWrite(SpaceEngine.java:2160) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.SpaceImpl.updateOrWrite(SpaceImpl.java:788) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.SpaceImpl.update(SpaceImpl.java:1867) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.operations.WriteEntrySpaceOperation.execute(WriteEntrySpaceOperation.java:41) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.operations.WriteEntrySpaceOperation.execute(WriteEntrySpaceOperation.java:29) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.operations.SpaceOperationsExecutor.executeOperation(SpaceOperationsExecutor.java:83) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.server.space.SpaceImpl.executeOperation(SpaceImpl.java:1733) ~[xap-datagrid.jar:?] at com.gigaspaces.internal.remoting.RemoteOperationsExecutorGigaspacesMethodinternalInvoke1.internalInvoke(Unknown Source) ~[?:?] at com.gigaspaces.internal.reflection.fast.AbstractMethod.invoke(AbstractMethod.java:45) ~[xap-datagrid.jar:?] at com.gigaspaces.lrmi.LRMIRuntime.invoked(LRMIRuntime.java:441) ~[xap-datagrid.jar:?] at com.gigaspaces.lrmi.nio.Pivot.consumeAndHandleRequest(Pivot.java:494) ~[xap-datagrid.jar:?] at com.gigaspaces.lrmi.nio.Pivot.handleRequest(Pivot.java:572) ~[xap-datagrid.jar:?] at com.gigaspaces.lrmi.nio.Pivot$ChannelEntryTask.run(Pivot.java:173) ~[xap-datagrid.jar:?] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[?:1.8.0_131] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) ~[?:1.8.0_131]

asked 2019-09-10 06:54:17 -0600

Sai K gravatar image
edit retag flag offensive close merge delete

Comments

Is the @SpaceId(autogenerate = true) ?? - Or is it unique based on the what field you are getting in the data ?

vinny gravatar imagevinny ( 2019-09-20 23:01:53 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
0

Hi, The exception you get complains about: rejected: an entry with the same index value already in space index id, meaning not same uid but rather id, both objects have id=42 and different uid does the class com.csx.tp.shipment.space.model.ShipmentSO has inheritance tree so you have 2 subclasses with the same id? is it LRU space? Please attach class tree definitions and pu.xml, you can use the support portal to further investigate.

Regards, Ester.

answered 2019-09-22 00:57:14 -0600

Ester gravatar image
edit flag offensive delete link more

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: 2019-09-10 06:54:17 -0600

Seen: 185 times

Last updated: Sep 22