Exception occurs when trying to create a new concept

classic Classic list List threaded Threaded
12 messages Options
Ishara Premadasa-2 Ishara Premadasa-2
Reply | Threaded
Open this post in threaded view
|

Exception occurs when trying to create a new concept

Hi,

I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.

An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept

(The full error stack trace output is in the source of this page.)

I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?


--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.


[hidden email] from OpenMRS Developers' mailing list
Mark Goodrich-2 Mark Goodrich-2
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

Fyi, it looks like this is the offending part of the code:

 

at org.openmrs.web.controller.ConceptFormController$ConceptFormBackingObject.getNumberOfObsUsingThisConcept(ConceptFormController.java:913)

 

Assumedly, something within this method call is causing a flush, and the Concept is transient as this point, because it is new.  It looks like the page is trying to read some statistical data about a concept, which is really only relevant when viewing/editing an existing concept.

 

Mark

 

 

 

From: [hidden email] [mailto:[hidden email]] On Behalf Of Ishara Premadasa
Sent: Friday, May 11, 2012 10:02 AM
To: [hidden email]
Subject: [OPENMRS-DEV] Exception occurs when trying to create a new concept

 

Hi,

I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.

An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept

(The full error stack trace output is in the source of this page.)

I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?

 

--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
Steven Githens Steven Githens
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

This may have appeared in trunk-3044 that I added last week.  It looks like I left off a few Transaction = readonly attributes on some new methods in ProgramWorkFlowService, but even after adding them, I'm still seeing this. ( and from Marks comment below, it appears it's actually coming from an existing ConceptService method. )

I'm wondering if the sidebar with the concept usage information should just be left out in the JSP conditionally if this is a new concept, and left in if you're editing an existing concept?

-Steve

On 05/11/2012 10:36 AM, Mark Goodrich wrote:

Fyi, it looks like this is the offending part of the code:

 

at org.openmrs.web.controller.ConceptFormController$ConceptFormBackingObject.getNumberOfObsUsingThisConcept(ConceptFormController.java:913)

 

Assumedly, something within this method call is causing a flush, and the Concept is transient as this point, because it is new.  It looks like the page is trying to read some statistical data about a concept, which is really only relevant when viewing/editing an existing concept.

 

Mark

 

 

 

From: [hidden email] [[hidden email]] On Behalf Of Ishara Premadasa
Sent: Friday, May 11, 2012 10:02 AM
To: [hidden email]
Subject: [OPENMRS-DEV] Exception occurs when trying to create a new concept

 

Hi,

I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.

An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept

(The full error stack trace output is in the source of this page.)

I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?

 

--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
Darius Jazayeri-3 Darius Jazayeri-3
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

I'd have thought that the sidebar with usage information is only for viewing the concept, not for editing it...

-Darius

On Fri, May 11, 2012 at 8:39 AM, Steven Githens <[hidden email]> wrote:
This may have appeared in trunk-3044 that I added last week.  It looks like I left off a few Transaction = readonly attributes on some new methods in ProgramWorkFlowService, but even after adding them, I'm still seeing this. ( and from Marks comment below, it appears it's actually coming from an existing ConceptService method. )

I'm wondering if the sidebar with the concept usage information should just be left out in the JSP conditionally if this is a new concept, and left in if you're editing an existing concept?

-Steve


On 05/11/2012 10:36 AM, Mark Goodrich wrote:

Fyi, it looks like this is the offending part of the code:

 

at org.openmrs.web.controller.ConceptFormController$ConceptFormBackingObject.getNumberOfObsUsingThisConcept(ConceptFormController.java:913)

 

Assumedly, something within this method call is causing a flush, and the Concept is transient as this point, because it is new.  It looks like the page is trying to read some statistical data about a concept, which is really only relevant when viewing/editing an existing concept.

 

Mark

 

 

 

From: [hidden email] [[hidden email]] On Behalf Of Ishara Premadasa
Sent: Friday, May 11, 2012 10:02 AM
To: [hidden email]
Subject: [OPENMRS-DEV] Exception occurs when trying to create a new concept

 

Hi,

I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.

An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept

(The full error stack trace output is in the source of this page.)

I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?

 

--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
Steven Githens Steven Githens
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

Hello,

On 05/11/2012 12:23 PM, Darius Jazayeri wrote:
I'd have thought that the sidebar with usage information is only for viewing the concept, not for editing it...


