We have a Business Service which we have imported from a Weblogic OSB 10.3 server into a Weblogic OSB 11gR1 server. The Business Service is an ejb protocol service which basically connects to an Oracle DB and writes messages to a given Table.
When we call the Business Service from a project flow, we are getting the following exception:
java.lang.NoClassDefFoundError: org/hibernate/JDBCException
thus, the messages in the flow are not being written to the database table...
I am guessing that this is due to a wrong hibernate jar version or something along those lines? Where do I need to look and what can I do to resolve this error?
The reason for why we were getting JDBCException was simply because the Oracle tablespace in which the table was sitting under was 100% full and, crucially, the tablespace was not set with autoextend on.
Related
I have deployed EAR in Weblogic 12c server targeting a cluster. Here cluster comprises of 2 managed servers on same physical machine.
Now, as per my requirement the application consumes messages from foreign destination e.g. MQ Series, so I have an MDB in my application that should make connection to remote queue via JNDI lookup.
So, in order to fulfill this, I have perfomed following steps:
1) Created a JMS server which targets to cluster.
2) Created a JMS Module which targets to cluster.
3) Inside JMS module created a Foreign server and checked on option - "Default Targeting Enabled". So, it is also targetting to cluster same as its parent.
4) Inside Foreign server, I have created destination and connection factories.
After making above changes, when I tried to deploy my EAR, I am getting following error messages. My MDB is not making connection to destination message queue.
The Message-Driven EJB TestMDB is unable to connect to the JMS destination jms/TEST_FEED_QUEUE. The Error was:
The destination for the MessageDrivenBean TESTMDB could not be resolved at this time. Please ensure the destination is available at the JNDI name jms/TEST_FEED_QUEUE. The EJB container will periodically attempt to resolve this MessageDrivenBean destination and additional warnings may be issued.
Similar errors were displayed on other managed server as well.
Please suggest, where I am doing wrong. Please suggest.
We have developed a Java application with the below specifications.
Frameworks: spring,hibernate
Database: oracle
Server: weblogic 11g
Problem here is when we use Weblogic Data Source the connections are not releasing to the pool which is causing Database server RAM consumption completely after some transactions. But when we use basic Data source in the application the connections are releasing immediately after each transaction and there was no RAM consumption at Database server end. How can I use container based data source?
This will depend on the parameters which you have selected while configuring data source for weblogic. Please check the following
1) Do not enable "Pinned to Thread" properties
2) Enable "Inactive connection time out" to appropriate value. It may be possible that you application has leaked connection
I have database username and password to access oracle db and also have service url like https://X-X.X.X.oraclecloudapps.com/apex/.
Can anybody know how to connect this db using JDBC connection.
I tried using oracle thin driver but somehow it failes.
Sample java code:
Connection conn = DriverManager.getConnection("jdbc:oracle:thin:#//X.X.X.X.oraclecloudapps.com:1521/sid", "username", "****");
It throws
Exception in thread "main" java.sql.SQLRecoverableException: Io exception: The Network Adapter could not establish the connection
I don't know SID here, it would be helpful if anybody give steps to find SID/ServiceName from Oracle Cloud dashboard.
You can't use JDBC to connect to the Database Schema Service. You can connect using the API or tools that utilize the REST API. For data upload to Oracle Database Schema Service, use Oracle SQL Developer, the Oracle Application Express SQL Workshop Data Upload Utility or the Oracle Application Express Data Load utility. Read more here: http://docs.oracle.com/cloud/latest/dbcs_schema/CSDBU/GUID-3B14CF7A-637B-4019-AAA7-A6DC5FF3D2AE.htm#CSDBU177
There is only three way to connect Database Schema Service.
From an Oracle Application Express application running in Database Schema Service
From a Java application running in an Oracle Java Cloud Service
Through RESTful Web services
Try the following JDBC URL to resolve the issue
"jdbc:oracle:thin:#host-address:1521/sid";
Note / is used after port and Not :
My application uses XA transaction for writing to db and publishing message out on MQ.
However Consumer application intermittently not able to find data in the database.
We are using
Weblogic 10.3 and oracle 10g
I thought as part of XA transaction, message will be sent out only when db commit is complete.
Any inputs on this will be appreciated..
Thanks.
The question is what data source are you using to execute xa transactions. If it is the emulated one this is expected, as you are only simulating xa.
I have a problem concerning with proxool and oracle driver in Tomcat.
The web application I use contains a webservice jar file using metro and a servlet to initialize / start the proxool pool. The proxool pool is configured with an oracle connection. When the service is called, it fetches a connection from the pool, executes a statement and returns. I close the resultset, the statement and the connection in the service method afterwards.
When I now try to hot undeploy the web application, the servlet stops proxool pool by ProxoolFacade.shutdown(); in it's destroy method.
The problem is, that the hot undeploy can not finish because the Oracle driver ojdbc5.jar can not be deleted from the folder of the extracted web application.
Trying the same with a SQL server database and the jtds driver it works without this problem.
Used versions:
Apache Tomcat 6.0.18
Oracle 11g JDBC driver 11.1.0.6.0
Proxool 0.9.1
Anyone has an idea?
Regards Timo
You must add the Oracle driver to the Tomcat instance and configure Tomcat JNDI with an Oracle datasoure.
This way, the driver will stay alive when the app is terminated and Tomcat will control the pooling of the DB connections. The reason for your problem is that some DB drivers "hook" into the VM. This means that Tomcat can't unload the classes during redeploy -- there are still references around.
I'd even suggest to try to move proxool into the Tomcat server and have Tomcat manage the pools for you. That would make hot deploy much faster and more reliable, even if you leak connections.