{"id":1995,"date":"2010-07-06T14:50:05","date_gmt":"2010-07-06T06:50:05","guid":{"rendered":"http:\/\/www.finereport.com\/CN\/wordpress\/knowledge\/install\/weblogic-10-1%e9%85%8d%e7%bd%aejndi%e6%95%b0%e6%8d%ae%e6%ba%90.html"},"modified":"2020-08-31T09:05:58","modified_gmt":"2020-08-31T01:05:58","slug":"weblogic","status":"publish","type":"post","link":"https:\/\/frg.fineres.com\/en\/2010\/07\/06\/weblogic\/","title":{"rendered":"Weblogic 10.1 configure JNDI datasource"},"content":{"rendered":"<p><b>NO.1 JNDI connection using the principles<\/b><\/p>\n<ol>\n<li>In the Report Designer to use JDBC to connect to the database, create a database connection, and then create a dataset using SQL or other methods, making better use of data collection <a title=\"reports\" href=\"https:\/\/www.finereport.com\/en\/\" target=\"_blank\" rel=\"noopener noreferrer\">reports<\/a>, and then establish a connection to the database from JDBC connection into JNDI connection, save the report template and deploy to weblogic server.<\/li>\n<li>Reports server configuration data sources.<\/li>\n<li>Modify the application web.xml file under WEB-INF.<\/li>\n<\/ol>\n<p><!--more--><\/p>\n<p>So that you can browse through a WEB browser to use the report of the JNDI data sources.<\/p>\n<p><b>NO.2 Our oracle 10g data source produced an example to illustrate the template jndi.cpt<\/b><\/p>\n<ol>\n<li>Report Designer create reports:In the designer using JDBC to connect to oracle 10g database, using the data in the database table student produced the following template jndi.cpt:<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/dd1.jpg\" alt=\"finereport\u62a5\u8868\u6570\u636e\u96c6\" \/><\/p>\n<p>Back to the definition of a data connection panel, previously defined database connection becomes JNDI connection, set the JNDI name for the oracle<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/mod-dc.jpg\" alt=\"Modify the report data connection\" \/><\/p>\n<p>Save the template to the application directory under weblogic 10 WebReport \/ WEB-INF \/ reportlets, save for jndi.cpt. At this point the server side data source is not configured, start the server and access the jndi report shows an error similar to the following:<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/error.jpg\" alt=\"The data source is not configured error\" \/><\/li>\n<li>Server-side configuration data sources:Open weblogic control interface 10: http: \/\/ localhost: 7001 \/ console; login weblogic server domain select the domain structure | Services | JDBC | Data Sources to open the data source configuration interface:<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/weblogic.jpg\" alt=\"weblogic 10 control interface\" \/><\/p>\n<p>Lock and edit the interface, a new data source, set new data source JNDI name for the oracle (ie, the production of the template definition JNDI name), select the database type and drive click &#8220;Next&#8221;, as shown below:<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/new-jdbc.jpg\" alt=\"New data source jdbc \" \/><\/p>\n<p>Transaction options according to their requirements definition, in this default, click &#8220;Next&#8221;<br \/>\nConfigure the connection properties: database name, URL, user name and password, weblogic 10 to establish a physical connection oracle 10g<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/next-jdbc.jpg\" alt=\"Configure the jdbc datasource properties\" \/><\/p>\n<p>Testing just defined data source connection: Before weblogic server configuration will show us good data source, and provides the connection test, click on the &#8220;Test Configuration&#8221; pop-up message &#8220;connection test was successful,&#8221; explained configured correctly, click &#8220;Next&#8221;<br \/>\nDeploy the new JDBC data source: Select the data source you need to deploy a server, click the &#8220;Finish&#8221;<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/over.jpg\" alt=\"Deploy jdbc datasource\" \/><\/p>\n<p>Server-side data source configured, the application after deployment can be configured to activate the connection with the oracle database through &#8220;oracle&#8221; This bridge (JNDI name)<\/li>\n<li>Modify the application WebReport \/ web.xml file under web-inf:<br \/>\nBetween \u2026\u2026 add the following sentence:<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/webxml.png\" alt=\"Modify the web.xml file\" \/><\/li>\n<li>Fully configured, you can access the JNDI data source for the report.<br \/>\n<img class=\"centered\" src=\"http:\/\/www.finereport.com\/en\/wp-content\/themes\/fanruan\/images\/success.jpg\" alt=\"access the JNDI data source\" \/><\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>NO.1 JNDI connection using the principles In the Report&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[111],"tags":[117],"_links":{"self":[{"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/posts\/1995"}],"collection":[{"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/comments?post=1995"}],"version-history":[{"count":2,"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/posts\/1995\/revisions"}],"predecessor-version":[{"id":10604,"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/posts\/1995\/revisions\/10604"}],"wp:attachment":[{"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/media?parent=1995"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/categories?post=1995"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/frg.fineres.com\/en\/wp-json\/wp\/v2\/tags?post=1995"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}