The UI Design on the ticket had a "Edit Concept" title on it, so I guessed it would be both for viewing and editing concepts.  Also, some of the metadata (like Questions Answered, etc) that got moved to the sidebar, I believe was also on the edit page before being moved to the sidebar.   It seems like some of that information may by useful for taking in to account when you're editing a concept.

I can remove it either for all editing, or when just editing a new unsaved concept.

-s


-Darius

On Fri, May 11, 2012 at 8:39 AM, Steven Githens <[hidden email]> wrote:
This may have appeared in trunk-3044 that I added last week.  It looks like I left off a few Transaction = readonly attributes on some new methods in ProgramWorkFlowService, but even after adding them, I'm still seeing this. ( and from Marks comment below, it appears it's actually coming from an existing ConceptService method. )

I'm wondering if the sidebar with the concept usage information should just be left out in the JSP conditionally if this is a new concept, and left in if you're editing an existing concept?

-Steve


On 05/11/2012 10:36 AM, Mark Goodrich wrote:

Fyi, it looks like this is the offending part of the code:

 

at org.openmrs.web.controller.ConceptFormController$ConceptFormBackingObject.getNumberOfObsUsingThisConcept(ConceptFormController.java:913)

 

Assumedly, something within this method call is causing a flush, and the Concept is transient as this point, because it is new.  It looks like the page is trying to read some statistical data about a concept, which is really only relevant when viewing/editing an existing concept.

 

Mark

 

 

 

From: [hidden email] [[hidden email]] On Behalf Of Ishara Premadasa
Sent: Friday, May 11, 2012 10:02 AM
To: [hidden email]
Subject: [OPENMRS-DEV] Exception occurs when trying to create a new concept

 

Hi,

I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.

An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept

(The full error stack trace output is in the source of this page.)

I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?

 

--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
Andrew Kanter Andrew Kanter
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

In reply to this post by Darius Jazayeri-3
It seems that it would be relevant to know how the concept was being used BEFORE editing it. It makes no sense to have this with New concepts that aren't used anywhere and haven't even been submitted....

Andy
 
--------------------
Andrew S. Kanter, MD MPH

Asst. Prof. of Clinical Biomedical Informatics and Clinical Epidemiology
Columbia University
Email: [hidden email]
Mobile: +1 (646) 469-2421
Office: +1 (212) 305-4842
Skype: akanter-ippnw
Yahoo: andy_kanter


From: Darius Jazayeri <[hidden email]>
To: [hidden email]
Sent: Friday, May 11, 2012 12:23 PM
Subject: Re: [OPENMRS-DEV] Exception occurs when trying to create a new concept

I'd have thought that the sidebar with usage information is only for viewing the concept, not for editing it...

-Darius

On Fri, May 11, 2012 at 8:39 AM, Steven Githens <[hidden email]> wrote:
This may have appeared in trunk-3044 that I added last week.  It looks like I left off a few Transaction = readonly attributes on some new methods in ProgramWorkFlowService, but even after adding them, I'm still seeing this. ( and from Marks comment below, it appears it's actually coming from an existing ConceptService method. )

I'm wondering if the sidebar with the concept usage information should just be left out in the JSP conditionally if this is a new concept, and left in if you're editing an existing concept?

-Steve


On 05/11/2012 10:36 AM, Mark Goodrich wrote:
Fyi, it looks like this is the offending part of the code:
 
at org.openmrs.web.controller.ConceptFormController$ConceptFormBackingObject.getNumberOfObsUsingThisConcept(ConceptFormController.java:913)
 
Assumedly, something within this method call is causing a flush, and the Concept is transient as this point, because it is new.  It looks like the page is trying to read some statistical data about a concept, which is really only relevant when viewing/editing an existing concept.
 
Mark
 
 
 
From: [hidden email] [[hidden email]] On Behalf Of Ishara Premadasa
Sent: Friday, May 11, 2012 10:02 AM
To: [hidden email]
Subject: [OPENMRS-DEV] Exception occurs when trying to create a new concept
 
Hi,
I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.
An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept
(The full error stack trace output is in the source of this page.)
I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?
 
--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.

[hidden email] from OpenMRS Developers' mailing list

