1. Go to weblogic server and click on Data Sources under Services.
Click on New>Generic Data Source.
Give a name for the data source. Leave the Scope as Global. JNDI should be jdbc/<Your data source name>. Then click Next.
Select the Database Driver as below if not already selected. Click Next.
Uncheck the option Supports Global Transactions, and leave all the default options. Click Next.
Now, give your database connection details and click Next.
In the next step, click on Test Configuration.
It should give the message as 'Connection test succeeded' if your connection details are correct. Click Next.
Select the target servers and click Finish. In my case, it is DefaultServer since it is integration weblogic server.
After clicking Finish, you should see the message as below.
Now, you should see your defined data source under data sources. If it is not available in the list, click Next.
Now, go back to Deployments.
Below step is optional but if you check the Exclude libraries option, it'll be easier for you to go to DBAdapater without clicking on Next to search for it every time. To exclude libraries, just expand the Customize this table option and check 'Exclude libraries when displaying deployments'. Click Apply.
Now you click on DBAdapter.
Go to Configuration>Outbound Connection Pools. Click New.
Click Next.
Give a JNDI name and click Finish.
You'll see the messages as below.
Now check the checkbox of DBAdapter. Click Update.
Click Next.
Click Finish.
Below messages will be populated.
Now, go to Deployments, click on DBAdapter>Configuration>Outbound Connection Pools. Expand the list and click on your connection.
Give your jdbc/<your connection name> under property value of XADataSourceName. Press enter and then save. If you don't press enter after entering the value, it won't take the value.
Now go back to Deployments one last time. Check DBAdapter and click Update.
Click Next.
Click Finish.
You'll see the messages as below.
Congratulations, you've configured database adapter on your own. Now, deploy and test your services with db adapter. Cheers!!
No comments:
Post a Comment