Oracle Data source configuration in MULE(AnyPoint Studio)

I use this config for oracle database in Mule:

    <spring:bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource" destroy-method="shutdown" name="Bean">
        <spring:property name="driverName" value="oracle.jdbc.driver.OracleDriver"/>
        <spring:property name="url" value="jdbc:oracle:thin:@"/>
        <spring:property name="user" value="username" />
        <spring:property name="password" value="123456" />

<db:oracle-config name="Oracle_Configuration" useXaTransactions="true" dataSource-ref="dataSource"   doc:name="Oracle Configuration">

    <db:pooling-profile maxPoolSize="10" minPoolSize="5" acquireIncrement="2"/>

*I added ojdbc14.jar as a external jar file into my project
but when I test connection in Global Elements in Anypoint Studio I see this error:

enter image description here

enter image description here

enter image description here

how can I solve this issue?

Also I have to say that in a main method I checked the connection and it was ok, this is Main method structure:

    import java.sql.*;

public class Main {

    public static void main(String[] args) throws Exception {

           try {
                 Class.forName ("oracle.jdbc.driver.OracleDriver");
           } catch (ClassNotFoundException e) {

            Connection conn = DriverManager.getConnection
                ("jdbc:oracle:thin:@", "eslami", "123456");
                                // @machineName:port:SID,   userid,  password

            Statement stmt = conn.createStatement();
            ResultSet rset = stmt.executeQuery("select * from person");
            while (
                System.out.println (rset.getString(1) +  "  " + rset.getString(2) + "  " +  
                                    rset.getString(3) +  "  " + rset.getString(4) + "  " + 
                                    rset.getString(5));   // Print row 1


Source: oracle

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.