These appear to be the "quick tip days" now. This is the third post in a row. This time I stumbled upon a very strange thing: While executing a simple save action from the XSP document I got the exception "You must provide an item name". Once I moved the document save in my bean and removed the simple action I was able to track the stack trace down to a native method from the XSP runtime - lucky me that it wasn't from my own code, but on the other hand this didn't give me a chance to work it around. Here is the stacktrace I got:
Error while saving document at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:102) at
As you can see, it's all "home made" stuff. Of course there are several other causes for this, e.g. an empty fieldname in
The problem only occurred after a partial refresh which was triggered from one of my elements on the page (here it was a drag-and-drop area). After I tested several things (which took me several hours) I had a closer look at this partial refresh. The drag-and-drop script finally issued that partial refresh using the
XSP.partialRefreshPost method. The refresh ID that was used somehow was not found on my page. Usually I'd have expected an error when referencing a partial refresh ID that's not there but it seems that this method ignores that. To be clear: there was a refresh event, values and texts were refreshed - so it was executed. As I mentioned before: after that refresh the save action failed.
I finally changed the refresh ID to an existing ID on my page - and et voilá, the exception was never seen again.
If you ever stumble upon this problem, check your refresh IDs being used!