Project

General

Profile

Actions

bug #10090

closed

Many LIEs in cdmserver log for Team.getCollectorTitleCache()

Added by Andreas Müller almost 2 years ago. Updated over 1 year ago.

Status:
Closed
Priority:
Priority14
Category:
cdmlib
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Severity:
critical
Found in Version:

Description

from int cdmserver (startup.log)

Caused by: org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: eu.etaxonomy.cdm.model.agent.Team.teamMembers, could not initialize proxy - no Session
        at org.hibernate.collection.internal.AbstractPersistentCollection.throwLazyInitializationException(AbstractPersistentCollection.java:606) ~[hibernate-core-5.4.33.Final.jar:5.4.33.Final]
        at org.hibernate.collection.internal.AbstractPersistentCollection.withTemporarySessionIfNeeded(AbstractPersistentCollection.java:218) ~[hibernate-core-5.4.33.Final.jar:5.4.33.Final]
        at org.hibernate.collection.internal.AbstractPersistentCollection.readSize(AbstractPersistentCollection.java:162) ~[hibernate-core-5.4.33.Final.jar:5.4.33.Final]
        at org.hibernate.collection.internal.PersistentList.size(PersistentList.java:137) ~[hibernate-core-5.4.33.Final.jar:5.4.33.Final]
        at eu.etaxonomy.cdm.strategy.cache.agent.TeamDefaultCacheStrategy.getCache(TeamDefaultCacheStrategy.java:174) ~[cdmlib-model-5.32.0-SNAPSHOT.jar:?]
        at eu.etaxonomy.cdm.strategy.cache.agent.TeamDefaultCacheStrategy.getCollectorTitleCache(TeamDefaultCacheStrategy.java:167) ~[cdmlib-model-5.32.0-SNAPSHOT.jar:?]
        at eu.etaxonomy.cdm.strategy.cache.agent.TeamDefaultCacheStrategy.getCollectorTitleCache(TeamDefaultCacheStrategy.java:1) ~[cdmlib-model-5.32.0-SNAPSHOT.jar:?]
        at eu.etaxonomy.cdm.model.agent.Team.getCollectorTitleCache(Team.java:359) ~[cdmlib-model-5.32.0-SNAPSHOT.jar:?]
~~

Related issues

Related to EDIT - bug #9949: doGetSynonymy throws LIE in Mexico PortalClosedAndreas Müller

Actions
Actions #1

Updated by Andreas Müller almost 2 years ago

maybe related to #9949

Actions #2

Updated by Andreas Müller almost 2 years ago

  • Related to bug #9949: doGetSynonymy throws LIE in Mexico Portal added
Actions #3

Updated by Andreas Müller almost 2 years ago

  • Status changed from New to Resolved
  • % Done changed from 0 to 70
Actions #5

Updated by Andreas Müller almost 2 years ago

The reason was a missing property path for secsource authors.

The reason why it happened for collectorTitleCache is that titleCaches are generally not computed if not null (related to #5849) and nomenclaturalTitleCaches in this test data are protected.

More generally spoken, the secundum authorteam is initialized by TitleAndNameCacheAutoInitializer but not necessarily the team members. Json serialization later (out of session) will try to read the authorteam bean and this throws an exception when team.getCollectorTitleCache() is called.

The final solution I decided for is now to catch LIEs in team.getCollectorTitleCache() if the precomputed collectorTitleCache is not null. This is acceptable as we do not expected the collectorTitleCache to be needed in this context and anyway the precomputed collectorTitleCache is correct in most cases.

Actions #6

Updated by Andreas Müller over 1 year ago

  • Assignee changed from Andreas Müller to Katja Luther

Should be fixed. Please review.

Actions #7

Updated by Andreas Müller over 1 year ago

  • Priority changed from Highest to Priority14
Actions #8

Updated by Andreas Müller over 1 year ago

  • Status changed from Resolved to Closed
  • Assignee changed from Katja Luther to Andreas Müller
  • % Done changed from 70 to 100
Actions

Also available in: Atom PDF