Looks good - thanks.
Type: Posts; User: reginald.blank; Keyword(s):
Looks good - thanks.
I wonder if making the comment an element collection would work.
I'll give it a try and let you know.
I originall wanted to use an embeddable but couldn't see a way to create it from the roo...
Apologies if this appears twice - the last submit didn't appear to work.
I have an entity called Issue which has a set (collection) of Comment entities.
The relationship is (currently)...
Okay, it looks like no one is able to help with the specific problem. I guess the next question is how do I debug and troubleshoot the code that is produced by the @Transactional AOP annotation...
You could also wrap up the TaskExecutor in another service that runs a runnable within a @Transactional annotated method. This is what you are doing now - just accept that the 2nd @Component is a...
I could be wrong, but I believe this behaviour is expected. The Spring Aspect code that wraps the service method in a transaction can only intercept calls from outside the service - not calls within...
I am nesting an @Transactional service call within an HTTP request that is filtered using OpenSessionInViewFilter (OSIVF). It is my (perhaps incorrect) understanding that while the OSIVF has...
As suggested I removed the bean definitions from the XML and just used annotations. The dependency gets correctly injected. Thanks for the help.
Thanks for all the feedback.
I also tried @Autowired and that didn't work either.
I did wonder if the whole thing was a bit over the top since I don't need it to convert Person ids in the...
If I remove the @Repository annotation on the person dao and move it into the servlet context xml then the dependency gets injected.
I guess this means that the annotation is being ignored. I have...
In order to correctly bind a unique entity ID to an object in a controller I am using a custom property editor (that needs to do a database lookup) that registered using the following beans in the...
First of all, sorry for the poor spelling of Entitie's - should have been Entity's.
It looks like I can use a table:table tag in the create.jspx, but I don't know how to filter by objects...
Is it possible to include a sub table for creating, viewing and editing an entity's associated objects from the entity's view? The associated objects only make sense when the are created with the...
I could get an existing user out of the database and use that to create a UsernameAndPasswordAuthenticationToken which I get the injected authentication manager to authentication before finally...
I want to run some setup code with a particular authenication. This code is run when the web app starts up - not as the result of an HTTP request etc. What is the best practice for setting the...
Where should I secure my web application on services (this appears to be the popular choice) or DAOs?
I prefer the former because it avoids coupling the database tier to the security. I prefer the...
I have a controller that gets a list of object IDs a user wants to delete. These are passed to a service which gets the matching objects from the database and tries to delete each one in a separate,...
I, aherm, found my servlet configuration used twice: once in web.xml the other in the dispatcher servlet config. It contains my scanned packages too. That must have mucked things up. Can you still...
I had a problem with my method security being ignored and it only worked when I seemed to take the opposite advice to that in the FAQ. I've quoted the advice here, along with my understanding. Can...
(My apology for lifting some of this from
I'm adding ACLs to an existing spring hibernate project and I am getting a:
java.lang.IllegalArgumentException: Transaction must be running
...
Yes, it looks like I can have MultipleTransactionManagers, but I have to specify which one I'm using in the @Transactional annotation - a bit of a problem when all the code is in the same method....
I have
<tx:annotation-driven />
and
I'm adding ACLs to an existing spring hibernate project and I am getting a:
java.lang.IllegalArgumentException: Transaction must be running
exception in the following method:
Thanks for the helpful reply. My response is inline...
That's not the case. As I mentioned in the original post the transactions are working for code called by the context, e.g. bean...
I've added an OpenSessionInViewInterceptor (OSIVI) to my code to allow my JSPs to access lazily loaded associations. I already had a transaction manager setup and my services make use of the...