Of ExceptionResolvers and XMLBeans
Using a custom ExceptionResolver in Spring Web Services to insert a Detail into a SoapFault.
Using a custom ExceptionResolver in Spring Web Services to insert a Detail into a SoapFault.
We all have those problems that we encounter just infrequently enough that when we see them again, we know we’ve solved this, but can’t remember how.
The NonUniqueObjectException thrown when using Session.saveOrUpdate() in Hibernate is one of mine. I’ll be adding new functionality to a complex application. All my unit tests work fine. Then in testing [...]
Here’s another problem that has a simple solution that took me longer than I expected to find.
I am using Hibernate 3.2.5 as my ORM. In one case, I want to map a child collection of items as an ordered List, taking advantage of the database to do my ordering.
I’m using Annotations intead of the [...]
This is one of those problems that I couldn’t find a complete example for when I needed it, so hopefully this will save somebody else the extra time it took me to piece it together.
We frequently need to have data tables in our UI, and allow the user to select a subset of those items [...]
In a comment to my previous post about configuring JMS via Spring, Vikas Kadam asked about configuring a connection to a secure TIBCO EMS topic or queue. As fate would have it, the next issue I dealt with was adding this to my own application. What worked for me was using Spring’s UserCredentialsConnectionFactoryAdapter as my [...]
I’ve spent several days, off and on, wrestling with a chicken-and-egg configuration issue.
I have an application that uses Spring 2.0 and is deployed to Tomcat 5.5. We make heavy use of Tomcat’s JNDI for configuring things like our database connections.
We’re adding JMS functionality to our application; at this point, we merely need to send events [...]
We’re using XMLBeans as part of a project. I had a document called EventConfig that had many EventDetails. I needed to find one EventDetails element based on its child element, EventName.
Being new to XMLBeans, and in bug fixing mode, I checked the XmlObject API, and saw only that selectPath(String) took a String. I couldn’t [...]
The Java Tutorial gives the standard definition of the protected access modifier:
The protected modifier specifies that the member can only be accessed within its own package (as with package-private) and, in addition, by a subclass of its class in another package.
But what does this mean in practice? I see a lot of confusion that [...]
I’ve seen several programmers struggle with a similar question. They create a collection of some sort, and add items to it in a loop. When they finish the loop and try to use the collection (or list, or array, or set, or map) it looks like every single object in the collection is the same [...]
This post on the JavaRanch Big Moose Saloon led me to fire up Eclipse and write some test code. The question is basically how can you use the ability to map a parent bean as part of a bean definition in Spring.
Let’s look at three classes and see how they can be mapped using Spring.
public [...]