Notice: In order to edit this ticket you need to be either: a Product Owner, The owner or the reporter of the ticket, or, in case of a Task not yet assigned, a team_member"

Task #1195 (new)

Opened 11 years ago

Hibernate throws NPE and OMERO throws InternalException

Reported by: jamoore Owned by: jamoore
Priority: major Milestone: Unscheduled
Component: ORM Version: 3.0-M1
Keywords: n.a. Cc: jburel
Resources: n.a. Referenced By: n.a.
References: n.a. Remaining Time: n.a.
Sprint: n.a.

Description

Though it's actually a bug in Hibernate, we should probably present a cleaner exception to the user:

select link from ProjectAnnotationLink as link left outer join link.details as details where link.parent.id = :parentID
omero.InternalException
    serverStackTrace = "ome.conditions.InternalException:  Wrapped Exception: (java.lang.NullPointerException):
                        null
                        	at org.hibernate.hql.ast.HqlSqlWalker.createFromJoinElement(HqlSqlWalker.java:310)
                        	at org.hibernate.hql.antlr.HqlSqlBaseWalker.joinElement(HqlSqlBaseWalker.java:3275)
                        	at org.hibernate.hql.antlr.HqlSqlBaseWalker.fromElement(HqlSqlBaseWalker.java:3067)
                        	at org.hibernate.hql.antlr.HqlSqlBaseWalker.fromElementList(HqlSqlBaseWalker.java:2945)
                        	at org.hibernate.hql.antlr.HqlSqlBaseWalker.fromClause(HqlSqlBaseWalker.java:688)
                        	at org.hibernate.hql.antlr.HqlSqlBaseWalker.query(HqlSqlBaseWalker.java:544)
                        	at org.hibernate.hql.antlr.HqlSqlBaseWalker.selectStatement(HqlSqlBaseWalker.java:281)
                        	at org.hibernate.hql.antlr.HqlSqlBaseWalker.statement(HqlSqlBaseWalker.java:229)
                        	at org.hibernate.hql.ast.QueryTranslatorImpl.analyze(QueryTranslatorImpl.java:228)
                        	at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:160)
                        	at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:111)
                        	at org.hibernate.engine.query.HQLQueryPlan.<init>(HQLQueryPlan.java:77)
                        	at org.hibernate.engine.query.HQLQueryPlan.<init>(HQLQueryPlan.java:56)
                        	at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:72)
                        	at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:133)
                        	at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:112)
                        	at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623)
                        	at sun.reflect.GeneratedMethodAccessor195.invoke(Unknown Source)
                        	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                        	at java.lang.reflect.Method.invoke(Method.java:585)
                        	at org.springframework.orm.hibernate3.HibernateTemplate$CloseSuppressingInvocationHandler.invoke(HibernateTemplate.java:1289)
                        	at $Proxy52.createQuery(Unknown Source)
                        	at ome.services.query.StringQuery.buildQuery(StringQuery.java:57)
                        	at ome.services.query.Query.doInHibernate(Query.java:226)
                        	at org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:419)
                        	at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:339)
                        	at ome.logic.QueryImpl.execute(QueryImpl.java:129)
                        	at ome.logic.QueryImpl.findAllByQuery(QueryImpl.java:357)

Change History (0)

Note: See TracTickets for help on using tickets. You may also have a look at Agilo extensions to the ticket.

1.3.13-PRO © 2008-2011 Agilo Software all rights reserved (this page was served in: 0.75907 sec.)

We're Hiring!