-
Feb 3rd, 2012, 08:47 AM
#21
Last edited by danielgig; Feb 3rd, 2012 at 08:48 AM.
Reason: wrong link
-
Feb 3rd, 2012, 02:33 PM
#22
Not adding much to this thread. But Daniel, I highly recommend overriding equals and hashCode in domain objects. Because the default implementation is via ==, which is memory address. So theoretically you could have two domain objects that data wise are the same domain objects, but are two different objects in the heap, and therefore equals will return false.
While this isn't JPA or Hibernate here, it was required to override equals and hashCode because the apis underneath the querying would use it to make sure it never created two different instances with the same data from the db.
Especially since these methods are used extensively in Collections, which with data models like we have will have plenty Collections to work with.
Hope that helps
Mark
-
Feb 3rd, 2012, 05:10 PM
#23
Mark, Daniel,
if you want to add anything to the docs, please just fork the project edit the xml in the src/docbk directory and issue a pull request. Thanks a lot.
Michael
-
Nov 30th, 2012, 10:05 AM
#24
Unfortunatly, I'm having this issue. I have these seperations made (of the MVC controllers), I have the correct entry for <tx:annotation-driven mode="proxy" />, and have tried the others in this thread. But in my service, I get this exception. No issues with my tests, just actual code. It's just not getting wrapped in a transaction.
Last edited by treaves; Nov 30th, 2012 at 10:30 AM.
-
Jan 7th, 2013, 02:45 AM
#25
But your service is injected into your controllers?
-
Jan 7th, 2013, 07:27 AM
#26
-
Jan 9th, 2013, 02:46 AM
#27
Any chance to share the project / a sample project to look at?
If you get your service injected elsewhere or pull it directly from the context (e.g. in a single Main class), does the transaction work then?
-
Jan 9th, 2013, 09:06 AM
#28
The transactions only work if they are in the classes the services call, which is how I've been working around this. So both the service injection & transaction injection work, just not in the same classes.
I'll see about creating a sample project to show this; I have one I've used to demonstrate several other defects in the NEO4j code, so maybe it can be easily modified.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules