Skip to Main Content

Integration

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Tuxedo and Postgres

3804333Dec 6 2018 — edited Dec 14 2018

Hi all,

I am going to use Postgres as resourse manager in Tuxedo XA-transactions.

As I recently learned Postgres doesn't support transaction migration between threads of control,

so I cannot in one transaction update some data in one service,

then call other service and see updated data in it,

because each service has its own database connection and

transaction cannot be associated with other connection.

I prepared XA resource manager switch for Postgres.

In xa_switch_t structure I set flag to TMNOMIGRATE.

In the implementation of xa_prepare() I execute "PREPARE TRANSACTION 'xid'".

This Postgres command should be executed inside transaction block, i.e. on connection

where I update my data. When I run my test program I see that xa_prepare()

was called not by my service, but by transaction manager server,

which has other database connection. Can I change this behaviour using Tuxedo settings

or I need to execute "PREPARE TRANSACTION 'xid'" directly inside my service?

Best regards,

Valery

Comments
Post Details
Added on Dec 6 2018
2 comments
763 views