Cannot get JDBC Connection in Elastic Beanstalk

Questions:

i want to deploy my application in AWS.
i have setup my env.
and in root-context.xml of my application i have setup data source.


    
    
    
    

this setting works fine locally in tomcat server.
but in AWS, it throws this error message

nested exception is org.apache.ibatis.exceptions.PersistenceException: 
Error querying database. Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is
java.sql.SQLException: Cannot load JDBC driver class 'oracle.jdbc.driver.OracleDriver'
The error may exist in file [/var/lib/tomcat8/webapps/ROOT/WEB-INF/classes/mappers/emp/emp-mapper.xml]
The error may involve EmpDAO.List ### The error occurred while executing a query
Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is
java.sql.SQLException: Cannot load JDBC driver class 'oracle.jdbc.driver.OracleDriver'

Now my question is: what should i do to use get jdbc connection in AWS?

Answers:



Questions:

i want to deploy my application in AWS.
i have setup my env.
and in root-context.xml of my application i have setup data source.


    
    
    
    

this setting works fine locally in tomcat server.
but in AWS, it throws this error message

nested exception is org.apache.ibatis.exceptions.PersistenceException: 
Error querying database. Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is
java.sql.SQLException: Cannot load JDBC driver class 'oracle.jdbc.driver.OracleDriver'
The error may exist in file [/var/lib/tomcat8/webapps/ROOT/WEB-INF/classes/mappers/emp/emp-mapper.xml]
The error may involve EmpDAO.List ### The error occurred while executing a query
Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is
java.sql.SQLException: Cannot load JDBC driver class 'oracle.jdbc.driver.OracleDriver'

Now my question is: what should i do to use get jdbc connection in AWS?

Answers:



Need Help? Chat with us