[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list



[hidden email] from OpenMRS Developers' mailing list
Darius Jazayeri-3 Darius Jazayeri-3
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

Go ahead and remove it for the new concept case, but leave it for editing an existing concept.

(Not having looked at it, I expect this to be ugly in the UI, but I'll reserve judgment until I've looked.)

-Darius

On Fri, May 11, 2012 at 9:36 AM, Andrew Kanter <[hidden email]> wrote:
It seems that it would be relevant to know how the concept was being used BEFORE editing it. It makes no sense to have this with New concepts that aren't used anywhere and haven't even been submitted....

Andy
 
--------------------
Andrew S. Kanter, MD MPH

Asst. Prof. of Clinical Biomedical Informatics and Clinical Epidemiology
Columbia University
Email: [hidden email]
Mobile: <a href="tel:%2B1%20%28646%29%20469-2421" value="+16464692421" target="_blank">+1 (646) 469-2421
Office: <a href="tel:%2B1%20%28212%29%20305-4842" value="+12123054842" target="_blank">+1 (212) 305-4842
Skype: akanter-ippnw
Yahoo: andy_kanter


From: Darius Jazayeri <[hidden email]>
To: [hidden email]
Sent: Friday, May 11, 2012 12:23 PM
Subject: Re: [OPENMRS-DEV] Exception occurs when trying to create a new concept

I'd have thought that the sidebar with usage information is only for viewing the concept, not for editing it...

-Darius

On Fri, May 11, 2012 at 8:39 AM, Steven Githens <[hidden email]> wrote:
This may have appeared in trunk-3044 that I added last week.  It looks like I left off a few Transaction = readonly attributes on some new methods in ProgramWorkFlowService, but even after adding them, I'm still seeing this. ( and from Marks comment below, it appears it's actually coming from an existing ConceptService method. )

I'm wondering if the sidebar with the concept usage information should just be left out in the JSP conditionally if this is a new concept, and left in if you're editing an existing concept?

-Steve


On 05/11/2012 10:36 AM, Mark Goodrich wrote:
Fyi, it looks like this is the offending part of the code:
 
at org.openmrs.web.controller.ConceptFormController$ConceptFormBackingObject.getNumberOfObsUsingThisConcept(ConceptFormController.java:913)
 
Assumedly, something within this method call is causing a flush, and the Concept is transient as this point, because it is new.  It looks like the page is trying to read some statistical data about a concept, which is really only relevant when viewing/editing an existing concept.
 
Mark
 
 
 
From: [hidden email] [[hidden email]] On Behalf Of Ishara Premadasa
Sent: Friday, May 11, 2012 10:02 AM
To: [hidden email]
Subject: [OPENMRS-DEV] Exception occurs when trying to create a new concept
 
Hi,
I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.
An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept
(The full error stack trace output is in the source of this page.)
I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?
 
--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.

[hidden email] from OpenMRS Developers' mailing list

