I am trying pool of pools again after a long time.
Connection Provider, it seems, indicates a Connection for a given Session obtained from a SessionFactory.
In a Pool of Pools scenario we attach a name for each pool (eg: PoolsForOracleDB, PoolsForFirebirdDB etc). I am not too sure how to bring in Pool of Pools using Connection Provider but for the same obtained Session!
Also, how to extend transaction for different connections from different Pools (PoolsForOracleDB, PoolsForFirebirdDB etc) in the same Session object? This way we can tx.commit() / s.flush() etc will ensure that connections to various databases is done in one shot in the same session.
Kindly help me with adivce and preferable a skeeton code if possible.
|