RPC Calls ( and notes in 9) to the rescue

After a little downtime on the xPages departement I started to do some xPages again ( a few weeks ago ). Today I faced the following problem. We want to transfer data from one app to the other to generate Word documents using a xpage control. The problem is that the call is done in the ‘website’ ┬ádatabase and the real logic is stored in the ‘data’ ┬ádatabase. The word document is also generated clientside (don’t ask). So I needed to find a way to transfer data from one app to the other.

I first made the obvious error to set a sessionScope and to get that scope at the other application. But since scopes are not inherited (ofcourse..) that didn’t work. The thing I didn’t want was to add multiple url parameters to acccess the other database. So what’s next?

the Remote procedure call! A colleague told me that they are are using RPC’s all over the application currently and maybe that could be a solution. There was only one problem. I didn’t even know that was possible nowadays in xPages. So I first browsed the source to find the current RPC’s and started to create my own.. but all I’ve got was a call that did throw errors all over the place.

To resolve the issue I checked www.notesin9.com to see if there was someone who did a session in the past about RPCs. And yes there is. John Jardin, who is a great speaker by the way, did a vid about RPC’s. Its very basic but it’s just enough for me to get started!

What would xPages be without http://notesin9.com/ and John Jardin…?