JTA is (default) transaction manager for EJB3,
From where it obtains information about my database? from where it (JTA) obtains info regarding my databses, user password, url etc..
if you are reading EJB3 In Action, then check out "
Listing 11.6 An example persistence.xml, page 411";
where user provides, transaction-type = "JTA", provider=toplink & jta-data-source=dataSourceName
In your application server you provide information for
dataSource - i.e. dsName, user, password
check out
page 415 of EJB3IA for glassfish App. server DataSource settings....
Container will start transaction on which Connection (database) Object?
if you are ware of ACID properties of transaction which means (in short) all done (commit everything) or nothing (rollback everything),
so all the resources (connections) enclosed in boundary of transaction will participate in transaction.
What does the statement means "The container automatically enlists con1 and con2 with the container-manager transaction"?
container-manager transaction > user is not writing any transaction mgmt code, user is just asking for transaction service
container is initiating transaction service & con1 & con2 are participating...
hope it may be helpful...