Got Error Like::com.evermind.server.ejb.TimeoutExpiredException.
Hi,
I have one big application in which we are using oracle9iAS and EJB. While I am searching some data which returns more than 15000 rows then I got Followed Error.
I use,
Front End ::Swing
Middle Ware ::EJB
Application Server ::OC4J 9i
com.evermind.server.ejb.TimeoutExpiredException: timeout expired waiting for an instance
at com.evermind.server.ejb.EntityEJBHome.getContextInstance(EntityEJBHome.java:309)
at com.evermind.server.ejb.DBEntityEJBHome.createWrapperInstance(DBEntityEJBHome.java:114)
at com.evermind.server.ejb.DBEntityEJBHome.getWrapperInstanceNoCache(DBEntityEJBHome.java:108)
at com.evermind.server.ejb.DBEntityEJBHome.getWrapperInstance(DBEntityEJBHome.java:149)
at FingdAttrBMHome_EntityHomeWrapper193.findBy_CompleteSQLFinder(FingdAttrBMHome_EntityHomeWrapper193.java:1086)
at com.fritolay.mware.mf.prd.session.FGItems.FGItemAppSearchBean.approvalSearchMethod(FGItemAppSearchBean.java:1422)
at com.fritolay.mware.mf.prd.session.FGItems.FGItemSFBean.approvalSearch(FGItemSFBean.java:9713)
at FGItemSFRemote_StatefulSessionBeanWrapper30.approvalSearch(FGItemSFRemote_StatefulSessionBeanWrapper30.java:1186)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:119)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48)
at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:802)
at java.lang.Thread.run(Thread.java:484)
Error: null:null:ApprovalSearch()->Exception occured in ApprovalBDCSearch found
Code which produce this error is as follows::
public Collection ejbFindBy_CompleteSQLFinder(String strSql)
throws RemoteException, FinderException, ServerSideException {
methodName = "ejbFindBy_generalCompleteFinder(String strSql)";
log(SIMPLE_MESSAGE, "\n\rSTARTED");
Connection con = null;
Statement stmt = null;
try {
String selectSQL = strSql;
log(SIMPLE_MESSAGE, "selectSql :\n\r" + selectSQL);
con = new SqlUtility().getConnection(DATA_SOURCE_NAME);
stmt = con.createStatement();
ResultSet rs = stmt.executeQuery(selectSQL);
Vector v = new Vector();
while (rs.next()) {
FingdAttrPK pk = new FingdAttrPK(getValue(rs,this.ITEM_SYS_NBR,"ITEM_SYS_NBR") , getValue(rs,this.CTRY_CODE,"CTRY_CODE") , getValue(rs,this.CO_CODE,"CO_CODE") , getValue(rs,this.FGITEM_ATTR_EFF_DT,"FGITEM_ATTR_EFF_DT"));
log(SIMPLE_MESSAGE, "" + pk );
v.addElement(pk);
} // End of While
log(SUCCESSFULLY_DONE,"successfully done ....");
return v;
catch (SQLException sqle) {
log(ERROR_OCCURED, "SQL Exception while getting PK " + sqle.getMessage());
sqle.printStackTrace();
int iErrorCode = sqle.getErrorCode();
String sErrorDesciption [] = new String[] {"SQL Exception while getting collection of PK " + sqle.getMessage()};
ServerSideException sse = new ServerSideException(beanName + methodName,iErrorCode,sErrorDesciption);
throw sse;
finally {
log(SIMPLE_MESSAGE, "releaseResource(Statement) : " + new SqlUtility().releaseResource(stmt));
log(SIMPLE_MESSAGE, "releaseResource(Connection) : " + new SqlUtility().releaseResource(con));
So, how i can solve this issue?? is there any setting in .xml files??
Regards,
Jignesh Patel
Thanks to all, The problem solved
Regards
Madhu V
Similar Messages
-
ClassCastException: com.evermind.server.ejb.EJBInputStream
Hello,
I am trying to use latest ocj4 (extened) to deploy the ejb.
I am getting following error
java.lang.ClassCastException:
com.evermind.server.ejb.EJBInputStream
Here is the part of code which calls a ejb method
Context ic = new InitialContext();
genObjectHome home = (genObjectHome)ic.lookup("genObjectEJB");
genObjectRemote ejb = (genObjectRemote)
PortableRemoteObject.narrow(home.create(),
genObjectRemote.class);
dataList = (genQueryDataObject) ejb.getGen();//*** Error occures
here
ejb.remove();
Application works ok on Weblogic.
Please provide any help or pointers to correct the problem.
Thanks a lot in advance.
Dhananjay ( [email protected])Hi Dhananjay,
I assume the code you have supplied is client code, correct? If
so, then what type of client is it -- web client or application
client? In any case, you will need to set some properties to be
used by the "InitialContext" object you are creating. Depending
on the type of client you are using, you would either set these
properties in the client code, or in one of the configuration
files. Configuration files are the things that are most different
between application servers, so the reason why your code works in
WebLogic and not OC4J is most probably due to the fact that you
need to modify your configuration settings. Have you looked at
the sample code on the Technet site? Have you looked through
Oracle's documentation for OC4J? Are you using JDeveloper?
I'm afraid that's all I can offer based on the information you
have supplied. Hope it helps.
Happy New Year,
Avi. -
Error running com.evermind.server.jms.JMSUtils
I'm running the following from the Developer prompt command window of a 10.1.2 midtier install.
java -classpath C:\OraHome_AppServ\j2ee\home\oc4j.jar com.evermind.server.jms.JMSUtils destinations
This gives the following error:
Oracle Application Server Containers for J2EE 10g (10.1.2.0.0) (build "041223.1874"), OC4J JMS 1.0.2b
javax.jms.JMSException: Unable to create a connection to "/0.0.0.0:9,127" as user "null".
at com.evermind.server.jms.JMSUtils.makeJMSException(JMSUtils.java:1843)
at com.evermind.server.jms.JMSUtils.toJMSException(JMSUtils.java:1859)
at com.evermind.server.jms.EvermindConnection.<init>(EvermindConnection.java:114)
at com.evermind.server.jms.EvermindConnectionFactory.createConnection(EvermindConnectionFactory.java:118)
at com.evermind.server.jms.EvermindConnectionFactory.createConnection(EvermindConnectionFactory.java:110)
at com.evermind.server.jms.JMSUtils.dest(JMSUtils.java:679)
at com.evermind.server.jms.JMSUtils.main(JMSUtils.java:265)
I'm running this to see if my Queue to Topic sample is working correctly. I suspect this is a configuration error but I'm not sure how to fix it.
Thanks,
CraigThese objects are created on the server when the oc4j.jms.debug property is true. They are used to track DMS phases that have been started but not yet completed. DMS phases are started (and these objects created) when operations on various OC4J JMS server-side objects (representing JMS connections, sessions, producers, consumers, browsers) are started, and are (supposed to be) ended (and these objects released) when those operations complete. Specifically, allocation is done via JMSObject.lock and release is via JMSObject.unlock. It's possible that you are hitting some case where one of these operations is calling lock() and then failing to call unlock(). Note that, despite the name, in most cases the lock() method doesn't check that the given JMS object isn't already locked, so multiple calls to lock() without an unlock() will typically not generate any kind of error or warning (but will produce a memory leak).
At least for debugging purposes, a modified JMSObject.class file could be used which had a member variable isLocked, set isLocked in lock(), cleared it in unlock(), and verified it is clear before setting it (throwing/logging otherwise). If you are unable (or are legally prevented) from doing such a temporary modification yourself, you should suggest that support provide you with such a modified class file as it will likely be the fastest way to find the root cause. (Note that it would not necessarily flag an error on the faulty operation, but rather on the next attempted operation on the given object or one of its "children", so you would need to backtrack to figure out what the last operation was. "children" is defined as "session is child of connection" and "consumer/producer/browser" are child of session" -- locking/unlocking a child also locks/unlocks the parent.)
As a workaround, you might try just not using oc4j.jms.debug.
-Jeff -
Dear Friends
Here is the problem.
please let me know the cause for the following error. This problem is coming while accessing the ejb component.
please give replay to the following id.
[email protected]
com.evermind.server.rmi.OrionRemoteException: Error in setSessionContext(): null
at com.evermind.server.ejb.StatelessSessionEJBHome.getContextInstance(StatelessSessionEJBHome.java:219)
at ResourceMgr_StatelessSessionBeanWrapper22.getSearchTechnicians(ResourceMgr_StatelessSessionBeanWrapper22.java:
at com.dsr.sov02.resourcemgr.ResourceMgrBD.getSearchTechnicians(ResourceMgrBD.java:3849)
at com.dsr.sov02.rovingeye.techmgmt.sf.TechMgmtSFEJB.getSearchTechnicians(TechMgmtSFEJB.java:732)
at TechMgmtSF_StatelessSessionBeanWrapper32.getSearchTechnicians(TechMgmtSF_StatelessSessionBeanWrapper32.java:17
at com.dsr.sov02.rovingeye.TechMgmtBD.getSearchTechnicians(TechMgmtBD.java:825)
at com.dsr.sov02.rovingeye.TechMgmtBP.getSearchTechnicians(TechMgmtBP.java:339)
at com.dsr.sov02.rovingeye.techmgmt.techsearch.TechSearchUCI.getSearchTechnicians(TechSearchUCI.java:124)
at com.dsr.sov02.rovingeye.techmgmt.techsearch.TechSearchRH.processRequest(TechSearchRH.java:198)
at com.dsr.sov02.rovingeye.RovingEyeRP.processRequest(RovingEyeRP.java:76)
at com.dsr.sov02.rovingeye.RovingEyeFC.doGet(rovingeyefc.java:41)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:195)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:309)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:696)
at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:281)
at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:766)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:259)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:107)
at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:802)
at java.lang.Thread.run(Unknown Source)
Nested exception is:
java.lang.NoSuchMethodError
at com.dsr.sov02.resourcemgr.sf.ResourceMgrEJB.setSessionContext(ResourceMgrEJB.java:87)
at com.evermind.server.ejb.StatelessSessionEJBHome.getContextInstance(StatelessSessionEJBHome.java:213)
at ResourceMgr_StatelessSessionBeanWrapper22.getSearchTechnicians(ResourceMgr_StatelessSessionBeanWrapper22.java:
at com.dsr.sov02.resourcemgr.ResourceMgrBD.getSearchTechnicians(ResourceMgrBD.java:3849)
at com.dsr.sov02.rovingeye.techmgmt.sf.TechMgmtSFEJB.getSearchTechnicians(TechMgmtSFEJB.java:732)
at TechMgmtSF_StatelessSessionBeanWrapper32.getSearchTechnicians(TechMgmtSF_StatelessSessionBeanWrapper32.java:17
at com.dsr.sov02.rovingeye.TechMgmtBD.getSearchTechnicians(TechMgmtBD.java:825)
at com.dsr.sov02.rovingeye.TechMgmtBP.getSearchTechnicians(TechMgmtBP.java:339)
at com.dsr.sov02.rovingeye.techmgmt.techsearch.TechSearchUCI.getSearchTechnicians(TechSearchUCI.java:124)
at com.dsr.sov02.rovingeye.techmgmt.techsearch.TechSearchRH.processRequest(TechSearchRH.java:198)
at com.dsr.sov02.rovingeye.RovingEyeRP.processRequest(RovingEyeRP.java:76)
at com.dsr.sov02.rovingeye.RovingEyeFC.doGet(rovingeyefc.java:41)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:195)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:309)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:696)
at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:281)
at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:766)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:259)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:107)
at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:802)
at java.lang.Thread.run(Unknown Source)
Thanks in advance.
Kumar T.Kumar,
From the stack trace you have posted, it appears that in line 87 of file "ResourceMgrEJB.java" (in package "com.dsr.sov02.resourcemgr.sf"), you are invoking a non-existent method. Have you looked at that line of the code?
Good Luck,
Avi. -
Hi
I get an this stack on the server side while doing a forward using RequestDispatcher.
com.evermind.server.http.HttpIOException: Connection aborted by peer: socket write error
at com.evermind.server.http.EvermindServletOutputStream.flushBuffer(EvermindServletOutputStream.java:81)
at com.evermind.server.http.EvermindHttpServletResponse.flushBuffer(EvermindHttpServletResponse.java:1818)
at javax.servlet.ServletResponseWrapper.flushBuffer(ServletResponseWrapper.java:52)
The funniest part is, i get this exception while i submit the request second time i get this error.. First time it works fine. :)
ANy solution on this would be greatly appreciated.
Thanks
ManjuHi!
I posted a TAR on metalink for this "read timed out" problem. This is the answer I got:
apparently the messages that you listed seem refer to a problem in reading request data from the client - so the HttpIOException is triggered.
I have made a little research on HttpIOException in request-reading context. There are only
two situations in which HttpIOException can be raised without an causing IOExce
ption, and I think none of them applies. So we'd have some kind of IOException t
hat causes the HttpIOException. It might well be a SocketException, because the
text "Read timed out" is as far as I know the standard text for SocketException
if the socket's SoTimeout has been reached.
In fact there is a configuration parameter for OC4J (though undocumented), which allows you to set the Socket's SoT
imeout -- and the default is 15000 (measured in milliseconds). The name is "orac
le.j2ee.http.socket.timeout", and it should be available in OC4J 9.0.3.1 and hig
her (I am definitely sure that it exists in OC4J 9.0.4.1).
So can you please add something like "-Doracle.j2ee.http.socket.timeout=120000" to the startup comma
nd for your standalone OC4J container to increase the timeout from 15 seconds to
2 minutes?
It helped us, although some requests time out "normally" instead.
/jonas -
Com.evermind.server.rmi.OrionRemoteException
Hi I have a simple AXIS2 webservice and BPEL process deployed on the same box but on two seperate OC4J's.
I then have a remote junit test which I invoke from a remote client and it works fine.
I then take this test case into JunitPerf and create a simple load test.
Bearing in mind the services are simple and only return a boolean.
The load test works fine for five users, but when I try any more than 5, say 10 for instance I get this exception,
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.invokeMethod(RMIConnection.java:1553)
at com.evermind.server.rmi.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:55)
at com.evermind.server.rmi.RecoverableRemoteInvocationHandler.invoke(RecoverableRemoteInvocationHandler.java:22)
at com.evermind.server.ejb.StatelessSessionRemoteInvocationHandler.invoke(StatelessSessionRemoteInvocationHandler.java:50)
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
com.evermind.server.rmi.OrionRemoteException: Disconnected: Unknown command: 100
at __Proxy1.request(Unknown Source)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1602)
at com.oracle.bpel.client.delivery.DeliveryService.request(DeliveryService.java:104)
at com.evermind.server.rmi.RMIConnection.invokeMethod(RMIConnection.java:1553)
at com.evermind.server.rmi.RMIConnection.invokeMethod(RMIConnection.java:1553)
at com.evermind.server.rmi.RMIConnection.invokeMethod(RMIConnection.java:1553)
at com.evermind.server.rmi.RMIConnection.invokeMethod(RMIConnection.java:1553)
Mt test case effetcively looks like this,
package test.bpel;
import java.util.Hashtable;
import java.util.Map;
import javax.naming.Context;
import junit.framework.TestCase;
import org.w3c.dom.Element;
import com.collaxa.xml.XMLHelper;
import com.oracle.bpel.client.Locator;
import com.oracle.bpel.client.NormalizedMessage;
import com.oracle.bpel.client.delivery.IDeliveryService;
public class TestFileCreateFromTemplate extends TestCase {
private StringBuffer xml = new StringBuffer();
public TestFileCreateFromTemplate(String name){
super(name);
public void testProcessFileCreateFromTemplate(){
xml.append("<ns1:FileCreateFromTemplateReq xmlns:ns1=\"http://www.thalesgroup.com/arrcc2is/GENB/FileCreateFromTemplate\">");
xml.append("<ns1:templateNameLocation>Test</ns1:templateNameLocation>");
xml.append("<ns1:newFileName>Test</ns1:newFileName>");
xml.append("<ns1:newFileLocation>Test</ns1:newFileLocation>");
xml.append("<ns1:destinationFolder>Test</ns1:destinationFolder>");
xml.append("<ns1:securityClassification>Test</ns1:securityClassification>");
xml.append("<ns1:dateOfCreation>12/2/2007</ns1:dateOfCreation>");
xml.append("<ns1:viewFileOnCreation>true</ns1:viewFileOnCreation>");
xml.append("<ns1:arrayOfMetadata xmlns:ns2=\"http://uk.thalesgroup.com/arrcc2is/geni/geni_common/geni_types\">");
xml.append("<ns2:metadataField>");
xml.append("<ns2:name>Test</ns2:name>");
xml.append("<ns2:valueAsString>Test</ns2:valueAsString>");
xml.append("<ns2:valueAsInteger>1</ns2:valueAsInteger>");
xml.append("<ns2:valueAsLong>1</ns2:valueAsLong>");
xml.append("<ns2:valueAsDouble>1</ns2:valueAsDouble>");
xml.append("<ns2:valueAsBoolean>true</ns2:valueAsBoolean>");
xml.append("</ns2:metadataField>");
xml.append("</ns1:arrayOfMetadata>");
xml.append("</ns1:FileCreateFromTemplateReq>");
try {
String jndiFactory = "com.evermind.server.rmi.RMIInitialContextFactory";
String jndiUsername = "oc4jadmin";
String jndiPassword = "babylon5";
String jndiProviderUrl = "opmn:ormi://wells175732.int.rdel.co.uk:6004:OC4J_SOA/orabpel";
Hashtable jndi = new Hashtable();
jndi.put(Context.PROVIDER_URL, jndiProviderUrl);
jndi.put(Context.INITIAL_CONTEXT_FACTORY, jndiFactory);
jndi.put(Context.SECURITY_PRINCIPAL, jndiUsername);
jndi.put(Context.SECURITY_CREDENTIALS, jndiPassword);
Locator locator = new Locator("default","bpel",jndi);
IDeliveryService deliveryService =
(IDeliveryService)locator.lookupService(IDeliveryService.SERVICE_NAME );
NormalizedMessage nm = new NormalizedMessage( );
nm.addPart("payload", xml.toString() );
System.out.println("Making Request: ");
NormalizedMessage res = deliveryService.request("FileCreateFromTemplate", "process", nm);
Map payload = res.getPayload();
System.out.println("Got Request: ");
Element element = (Element)payload.get("payload");
System.out.println("RESPONSE XML: ");
System.out.println( XMLHelper.toXML(element) );
} catch(Exception e) {
e.printStackTrace();
fail("TEST FAILED BECAUSE : " + e.getMessage());
The load test class is a follows, very basic,
package test.bpel;
import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;
import com.clarkware.junitperf.LoadTest;
import com.clarkware.junitperf.TestFactory;
public class ARRCLoadTest extends TestCase{
private static final int users = 10;
private static final int iterations = 1;
public ARRCLoadTest(){}
public static Test suite(){
TestSuite suite = new TestSuite();
suite.addTest(testUnderLoad());
return suite;
public static Test testUnderLoad(){
Test factory = new TestFactory(TestFileCreateFromTemplate.class);
Test loadTest = new LoadTest(factory, users, iterations);
return loadTest;
Any ideas why this would be happening. I was thinking is there a maximum of concurrent users somewhere to be set in the enterprise manager.
I also checked my BPEL Console instances for this specific bpel process and they have been created for all 10 processes.Kumar,
From the stack trace you have posted, it appears that in line 87 of file "ResourceMgrEJB.java" (in package "com.dsr.sov02.resourcemgr.sf"), you are invoking a non-existent method. Have you looked at that line of the code?
Good Luck,
Avi. -
I have a UserManager subclass which has to call session beans running in the application server.
I successfully got my BeanRemoteHome object, but when I call "home.create()", I get the following exception:
java.lang.NullPointerException
com.evermind.security.User com.evermind.server.ThreadState.getUser()
ThreadState.java:135
com.attws.it.bsa.felix.ejb.session.UserEventManagerRemote UserEventManagerRemoteHome_StatelessSessionHomeWrapper6.create()
UserEventManagerRemoteHome_StatelessSessionHomeWrapper6.java:61
boolean com.attws.it.bsa.felix.common.utils.LoggingUserManager.checkPassword(java.lang.String, java.lang.String)
LoggingUserManager.java:85
boolean com.orionsupport.security.SimpleUserManager$UserWrapper.authenticate(java.lang.String)
SimpleUserManager.java:63
boolean com.evermind.server.http.HttpRequestHandler.processRequest(com.evermind.server.ApplicationServerThread, com.evermind.server.http.EvermindHttpServletRequest, com.evermind.server.http.EvermindHttpServletResponse, java.io.InputStream, java.io.OutputStream, boolean)
HttpRequestHandler.java:559
void com.evermind.server.http.HttpRequestHandler.run(java.lang.Thread)
HttpRequestHandler.java:243
void com.evermind.util.ThreadPoolThread.run()
ThreadPoolThread.java:64
My code doesn't abort anything when this fails, it just goes on. Except for not being able to get this Remote interface in the UserManager class, my application starts up fine, and I'm able to perform operations.As an update, I just spent the last two hours writing a MDB to take the place of the session bean, in case that was the problem. I got past the obstacles that OC4J docs presented to me (specifying "jms-destination-type" instead of "destination-type", and neglecting to mention that you need to change the DOCTYPE to specify EJB 2.0 instead of 1.1) and successfully deployed an MDB, then I put some code into my UserManager to send a queue message instead of calling a session bean. When it finally got to the point of sending the message, I got the exception in the exact same place (this is from standalone OC4J, which is why the line number is 139 instead of 135):
java.lang.NullPointerException
at com.evermind.server.ThreadState.getUser(ThreadState.java:139)
at com.evermind.server.ejb.MessageDrivenHome.onMessage(MessageDrivenHome.java:701)
at com.evermind.server.ejb.MessageDrivenHome.process(MessageDrivenHome.java:892)
at com.evermind.server.jms.ServerQueue.add(ServerQueue.java:88)
at com.evermind.server.jms.JMSServer.addMessage(JMSServer.java:313)
at com.evermind.server.jms.LocalQueueConnection.send(LocalQueueConnection.java:46)
at com.evermind.server.jms.EvermindQueueSession.send(EvermindQueueSession.java:117)
at com.evermind.server.jms.EvermindQueueSender.send(EvermindQueueSender.java:75)
at com.evermind.server.jms.EvermindQueueSender.send(EvermindQueueSender.java:36)
at com.evermind.server.jms.EvermindQueueSender.send(EvermindQueueSender.java:31)
at com.attws.it.bsa.felix.common.utils.LoggingUserManager.checkPassword(LoggingUserManager.java:134)
at com.orionsupport.security.SimpleUserManager$UserWrapper.authenticate(SimpleUserManager.java:63)
at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:559)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:243)
at com.evermind.util.ThreadPoolThread.run(ThreadPoolThread.java:64) -
ClassCastException: com.evermind.server.rmi.OrionRemoteException
We have resently tried to move our application from OC4J 9.0.3 to the OC4J 9.0.4 preview.
However when autogenerating data we get the following exception:
com.evermind.server.rmi.OrionRemoteException: java.lang.ClassCastException: com.evermind.server.rmi.OrionRemoteException
at com.evermind.server.ejb.EJBUtils.getUserException(EJBUtils.java:275)
at InstallSession_StatelessSessionBeanWrapper2717.createItemBatchBaseData(InstallSession_StatelessSessionBeanWrapper2717.java:268)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:124)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)
at java.lang.Thread.run(Thread.java:479)
at connection to wmsserver/192.168.1.95 as admin
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1499)
at com.evermind.server.rmi.RMIConnection.invokeMethod(RMIConnection.java:1452)
at com.evermind.server.rmi.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:55)
at com.evermind.server.rmi.RecoverableRemoteInvocationHandler.invoke(RecoverableRemoteInvocationHandler.java:22)
at com.evermind.server.ejb.StatelessSessionRemoteInvocationHandler.invoke(StatelessSessionRemoteInvocationHandler.java:50)
at __Proxy1.createItemBatchBaseData(Unknown Source)
at Sampleinstall.InstallSessionClient2.main(InstallSessionClient2.java:28)
Nested exception is:
java.lang.ClassCastException: com.evermind.server.rmi.OrionRemoteException
at ItemBatchLocalHome_EntityHomeWrapper343.create(ItemBatchLocalHome_EntityHomeWrapper343.java:1063)
at install.impl.InstallSessionBean.createItemBatchBaseData(InstallSessionBean.java:120)
at InstallSession_StatelessSessionBeanWrapper2717.createItemBatchBaseData(InstallSession_StatelessSessionBeanWrapper2717.java:254)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:124)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)
at java.lang.Thread.run(Thread.java:479)
at connection to wmsserver/192.168.1.95
at com.evermind.server.rmi.OrionRemoteException.receive(OrionRemoteException.java:130)
at com.evermind.server.rmi.RMIConnection.handleMethodInvocationResponse(RMIConnection.java:1622)
at com.evermind.server.rmi.RMIConnection.run(RMIConnection.java:406)
at com.evermind.server.rmi.RMIConnection.run(RMIConnection.java:286)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:536)
Process exited with exit code 0.
The method which fails is the following method, which is located in an orinary stateless session bean:
public void createItemBatchBaseData() {
try{
ItemBatchLocalHome itemBatchHome = getItemBatchLocalHome();
ItemLocalHome itemHome = getItemLocalHome(); ItemLocal item = itemHome.findByPrimaryKey("5501");
System.out.println("Før create "+item);
ItemBatchLocal itemBatch = itemBatchHome.create(item,
"B05501-1",
new Long(System.currentTimeMillis()),
new Boolean(false),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Integer(0));
System.err.println("Efter create");
item = itemHome.findByPrimaryKey("5502");
/* FAILS HERE >> */ itemBatch = itemBatchHome.create(item,
("B05502-1"),
new Long(System.currentTimeMillis()),
new Boolean(false),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Integer(0));
catch (CreateException e) {
System.err.println("Et eller flere batchnumre er oprettet i forvejen \n");
e.printStackTrace();
catch (FinderException f){
System.err.println("Ved oprettelse af batchnummer manglede relateret vare \n");
f.printStackTrace();
catch (NamingException e) {
System.err.println("Naming");
e.printStackTrace();
itemBatch is a CMP entity bean, with nothing but the field getters and setters, so it should be quite basic.
It worked without problems in 9.0.3, so we are wondering what we might have missed when changing to 9.0.4.
mvh
NHBWe have resently tried to move our application from OC4J 9.0.3 to the OC4J 9.0.4 preview.
However when autogenerating data we get the following exception:
com.evermind.server.rmi.OrionRemoteException: java.lang.ClassCastException: com.evermind.server.rmi.OrionRemoteException
at com.evermind.server.ejb.EJBUtils.getUserException(EJBUtils.java:275)
at InstallSession_StatelessSessionBeanWrapper2717.createItemBatchBaseData(InstallSession_StatelessSessionBeanWrapper2717.java:268)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:124)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)
at java.lang.Thread.run(Thread.java:479)
at connection to wmsserver/192.168.1.95 as admin
at com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(RMIConnection.java:1499)
at com.evermind.server.rmi.RMIConnection.invokeMethod(RMIConnection.java:1452)
at com.evermind.server.rmi.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:55)
at com.evermind.server.rmi.RecoverableRemoteInvocationHandler.invoke(RecoverableRemoteInvocationHandler.java:22)
at com.evermind.server.ejb.StatelessSessionRemoteInvocationHandler.invoke(StatelessSessionRemoteInvocationHandler.java:50)
at __Proxy1.createItemBatchBaseData(Unknown Source)
at Sampleinstall.InstallSessionClient2.main(InstallSessionClient2.java:28)
Nested exception is:
java.lang.ClassCastException: com.evermind.server.rmi.OrionRemoteException
at ItemBatchLocalHome_EntityHomeWrapper343.create(ItemBatchLocalHome_EntityHomeWrapper343.java:1063)
at install.impl.InstallSessionBean.createItemBatchBaseData(InstallSessionBean.java:120)
at InstallSession_StatelessSessionBeanWrapper2717.createItemBatchBaseData(InstallSession_StatelessSessionBeanWrapper2717.java:254)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:124)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)
at java.lang.Thread.run(Thread.java:479)
at connection to wmsserver/192.168.1.95
at com.evermind.server.rmi.OrionRemoteException.receive(OrionRemoteException.java:130)
at com.evermind.server.rmi.RMIConnection.handleMethodInvocationResponse(RMIConnection.java:1622)
at com.evermind.server.rmi.RMIConnection.run(RMIConnection.java:406)
at com.evermind.server.rmi.RMIConnection.run(RMIConnection.java:286)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:536)
Process exited with exit code 0.
The method which fails is the following method, which is located in an orinary stateless session bean:
public void createItemBatchBaseData() {
try{
ItemBatchLocalHome itemBatchHome = getItemBatchLocalHome();
ItemLocalHome itemHome = getItemLocalHome(); ItemLocal item = itemHome.findByPrimaryKey("5501");
System.out.println("Før create "+item);
ItemBatchLocal itemBatch = itemBatchHome.create(item,
"B05501-1",
new Long(System.currentTimeMillis()),
new Boolean(false),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Integer(0));
System.err.println("Efter create");
item = itemHome.findByPrimaryKey("5502");
/* FAILS HERE >> */ itemBatch = itemBatchHome.create(item,
("B05502-1"),
new Long(System.currentTimeMillis()),
new Boolean(false),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Double(0),new Double(0),new Double(0),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Long(System.currentTimeMillis()),
new Integer(0));
catch (CreateException e) {
System.err.println("Et eller flere batchnumre er oprettet i forvejen \n");
e.printStackTrace();
catch (FinderException f){
System.err.println("Ved oprettelse af batchnummer manglede relateret vare \n");
f.printStackTrace();
catch (NamingException e) {
System.err.println("Naming");
e.printStackTrace();
itemBatch is a CMP entity bean, with nothing but the field getters and setters, so it should be quite basic.
It worked without problems in 9.0.3, so we are wondering what we might have missed when changing to 9.0.4.
mvh
NHB -
Deployment error in com.evermind.....
Yet another bomb in my face ;)
during deployment i get this (i'm trying to add some ebeans to the project, we've been using DAO's uptill now)
Auto-unpacking D:\oc4j9030\j2ee\home\applications\NMS_EJBs.ear... done.
Auto-deploying NMS_EJBs (New server version detected)...
Copying default deployment descriptor from archive at D:\oc4j9030\j2ee\home\applications\NMS_EJBs/NMS_EJBs.jar/META-INF/orion-ejb-jar.xml to deployment directory D:\oc4j9030\j2ee\home\application-deployments\NMS_EJBs\NMS_EJBs.jar...
java.lang.NullPointerException
at com.evermind.server.ejb.compilation.CMPObjectCompilation.processContainerManagedField(CMPObjectCompilation.java:314)
at com.evermind.server.ejb.compilation.CMPObjectCompilation.processFields(CMPObjectCompilation.java:235)
at com.evermind.server.ejb.compilation.PersistenceManagerCompilation.compile(PersistenceManagerCompilation.java:59)
at com.evermind.server.ejb.compilation.EntityBeanCompilation.compile(EntityBeanCompilation.java:332)
at com.evermind.server.ejb.compilation.Compilation.compile(Compilation.java:288)
at com.evermind.server.administration.ServerApplicationInstallation.finish(ServerApplicationInstallation.java:526)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:119)
at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48)
at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:803)
at java.lang.Thread.run(Thread.java:536)
Ideas ? what am i doing wrong ?With pleasue ... :o)
<?xml version = '1.0' encoding = 'windows-1252'?>
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
<ejb-jar>
<enterprise-beans>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>CustomerEJB</display-name>
<ejb-name>CustomerEJB</ejb-name>
<local-home>dk.son.nms.ejb.session.CustomerEJBHome</local-home>
<local>dk.son.nms.ejb.session.CustomerEJB</local>
<ejb-class>dk.son.nms.ejb.session.impl.CustomerEJBBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>LookupFacade</display-name>
<ejb-name>LookupFacade</ejb-name>
<home>dk.son.nms.ejb.session.LookupFacadeHome</home>
<remote>dk.son.nms.ejb.session.LookupFacade</remote>
<ejb-class>dk.son.nms.ejb.session.impl.LookupFacadeBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
<ejb-local-ref>
<ejb-ref-name>LookupEJB</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<local-home>dk.son.nms.ejb.session.LookupEJBHome</local-home>
<local>dk.son.nms.ejb.session.LookupEJB</local>
<ejb-link>LookupEJB</ejb-link>
</ejb-local-ref>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>CustomerFacade</display-name>
<ejb-name>CustomerFacade</ejb-name>
<home>dk.son.nms.ejb.session.CustomerFacadeHome</home>
<remote>dk.son.nms.ejb.session.CustomerFacade</remote>
<ejb-class>dk.son.nms.ejb.session.impl.CustomerFacadeBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
<ejb-local-ref>
<ejb-ref-name>CustomerEJB</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<local-home>dk.son.nms.ejb.session.CustomerEJBHome</local-home>
<local>dk.son.nms.ejb.session.CustomerEJB</local>
<ejb-link>CustomerEJB</ejb-link>
</ejb-local-ref>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>DebtorFacade</display-name>
<ejb-name>DebtorFacade</ejb-name>
<home>dk.son.nms.ejb.session.DebtorFacadeHome</home>
<remote>dk.son.nms.ejb.session.DebtorFacade</remote>
<ejb-class>dk.son.nms.ejb.session.impl.DebtorFacadeBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
<ejb-local-ref>
<ejb-ref-name>DebtorEJB</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<local-home>dk.son.nms.ejb.session.DebtorEJBHome</local-home>
<local>dk.son.nms.ejb.session.DebtorEJB</local>
<ejb-link>DebtorEJB</ejb-link>
</ejb-local-ref>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>LookupEJB</display-name>
<ejb-name>LookupEJB</ejb-name>
<local-home>dk.son.nms.ejb.session.LookupEJBHome</local-home>
<local>dk.son.nms.ejb.session.LookupEJB</local>
<ejb-class>dk.son.nms.ejb.session.impl.LookupEJBBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>SystemEJB</display-name>
<ejb-name>SystemEJB</ejb-name>
<home>dk.son.nms.ejb.session.SystemEJBHome</home>
<remote>dk.son.nms.ejb.session.SystemEJB</remote>
<ejb-class>dk.son.nms.ejb.session.impl.SystemEJBBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateful )</description>
<display-name>ValueLister</display-name>
<ejb-name>ValueLister</ejb-name>
<home>dk.son.nms.ejb.patterns.ValueListerHome</home>
<remote>dk.son.nms.ejb.patterns.ValueLister</remote>
<local-home>dk.son.nms.ejb.patterns.ValueListerLocalHome</local-home>
<local>dk.son.nms.ejb.patterns.ValueListerLocal</local>
<ejb-class>dk.son.nms.ejb.patterns.impl.ValueListerBean</ejb-class>
<session-type>Stateful</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>UserManager</display-name>
<ejb-name>UserManager</ejb-name>
<home>dk.son.nms.ejb.session.UserManagerHome</home>
<remote>dk.son.nms.ejb.session.UserManager</remote>
<ejb-class>dk.son.nms.ejb.session.impl.UserManagerBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>ReminderEJB</display-name>
<ejb-name>ReminderEJB</ejb-name>
<home>dk.son.nms.ejb.session.ReminderHome</home>
<remote>dk.son.nms.ejb.session.ReminderEJB</remote>
<ejb-class>dk.son.nms.ejb.session.impl.ReminderBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>FormArchive</display-name>
<ejb-name>FormArchive</ejb-name>
<home>dk.son.nms.ejb.session.FormArchiveHome</home>
<remote>dk.son.nms.ejb.session.FormArchive</remote>
<ejb-class>dk.son.nms.ejb.session.impl.FormArchiveBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>DebtorEJB</display-name>
<ejb-name>DebtorEJB</ejb-name>
<local-home>dk.son.nms.ejb.session.DebtorEJBHome</local-home>
<local>dk.son.nms.ejb.session.DebtorEJB</local>
<ejb-class>dk.son.nms.ejb.session.impl.DebtorEJBBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<session>
<description>Session Bean ( Stateless )</description>
<display-name>AutomaticPosting</display-name>
<ejb-name>AutomaticPosting</ejb-name>
<home>dk.son.nms.ejb.session.AutomaticPostingHome</home>
<remote>dk.son.nms.ejb.session.AutomaticPosting</remote>
<ejb-class>dk.son.nms.ejb.session.impl.AutomaticPostingBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
<entity>
<description>entity Bean ( CMP )</description>
<display-name>Invoice_master</display-name>
<ejb-name>Invoice_master</ejb-name>
<local-home>dk.son.nms.ejb.entity.Invoice_masterLocalHome</local-home>
<local>dk.son.nms.ejb.entity.Invoice_masterLocal</local>
<ejb-class>dk.son.nms.ejb.entity.impl.Invoice_masterBean</ejb-class>
<persistence-type>Container</persistence-type>
<prim-key-class>java.lang.Long</prim-key-class>
<reentrant>False</reentrant>
<cmp-version>2.x</cmp-version>
<abstract-schema-name>Invoice_master</abstract-schema-name>
<cmp-field>
<field-name>faktnr</field-name>
</cmp-field>
<cmp-field>
<field-name>split_faktnr</field-name>
</cmp-field>
<cmp-field>
<field-name>fak_kred_kode</field-name>
</cmp-field>
<cmp-field>
<field-name>faktura_dato</field-name>
</cmp-field>
<cmp-field>
<field-name>forfalds_dato</field-name>
</cmp-field>
<cmp-field>
<field-name>bureaunr</field-name>
</cmp-field>
<cmp-field>
<field-name>kundenr</field-name>
</cmp-field>
<cmp-field>
<field-name>moms_pct</field-name>
</cmp-field>
<cmp-field>
<field-name>inf_pct</field-name>
</cmp-field>
<cmp-field>
<field-name>shs_pct</field-name>
</cmp-field>
<cmp-field>
<field-name>ant_detail_lin</field-name>
</cmp-field>
<primkey-field>faktnr</primkey-field>
</entity>
<entity>
<description>entity Bean ( CMP )</description>
<display-name>Invoice_ad_master</display-name>
<ejb-name>Invoice_ad_master</ejb-name>
<local-home>dk.son.nms.ejb.entity.Invoice_ad_masterLocalHome</local-home>
<local>dk.son.nms.ejb.entity.Invoice_ad_masterLocal</local>
<ejb-class>dk.son.nms.ejb.entity.impl.Invoice_ad_masterBean</ejb-class>
<persistence-type>Container</persistence-type>
<prim-key-class>dk.son.nms.ejb.entity.Invoice_ad_masterPK</prim-key-class>
<reentrant>False</reentrant>
<cmp-version>2.x</cmp-version>
<abstract-schema-name>Invoice_ad_master</abstract-schema-name>
<cmp-field>
<field-name>avisnr</field-name>
</cmp-field>
<cmp-field>
<field-name>ugenr</field-name>
</cmp-field>
<cmp-field>
<field-name>annnr</field-name>
</cmp-field>
<cmp-field>
<field-name>avis</field-name>
</cmp-field>
<cmp-field>
<field-name>snr</field-name>
</cmp-field>
<cmp-field>
<field-name>ann_text</field-name>
</cmp-field>
<cmp-field>
<field-name>dekort_flg</field-name>
</cmp-field>
<cmp-field>
<field-name>ant_detail_records</field-name>
</cmp-field>
<cmp-field>
<field-name>faktura_type</field-name>
</cmp-field>
<cmp-field>
<field-name>del_udg</field-name>
</cmp-field>
<cmp-field>
<field-name>ordrenr</field-name>
</cmp-field>
</entity>
<entity>
<description>entity Bean ( CMP )</description>
<display-name>Invoice_ad_detail</display-name>
<ejb-name>Invoice_ad_detail</ejb-name>
<local-home>dk.son.nms.ejb.entity.Invoice_ad_detailLocalHome</local-home>
<local>dk.son.nms.ejb.entity.Invoice_ad_detailLocal</local>
<ejb-class>dk.son.nms.ejb.entity.impl.Invoice_ad_detailBean</ejb-class>
<persistence-type>Container</persistence-type>
<prim-key-class>dk.son.nms.ejb.entity.Invoice_ad_detailPK</prim-key-class>
<reentrant>False</reentrant>
<cmp-version>2.x</cmp-version>
<abstract-schema-name>Invoice_ad_detail</abstract-schema-name>
<cmp-field>
<field-name>avisnr</field-name>
</cmp-field>
<cmp-field>
<field-name>annnr</field-name>
</cmp-field>
<cmp-field>
<field-name>lobnr</field-name>
</cmp-field>
<cmp-field>
<field-name>varenr</field-name>
</cmp-field>
<cmp-field>
<field-name>varegrpnr</field-name>
</cmp-field>
<cmp-field>
<field-name>lintypkode</field-name>
</cmp-field>
<cmp-field>
<field-name>rabatkode</field-name>
</cmp-field>
<cmp-field>
<field-name>text</field-name>
</cmp-field>
<cmp-field>
<field-name>spalter</field-name>
</cmp-field>
<cmp-field>
<field-name>hoejde</field-name>
</cmp-field>
<cmp-field>
<field-name>ant_enh</field-name>
</cmp-field>
<cmp-field>
<field-name>sats</field-name>
</cmp-field>
</entity>
</enterprise-beans>
<relationships>
<ejb-relation>
<ejb-relation-name>Invoice_ad_master - Invoice_master</ejb-relation-name>
<ejb-relationship-role>
<ejb-relationship-role-name>Invoice_master may have many Invoice_ad_master</ejb-relationship-role-name>
<multiplicity>One</multiplicity>
<relationship-role-source>
<ejb-name>Invoice_master</ejb-name>
</relationship-role-source>
<cmr-field>
<cmr-field-name>invoice_ad_master_faktnr</cmr-field-name>
<cmr-field-type>java.util.Collection</cmr-field-type>
</cmr-field>
</ejb-relationship-role>
<ejb-relationship-role>
<ejb-relationship-role-name>Invoice_ad_master has one Invoice_master</ejb-relationship-role-name>
<multiplicity>Many</multiplicity>
<relationship-role-source>
<ejb-name>Invoice_ad_master</ejb-name>
</relationship-role-source>
<cmr-field>
<cmr-field-name>invoice_master_faktnr</cmr-field-name>
</cmr-field>
</ejb-relationship-role>
</ejb-relation>
</relationships>
<assembly-descriptor>
<!--Requires transaction -->
<container-transaction>
<method>
<ejb-name>AutomaticPosting</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>CustomerEJB</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>CustomerFacade</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>DebtorEJB</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>DebtorFacade</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>FormArchive</ejb-name>
<method-name>storeForm</method-name>
</method>
<method>
<ejb-name>FormArchive</ejb-name>
<method-name>storeFormData</method-name>
</method>
<method>
<ejb-name>FormArchive</ejb-name>
<method-name>updateFormPaper</method-name>
</method>
<method>
<ejb-name>FormArchive</ejb-name>
<method-name>updateFormVO</method-name>
</method>
<method>
<ejb-name>FormArchive</ejb-name>
<method-name>updateFormVO</method-name>
</method>
<method>
<ejb-name>LookupEJB</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>LookupFacade</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>ReminderEJB</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>SystemEJB</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>UserManager</ejb-name>
<method-name>*</method-name>
</method>
<trans-attribute>Required</trans-attribute>
</container-transaction>
<!-- Supports transaction -->
<container-transaction>
<method>
<ejb-name>FormArchive</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>DebtorEJB</ejb-name>
<method-name>getDeb600Report</method-name>
</method>
<method>
<ejb-name>DebtorEJB</ejb-name>
<method-name>getDeb610Report</method-name>
</method>
<trans-attribute>Supports</trans-attribute>
</container-transaction>
<!-- Never uses transaction -->
<container-transaction>
<method>
<ejb-name>DebtorFacade</ejb-name>
<method-name>getDeb600Report</method-name>
</method>
<method>
<ejb-name>DebtorFacade</ejb-name>
<method-name>getDeb610Report</method-name>
</method>
<method>
<ejb-name>DebtorFacade</ejb-name>
<method-name>getDeb997Report</method-name>
</method>
<method>
<ejb-name>DebtorFacade</ejb-name>
<method-name>getReportCustWithStopCode</method-name>
</method>
<method>
<ejb-name>DebtorFacade</ejb-name>
<method-name>getReportStopCodeTotal</method-name>
</method>
<method>
<ejb-name>DebtorFacade</ejb-name>
<method-name>getPostingJournalReport</method-name>
</method>
<method>
<ejb-name>DebtorEJB</ejb-name>
<method-name>getDeb997Report</method-name>
</method>
<method>
<ejb-name>DebtorEJB</ejb-name>
<method-name>getReportCustWithStopCode</method-name>
</method>
<method>
<ejb-name>DebtorEJB</ejb-name>
<method-name>getReportStopCodeTotal</method-name>
</method>
<method>
<ejb-name>DebtorEJB</ejb-name>
<method-name>getPostingJournalReport</method-name>
</method>
<method>
<ejb-name>ValueLister</ejb-name>
<method-name>*</method-name>
</method>
<method>
<ejb-name>CustomerFacade</ejb-name>
<method-name>getReportSubs76x</method-name>
</method>
<method>
<ejb-name>CustomerFacade</ejb-name>
<method-name>getReportSubs820</method-name>
</method>
<method>
<ejb-name>CustomerFacade</ejb-name>
<method-name>getReportSubs820Tot</method-name>
</method>
<method>
<ejb-name>CustomerEJB</ejb-name>
<method-name>getReportSubs76x</method-name>
</method>
<method>
<ejb-name>CustomerEJB</ejb-name>
<method-name>getReportSubs820</method-name>
</method>
<method>
<ejb-name>CustomerEJB</ejb-name>
<method-name>getReportSubs820Tot</method-name>
</method>
<trans-attribute>NotSupported</trans-attribute>
</container-transaction>
</assembly-descriptor>
</ejb-jar>
and the orion-ejb-jar
<?xml version = '1.0' encoding = 'windows-1252'?>
<!DOCTYPE orion-ejb-jar PUBLIC "-//Evermind//DTD Enterprise JavaBeans 2.0 runtime//EN" "http://xmlns.oracle.com/ias/dtds/orion-ejb-jar.dtd">
<orion-ejb-jar>
<enterprise-beans>
<entity-deployment name="Invoice_master" data-source="jdbc/OracleDS2" table="INVOICE_MASTER">
<primkey-mapping>
<cmp-field-mapping name="faktnr" persistence-name="FAKTNR" persistence-type="NUMBER(12)"/>
</primkey-mapping>
<cmp-field-mapping name="faktnr" persistence-name="FAKTNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="split_faktnr" persistence-name="SPLIT_FAKTNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="fak_kred_kode" persistence-name="FAK_KRED_KODE" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="faktura_dato" persistence-name="FAKTURA_DATO" persistence-type="DATE"/>
<cmp-field-mapping name="forfalds_dato" persistence-name="FORFALDS_DATO" persistence-type="DATE"/>
<cmp-field-mapping name="bureaunr" persistence-name="BUREAUNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="kundenr" persistence-name="KUNDENR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="moms_pct" persistence-name="MOMS_PCT" persistence-type="NUMBER(5,2)"/>
<cmp-field-mapping name="inf_pct" persistence-name="INF_PCT" persistence-type="NUMBER(5,2)"/>
<cmp-field-mapping name="shs_pct" persistence-name="SHS_PCT" persistence-type="NUMBER(5,2)"/>
<cmp-field-mapping name="ant_detail_lin" persistence-name="ANT_DETAIL_LIN" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="invoice_ad_master_faktnr">
<collection-mapping table="INVOICE_AD_MASTER">
<primkey-mapping>
<cmp-field-mapping>
<entity-ref home="Invoice_master">
<cmp-field-mapping persistence-name="FAKTNR" persistence-type="NUMBER(12)"/>
</entity-ref>
</cmp-field-mapping>
</primkey-mapping>
<value-mapping type="dk.son.nms.ejb.entity.Invoice_ad_masterLocal">
<cmp-field-mapping>
<entity-ref home="Invoice_ad_master">
<cmp-field-mapping>
<fields>
<cmp-field-mapping name="faktnr" persistence-name="FAKTNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="avisnr" persistence-name="AVISNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="ugenr" persistence-name="UGENR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="annnr" persistence-name="ANNNR" persistence-type="NUMBER(12)"/>
</fields>
</cmp-field-mapping>
</entity-ref>
</cmp-field-mapping>
</value-mapping>
</collection-mapping>
</cmp-field-mapping>
</entity-deployment>
<entity-deployment name="Invoice_ad_master" data-source="jdbc/OracleDS2" table="INVOICE_AD_MASTER">
<primkey-mapping>
<cmp-field-mapping>
<fields>
<cmp-field-mapping name="faktnr" persistence-name="FAKTNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="avisnr" persistence-name="AVISNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="ugenr" persistence-name="UGENR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="annnr" persistence-name="ANNNR" persistence-type="NUMBER(12)"/>
</fields>
</cmp-field-mapping>
</primkey-mapping>
<cmp-field-mapping name="avisnr" persistence-name="AVISNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="ugenr" persistence-name="UGENR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="annnr" persistence-name="ANNNR" persistence-type="NUMBER(12)"/>
<cmp-field-mapping name="avis" persistence-name="AVIS" persistence-type="NUMBER(2)"/>
<cmp-field-mapping name="snr" persistence-name="SNR" persistence-type="NUMBER(6)"/>
<cmp-field-mapping name="ann_text" persistence-name="ANN_TEXT" persistence-type="VARCHAR2(200)"/>
<cmp-field-mapping name="dekort_flg" persistence-name="DEKORT_FLG" persistence-type="VARCHAR2(1)"/>
<cmp-field-mapping name="ant_detail_records" persistence-name="ANT_DETAIL_RECORDS" persistence-type="NUMBER(6)"/>
<cmp-field-mapping name="faktura_type" persistence-name="FAKTURA_TYPE" persistence-type="NUMBER(2)"/>
<cmp-field-mapping name="del_udg" persistence-name="DEL_UDG" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="ordrenr" persistence-name="ORDRENR" persistence-type="NUMBER(9)"/>
<cmp-field-mapping name="invoice_master_faktnr">
<entity-ref home="Invoice_master">
<cmp-field-mapping persistence-name="FAKTNR" persistence-type="NUMBER(12)"/>
</entity-ref>
</cmp-field-mapping>
</entity-deployment>
<entity-deployment name="Invoice_ad_detail" data-source="jdbc/OracleDS2" table="INVOICE_AD_DETAIL">
<primkey-mapping>
<cmp-field-mapping>
<fields>
<cmp-field-mapping name="avisnr" persistence-name="AVISNR" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="annnr" persistence-name="ANNNR" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="lobnr" persistence-name="LOBNR" persistence-type="NUMBER(8)"/>
</fields>
</cmp-field-mapping>
</primkey-mapping>
<cmp-field-mapping name="avisnr" persistence-name="AVISNR" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="annnr" persistence-name="ANNNR" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="lobnr" persistence-name="LOBNR" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="varenr" persistence-name="VARENR" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="varegrpnr" persistence-name="VAREGRPNR" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="lintypkode" persistence-name="LINTYPKODE" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="rabatkode" persistence-name="RABATKODE" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="text" persistence-name="TEXT" persistence-type="VARCHAR2(60)"/>
<cmp-field-mapping name="spalter" persistence-name="SPALTER" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="hoejde" persistence-name="HOEJDE" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="ant_enh" persistence-name="ANT_ENH" persistence-type="NUMBER(8)"/>
<cmp-field-mapping name="sats" persistence-name="SATS" persistence-type="NUMBER(13,2)"/>
</entity-deployment>
</enterprise-beans>
<assembly-descriptor>
<default-method-access>
<security-role-mapping impliesAll="true" name="<default-ejb-caller-role>"/>
</default-method-access>
</assembly-descriptor>
</orion-ejb-jar> -
Com.evermind.server.rmi.RMIClientContext.lookup ERROR
Hello,
I'm trying to follow up the JavaEE_tutorial.PDF (http://www.oracle.com/technology/obe/JavaEE_tutorial_10131/index.htm) and when want to testing the Data Model I get this error:
D:\oracle\jdevstudio10131\jdk\bin\javaw.exe -client -classpath D:\oracle\jdevstudio10131\jdev\mywork\SRDEMO\Model\classes;D:\oracle\jdevstudio10131\j2ee\home\lib\ejb30.jar;D:\oracle\jdevstudio10131\toplink\jlib\toplink-essentials.jar;D:\oracle\jdevstudio10131\j2ee\home\lib\activation.jar;D:\oracle\jdevstudio10131\j2ee\home\lib\ejb.jar;D:\oracle\jdevstudio10131\j2ee\home\lib\jms.jar;D:\oracle\jdevstudio10131\j2ee\home\lib\jta.jar;D:\oracle\jdevstudio10131\j2ee\home\lib\mail.jar;D:\oracle\jdevstudio10131\j2ee\home\lib\servlet.jar;D:\oracle\jdevstudio10131\jdev\system\oracle.j2ee.10.1.3.39.84\embedded-oc4j\.client;D:\oracle\jdevstudio10131\j2ee\home\oc4j.jar;D:\oracle\jdevstudio10131\j2ee\home\lib\oc4j-internal.jar;D:\oracle\jdevstudio10131\opmn\lib\optic.jar;D:\oracle\jdevstudio10131\toplink\jlib\toplink.jar;D:\oracle\jdevstudio10131\toplink\jlib\toplink-oc4j.jar;D:\oracle\jdevstudio10131\toplink\jlib\antlr.jar org.srdemo.client.ServiceRequestFacadeClientEmbed
javax.naming.CommunicationException: Connection refused: connect [Root exception is java.net.ConnectException: Connection refused: connect]
at com.evermind.server.rmi.RMIClient.lookup(RMIClient.java:292)
at com.evermind.server.rmi.RMIClientContext.lookup(RMIClientContext.java:51)
at javax.naming.InitialContext.lookup(InitialContext.java:351)
at org.srdemo.client.ServiceRequestFacadeClientEmbed.main(ServiceRequestFacadeClientEmbed.java:23)
Caused by: java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at java.net.Socket.connect(Socket.java:507)
at java.net.Socket.connect(Socket.java:457)
at java.net.Socket.<init>(Socket.java:365)
at java.net.Socket.<init>(Socket.java:207)
at com.evermind.server.rmi.RMIClientConnection.createSocket(RMIClientConnection.java:682)
at oracle.oc4j.rmi.ClientSocketRmiTransport.createNetworkConnection(ClientSocketRmiTransport.java:58)
at oracle.oc4j.rmi.ClientRmiTransport.connectToServer(ClientRmiTransport.java:78)
at oracle.oc4j.rmi.ClientSocketRmiTransport.connectToServer(ClientSocketRmiTransport.java:68)
at com.evermind.server.rmi.RMIClientConnection.connect(RMIClientConnection.java:646)
at com.evermind.server.rmi.RMIClientConnection.sendLookupRequest(RMIClientConnection.java:190)
at com.evermind.server.rmi.RMIClientConnection.lookup(RMIClientConnection.java:174)
at com.evermind.server.rmi.RMIClient.lookup(RMIClient.java:283)
... 3 more
Process exited with exit code 0.
Thanks in advance for your help,
MiguelIt does work!!
I have a incorrect connection pool in the data-sources.xml
Bye -
I am getting the following error while running JSP. Can anyone guide me.
Caught "com.evermind.server.rmi.OrionRemoteException" while attempting to find all DepartmentBean entries.
com.evermind.server.rmi.OrionRemoteException: Database error: Io exception: The Network Adapter could not establish the connection; nested exception is: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
Add entry
I have doubt in
My rmi.xml file
<?xml version="1.0" standalone='yes'?>
<!DOCTYPE rmi-server PUBLIC "Orion RMI-server" "http://xmlns.oracle.com/ias/dtds/rmi-server.dtd">
<rmi-server port="23791" >
<!-- A remote server connection example -->
<!-- <server host="the.remote.server.com" username="adminUser" password="123abc" /> -->
<!-- <server host="169.254.162.207" username="admin" password="welcome" /> -->
<!-- <server host="prg-fg9s9g12dnz" username="admin" password="welcome" /> -->
<!-- path to the log-file where RMI-events/errors are stored -->
<log>
<file path="../log/rmi.log" />
</log>
</rmi-server>
If I give server host line My oc4j server is NOT initialized.
In My Data Sources file :
<data-source
class="com.evermind.sql.DriverManagerDataSource"
name="jdbc/DBConnection"
location="jdbc/OracleCoreDS"
xa-location="jdbc/xa/OracleXADS"
ejb-location="jdbc/DBConnection"
connection-driver="oracle.jdbc.driver.OracleDriver"
username="RajiveShukla"
password="pujavrms1"
url="jdbc:oracle:thin:@localhost:1521:wbs"
inactivity-timeout="30"
/>
And JSP which I run is :
<%
* list.jsp
* Lists all the entries stored through EmployeeBean. This JSP is the only JSP
* that will actually connect to the entity bean. On success, it will save a
* reference to the entity bean in the session. So there will be one reference
* to the bean per session.
%>
<%@ page import="com.webstore.*,java.io.*,java.net.*,java.util.*,javax.naming.*,javax.rmi.*" %>
<%
// Make sure this page will not be cached by the browser
response.addHeader("Pragma", "no-cache");
response.addHeader("Cache-Control", "no-store");
// We will send error messages to System.err, for verbosity. In a real
// application you will probably not want this.
PrintStream errorStream = System.err;
// If we find any fatal error, we will store it in the "error" variable. If
// an exception is caught that corresponds with this error message, then we
// will store it in the "exception" variable.
String error = null;
Exception exception = null;
// First check if the reference to the EJB is already stored in the session.
DepartmentHome home = (DepartmentHome) session.getAttribute("DepartmentHome");
// If not, then attempt to get the initial JNDI context.
if (home == null) {
// When attempting to connect to JNDI, we store the reference to the
// initial JNDI context in this variable. We will use it to lookup the
// entity bean.
Context context = null;
try {
context = new InitialContext();
} catch (Exception e) {
exception = e;
error = "Caught \"" + exception.getClass().getName() + "\" while " +
"attempting to create the initial JNDI context.";
errorStream.println(error);
exception.printStackTrace(errorStream);
// We have specified "EmployeeBean" in the web.xml file as the name
// by which we would like to contact the EmployeeBean home interface. We will
// have to prepend "java:comp/env/", the root `directory' for enterprise
// beans.
//final String location = "java:comp/env/DepartmentBean";
if (error == null) {
try {
// Attempt to lookup an object at the specified location in the JNDI
// context.
//Object boundObject = context.lookup(location);
Object boundObject = context.lookup("Department");
// Try to convert it to an instance of EmployeeBean, the home
// interface for our bean.
home = (DepartmentHome) PortableRemoteObject.narrow(boundObject,
DepartmentHome.class);
// If we got this far, we've done it, let's save the reference to the
// Employee home interface in the session for future use by both
// this page and the other JSP pages.
session.setAttribute("DepartmentHome", home);
} catch (Exception e) {
exception = e;
error = "Caught \"" + exception.getClass().getName() + "\" while " +
"attempting to lookup the Department bean at \"" + "\".";
//location + "\".";
errorStream.println(error);
exception.printStackTrace(errorStream);
// This is the variable we will store all records in.
Collection recs = null;
if (error == null) {
try {
recs = home.findAll();
} catch (Exception e) {
exception = e;
error = "Caught \"" + exception.getClass().getName() + "\" while " +
"attempting to find all DepartmentBean entries.";
errorStream.println(error);
exception.printStackTrace(errorStream);
// Decide what the title will be.
String title;
if (error != null) {
title = "Error";
} else {
title = "com.webstore | List of entries";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE><%= title %></TITLE>
</HEAD>
<BODY bgcolor="#FFFFFF">
<H1><%= title %></H1>
<%
// Display the error message, if any.
if (error != null) {
%>
<P><BLOCKQUOTE><%= error %></BLOCKQUOTE>
<%
// Display the exception message, if any.
if (exception != null) {
%>
<P><BLOCKQUOTE><CODE><%= exception %></CODE></BLOCKQUOTE>
<%
} /* if */
} else {
// If there are no recs to be displayed, display a descriptive text.
if (recs.size() == 0) {
%>
<P><BLOCKQUOTE>No entries found.</BLOCKQUOTE>
<%
// Otherwise display a table with all columns, and
// display two extra choices: "Edit" and "Delete".
} else {
%>
<P><TABLE border="1" width="100%">
<TR>
<TD><STRONG>DptNo (long)</STRONG></TD>
<TD><STRONG>DptName (String)</STRONG></TD>
<TD><STRONG>Actions</STRONG></TD>
</TR>
<%
Iterator iterator = recs.iterator();
while(iterator.hasNext()) {
Department rec = (Department) PortableRemoteObject.narrow(iterator.next(),
Department.class);
long dptNo = rec.getDptno();
String dptName= rec.getDptname();
// put all pk columns in hashtable for URLEncoding
Hashtable cols = new Hashtable();
cols.put("DPTNO",Long.valueOf("dptNo"));
// URLEncode columns as params to JSP
StringBuffer buf = new StringBuffer();
Enumeration params = cols.keys();
while (params.hasMoreElements()) {
String param = (String)params.nextElement();
String value = (String)cols.get(param);
buf.append(URLEncoder.encode(param) +
"=" + URLEncoder.encode(value));
if (params.hasMoreElements())
buf.append("&");
String editURL = "dptedit.jsp?" + buf;
String deleteURL = "dptdelete.jsp?" + buf;
%>
<TR>
<TD><%= dptNo %></TD>
<TD><%= dptName %></TD>
<TD><A href="<%= editURL %>">Edit</A> <A href="<%= deleteURL %>">Delete</A></TD>
</TR>
<%
} /* for */
%>
</TABLE>
<%
} /* else */
} /* else */
// Finally display a link to the page that allows the user to add an entry
// to the address book.
%>
<P><TABLE border="1">
<TR><TD><A href="dptadd.jsp">Add entry</A></TD></TR>
</TABLE>
</BODY>
</HTML>
Please guide me..Hi Avi,
Thanks,
I have already used earlier..
the data-sources file is as under.
<data-source class="com.evermind.sql.DriverManagerDataSource" name="jdbc/DBConnection" location="jdbc/OracleCoreDS" xa-location="jdbc/xa/OracleXADS" ejb-location="com.webstore.Department" connection-driver="oracle.jdbc.driver.OracleDriver" username="RajiveShukla" password="pxujxa" url="jdbc:oracle:thin:@PRG-FG9S9G12DNZ:1521:wbs" inactivity-timeout="30"/>
</data-sources>
The username and password and sid, I can connect in the sqlPlus
Do we have to give remote server name in rmi.xml.. It is not initilizing the J2EE server if we give that.??
I am using thin driver , if any change or any settings please write me..
Thanks in advance..
Rajive -
My application is in Java Swings , EJB, Oracle 9iAs.
Intitally application is working fine but after some time we are facing the application sever hangup problem.
for e.g. when client application is trying to lookup for the remote object, the application server is not responding anything.
In addition to this, I would like to know that when the method com.evermind.server.rmi.RMIContext.unbindAll() is called?
The information related to deadlock is as under:
FOUND A JAVA LEVEL DEADLOCK:
"RMIConnectionThread":
waiting to lock monitor 0x1aeb80 (object 0x46bca9b8, a java.util.HashMap),
which is locked by "RMICallHandler-5"
"RMICallHandler-5":
waiting to lock monitor 0x1aeb00 (object 0x46066708, a com.evermind.server.rmi.RMIServer),
which is locked by "RMIConnectionThread"
VipulRussel ,
Have you started remote OC4J Server? Also can you able to browse
JNDI tree of Remote OC4J Server from JDeveloper?
Also provide following information in order to understand your problem fully
1. Which OC4J version you are using?
2. Platform in which you are testing your application?
3. Provide full stack trace of error that you are getting
Cheers
--Venky -
I am getting the below error when the server is started. Can any one let me know why do we get this error?
13/01/13 23:33:28.432 10.1.3.5.0 Started
13/01/14 00:46:53.915 Internal server error
java.lang.NullPointerException
at com.evermind.server.ObjectReferenceCleaner.resetApplicationLogger(ObjectReferenceCleaner.java:260)
at com.evermind.server.ObjectReferenceCleaner.cleanupApplicationLogger(ObjectReferenceCleaner.java:167)
at com.evermind.server.ObjectReferenceCleaner.loaderDestroyed(ObjectReferenceCleaner.java:94)
at oracle.classloader.EventDispatcher.loaderDestroyed(EventDispatcher.java:254)
at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1187)
at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1126)
at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1069)
at com.evermind.server.ApplicationStateRunning.destroyClassLoaders(ApplicationStateRunning.java:1201)
at com.evermind.server.Application.stateCleanUp(Application.java:3766)
at com.evermind.server.Application.destroy(Application.java:802)
at com.evermind.server.ApplicationServer.destroyApplications(ApplicationServer.java:2337)
at com.evermind.server.ApplicationServer.destroy(ApplicationServer.java:2124)
at com.evermind.server.ApplicationServerShutdownHandler.run(ApplicationServerShutdownHandler.java:93)
at java.lang.Thread.run(Thread.java:662)
13/01/14 00:48:42.413 10.1.3.5.0 StartedI am getting the below error when the server is started. Can any one let me know why do we get this error?
13/01/13 23:33:28.432 10.1.3.5.0 Started
13/01/14 00:46:53.915 Internal server error
java.lang.NullPointerException
at com.evermind.server.ObjectReferenceCleaner.resetApplicationLogger(ObjectReferenceCleaner.java:260)
at com.evermind.server.ObjectReferenceCleaner.cleanupApplicationLogger(ObjectReferenceCleaner.java:167)
at com.evermind.server.ObjectReferenceCleaner.loaderDestroyed(ObjectReferenceCleaner.java:94)
at oracle.classloader.EventDispatcher.loaderDestroyed(EventDispatcher.java:254)
at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1187)
at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1126)
at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1069)
at com.evermind.server.ApplicationStateRunning.destroyClassLoaders(ApplicationStateRunning.java:1201)
at com.evermind.server.Application.stateCleanUp(Application.java:3766)
at com.evermind.server.Application.destroy(Application.java:802)
at com.evermind.server.ApplicationServer.destroyApplications(ApplicationServer.java:2337)
at com.evermind.server.ApplicationServer.destroy(ApplicationServer.java:2124)
at com.evermind.server.ApplicationServerShutdownHandler.run(ApplicationServerShutdownHandler.java:93)
at java.lang.Thread.run(Thread.java:662)
13/01/14 00:48:42.413 10.1.3.5.0 Started -
Com.evermind.server.http.HttpIOException: Broken pipe
i am getting this error at my server. Can anybody help me in solving this. I am using Oracle 9iAs..and this is the full error that i get
com.evermind.server.http.HttpIOException: Broken pipe
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.fillInStackTrace(Compiled Code)
at java.lang.Throwable.<init>(Compiled Code)
at java.lang.Exception.<init>(Compiled Code)
at java.io.IOException.<init>(Compiled Code)
at com.evermind.server.http.HttpIOException.<init>(Compiled Code)
at com.evermind.server.http.EvermindServletOutputStream.write(Compiled C
ode)
at com.evermind.server.http.EvermindServletOutputStream.write(Compiled C
ode)
at com.evermind.server.http.EvermindServletOutputStream.write(Compiled C
ode)
at com.evermind.server.http.HttpApplication.include(Compiled Code)
at com.evermind.server.http.FileRequestDispatcher.forwardInternal(Compil
ed Code)
at com.evermind.server.http.FileRequestDispatcher.forward(Compiled Code)
at Premier.RegistrationServlet.createHTML(Compiled Code)
at Premier.RegistrationServlet.doGet(Compiled Code)
at javax.servlet.http.HttpServlet.service(Compiled Code)
at javax.servlet.http.HttpServlet.service(Compiled Code)
at com.evermind.server.http.ServletRequestDispatcher.invoke(Compiled Cod
e)
at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(Com
piled Code)
at com.evermind.server.http.HttpRequestHandler.processRequest(Compiled C
ode)
at com.evermind.server.http.HttpRequestHandler.run(Compiled Code)
at com.evermind.util.ThreadPoolThread.run(Compiled Code)I suggest you recompile your servlet RegistrationServlet with the debug option that way you will get the line in your source code that has triggered the Exception instead of (Compiled Code). From then on it will be easier for you to start undestanding what's going on.
-
Com.evermind.server.http.HttpIOException: Read timed out
Hello,
I am using embded oracle oc4j server and getting following exception, and I cant fine httpd.conf file to increase KeepTimeout
ERROR : HttpRequestHandler-1229 com.tcs.sgv.common.exception.BaseException - The stack trace is:
com.evermind.server.http.HttpIOException: Read timed out
at com.evermind.server.http.EvermindServletInputStream.read(EvermindServletInputStream.java:92)
at javax.servlet.ServletInputStream.readLine(ServletInputStream.java:138)
at com.hhc.MultipartInputStreamHandler.readLine(MultipartRequest.java:831)
at com.hhc.MultipartInputStreamHandler.readLine(MultipartRequest.java:808)
at com.hhc.MultipartRequest.readRequest(MultipartRequest.java:394)
at com.hhc.MultipartRequest.<init>(MultipartRequest.java:222)
at com.tcs.sgv.fms.requesthandler.NotingRequestHandler.getNotings(NotingRequestHandler.java:1250)
at com.tcs.sgv.fms.requesthandler.NotingRequestHandler.processRequest(NotingRequestHandler.java:304)
at com.tcs.sgv.common.servlet.FrontServlet.processRequest(FrontServlet.java:171)
at com.tcs.sgv.common.servlet.FrontServlet.doPost(FrontServlet.java:112)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:778)
at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:270)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)
at java.lang.Thread.run(Thread.java:534)
- 10 Jul 2009 05:10:24,782 - 703516 milliseconds
Please help me regarding this problemOracle have their own support forums at http://otn.oracle.com
You may also want to search MetaLink.
Maybe you are looking for
-
How to connect an early 2009 MacBook Pro to a TV via HDMI
I have the cables and adapter but am only getting one image when all is hooked up.......what else need I do? I've seen youtube instructions but I seem to lack the "arrangement menu under the "displays" preference....... Is this MacBook unable to run
-
How can I transfer movies from my pc to iPad
Problem to transfer movie from pc to iPad
-
[SOLVED] nvidia and xorg-server, slow start compared to nv
I've seen many similar topics but none that have been solved, therefore the new topic. Starting xorg with nv driver takes just a few seconds to desktop, while using nvidia takes almost 10 seconds more to get to desktop. Although after reaching deskto
-
VS 2005 ODBC Connection for CR XI Report
Post Author: Mohan56 CA Forum: .NET Hello, In VS 2005, I am using the CrystalReportViewer to display my report on Windows Form. This report uses the ODBC connection (defined in System Data Sources Name (DSN) as infimacs) to an Informix database, usi
-
Hello, Can anybody help me finding SAP or other documentation related with DMS (Document Management System)? Thanks, Regards, Ana