A
Alisa Jackson
We have an application (java on top of oracle) which is primarily
accessed through RMI. A customer asked to make the API transactional
so that they would have the explicit control over
start/commit/rollback of any changes our app does to the database.
What are some standard approaches for doing this? The only obvious
thing seems to be to expose some integer transactionId as an argument
to every method of the API and then pass that transactionId from the
client to the server and down the call stack until it gets to the
point where the actual DB operation is occurring and then use the
Connection associated with that transactionId.
This seems ugly on many levels. One is that the client needs to pass
around this transactionId, and even worse all the internal interfaces
need to be modified to pass around the transactionId between methods.
Do you have any better suggestions on how to address this? The project
has some time so we want to have a proper solution for it, preferrably
one that does not require purchasing third party software.
Thanks,
- alisa
accessed through RMI. A customer asked to make the API transactional
so that they would have the explicit control over
start/commit/rollback of any changes our app does to the database.
What are some standard approaches for doing this? The only obvious
thing seems to be to expose some integer transactionId as an argument
to every method of the API and then pass that transactionId from the
client to the server and down the call stack until it gets to the
point where the actual DB operation is occurring and then use the
Connection associated with that transactionId.
This seems ugly on many levels. One is that the client needs to pass
around this transactionId, and even worse all the internal interfaces
need to be modified to pass around the transactionId between methods.
Do you have any better suggestions on how to address this? The project
has some time so we want to have a proper solution for it, preferrably
one that does not require purchasing third party software.
Thanks,
- alisa