[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list



[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
Burke Mamlin Burke Mamlin
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

Agreed that usage information for a new concept doesn't make sense; however, if the sidebar contains links to similar concepts and/or resources (like lab websites for definitions), those were specifically meant to be useful during concept creation – e.g., after you enter the new concept's name and click on similar concepts, you find that you have already defined the concept; when adding a new concept for a lab test, you use the link to look up a good definition for it; etc.

-Burke

On Fri, May 11, 2012 at 1:12 PM, Darius Jazayeri <[hidden email]> wrote:
Go ahead and remove it for the new concept case, but leave it for editing an existing concept.

(Not having looked at it, I expect this to be ugly in the UI, but I'll reserve judgment until I've looked.)

-Darius

On Fri, May 11, 2012 at 9:36 AM, Andrew Kanter <[hidden email]> wrote:
It seems that it would be relevant to know how the concept was being used BEFORE editing it. It makes no sense to have this with New concepts that aren't used anywhere and haven't even been submitted....

Andy
 
--------------------
Andrew S. Kanter, MD MPH

Asst. Prof. of Clinical Biomedical Informatics and Clinical Epidemiology
Columbia University
Email: [hidden email]
Mobile: <a href="tel:%2B1%20%28646%29%20469-2421" value="+16464692421" target="_blank">+1 (646) 469-2421
Office: <a href="tel:%2B1%20%28212%29%20305-4842" value="+12123054842" target="_blank">+1 (212) 305-4842
Skype: akanter-ippnw
Yahoo: andy_kanter


From: Darius Jazayeri <[hidden email]>
To: [hidden email]
Sent: Friday, May 11, 2012 12:23 PM
Subject: Re: [OPENMRS-DEV] Exception occurs when trying to create a new concept

I'd have thought that the sidebar with usage information is only for viewing the concept, not for editing it...

-Darius

On Fri, May 11, 2012 at 8:39 AM, Steven Githens <[hidden email]> wrote:
This may have appeared in trunk-3044 that I added last week.  It looks like I left off a few Transaction = readonly attributes on some new methods in ProgramWorkFlowService, but even after adding them, I'm still seeing this. ( and from Marks comment below, it appears it's actually coming from an existing ConceptService method. )

I'm wondering if the sidebar with the concept usage information should just be left out in the JSP conditionally if this is a new concept, and left in if you're editing an existing concept?

-Steve


On 05/11/2012 10:36 AM, Mark Goodrich wrote:
Fyi, it looks like this is the offending part of the code:
 
at org.openmrs.web.controller.ConceptFormController$ConceptFormBackingObject.getNumberOfObsUsingThisConcept(ConceptFormController.java:913)
 
Assumedly, something within this method call is causing a flush, and the Concept is transient as this point, because it is new.  It looks like the page is trying to read some statistical data about a concept, which is really only relevant when viewing/editing an existing concept.
 
Mark
 
 
 
From: [hidden email] [[hidden email]] On Behalf Of Ishara Premadasa
Sent: Friday, May 11, 2012 10:02 AM
To: [hidden email]
Subject: [OPENMRS-DEV] Exception occurs when trying to create a new concept
 
Hi,
I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.
An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept
(The full error stack trace output is in the source of this page.)
I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?
 
--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.

[hidden email] from OpenMRS Developers' mailing list

[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list



[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
Steven Githens Steven Githens
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

In reply to this post by Darius Jazayeri-3
Not sure how this list deals with attachments, but attached is a screen of the sidebar while editing an existing concept.

-s

On 05/11/2012 01:12 PM, Darius Jazayeri wrote:
Go ahead and remove it for the new concept case, but leave it for editing an existing concept.

(Not having looked at it, I expect this to be ugly in the UI, but I'll reserve judgment until I've looked.)

-Darius



[hidden email] from OpenMRS Developers' mailing list

editing-with-sidebar.png (157K) Download Attachment
Ben Wolfe (openmrs) Ben Wolfe (openmrs)
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

Yeah, just hide that lower box when creating a concept.  The upper box queries gets changed by javascript when typing the name and so a user /could/ click them when creating (not sure they ever have been clicked though)

Ben

On Fri, May 11, 2012 at 1:58 PM, Steven Githens <[hidden email]> wrote:
Not sure how this list deals with attachments, but attached is a screen of the sidebar while editing an existing concept.

-s


On 05/11/2012 01:12 PM, Darius Jazayeri wrote:
Go ahead and remove it for the new concept case, but leave it for editing an existing concept.

(Not having looked at it, I expect this to be ugly in the UI, but I'll reserve judgment until I've looked.)

-Darius



[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
Steven Githens Steven Githens
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept

In reply to this post by Ishara Premadasa-2
Ishara,

I think this should be fixed in r27354, can you give it a go?

Cheers,
Steve

On 05/11/2012 10:01 AM, Ishara Premadasa wrote:

Hi,

I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.

An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept

(The full error stack trace output is in the source of this page.)

I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?


--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list
ishara premadasa ishara premadasa
Reply | Threaded
Open this post in threaded view
|

Re: Exception occurs when trying to create a new concept



On Fri, May 11, 2012 at 11:58 PM, Steven Githens <[hidden email]> wrote:
Ishara,

I think this should be fixed in r27354, can you give it a go?

Yes, i updated the repo and tried again. The concept page now loads and works fine.
Thank you very much!

Cheers,
Steve


On 05/11/2012 10:01 AM, Ishara Premadasa wrote:

Hi,

I was trying to create a new concept with the latest trunk today for my gsoc project related work and it throws the following exception and page is not fully loaded.

An error has occurred!
The following error happened somewhere on this page:
javax.el.ELException: org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: org.openmrs.Concept

(The full error stack trace output is in the source of this page.)

I have created a ticket for this in https://tickets.openmrs.org/browse/TRUNK-3345 . Can someone please have a look and help me?


--
Ishara Premadasa,
Google Summer of Code Intern 2012,
Dept. of Computer Science and Engineering,
University of Moratuwa,
Sri Lanka.


[hidden email] from OpenMRS Developers' mailing list


[hidden email] from OpenMRS Developers' mailing list



--
Best Regards.

Ishara Premadasa,
Final Year Undergraduate,
Dept. of Computer Science & Engineering,
University of Moratuwa
Sri Lanka.




[hidden email] from OpenMRS Developers' mailing list