For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub
- This topic has 4 replies, 2 voices, and was last updated 19 years, 7 months ago by
jstorck.
-
AuthorPosts
-
jstorckMemberI’m horribly sorry if this question has come up and been covered already, but I’m having a horrible time getting JNDI lookups to work with OC4J. I’ve taken the example EAP “TraderX” from this site, and tried to run it on OC4J and as downloaded, it does not work.
In the TraderX EJB project, I added the OC4J doclet so that XDoclet would produce the orion-ejb-jar.xml. It creates the xml file with this as it’s content:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE orion-ejb-jar PUBLIC "-//Evermind//DTD Enterprise JavaBeans 1.1 runtime//EN" "http://xmlns.oracle.com/ias/dtds/orion-ejb-jar.dtd"> <orion-ejb-jar deployment-version="9.0.3.0.0"> <enterprise-beans> <!-- Session Beans deployment --> <session-deployment name="Trader" location="ejb/com/genuitec/trader/ejb/TraderHome" > </session-deployment> <!-- Entity Beans deployment --> <!-- Message Driven Beans deployment --> <!-- To add additional beans that you have deployment descriptor info for, put a file in your XDoclet merge directory called oc4j-beans.ent that contains the session-deployment, entity-deployment or message-driven-deployment markup for those beans. --> </enterprise-beans> </orion-ejb-jar>
However, when I brows to http://localhost:8888/TraderWeb, and fill out the form and submit it, it displays a page (in raw html, instead of parsing it), informing that it cannot find ejb/com/genuitec/trader/ejb/TraderHome, and also reports a NullPointerException.
Has anyone gotten this example to work on OC4J? Oracle’s site seems to be lacking in decent example code for OC4J and JNDI lookup. The few how-tos I found were missing their sample code snippets.
Thanks in advance. I must admit, I’m very new to J2EE, and since I’m not very clear on J2EE as a whole, I’m probably not searching the right places to find the answers I need.
Hopefully someone can kick me in the right direction here?
January 13, 2006 at 5:56 pm #244575
Riyad KallaMemberWhat happens when you change your EJB lookup string to:
java:comp/env/ejb/com/genuitec/trader/ejb/TraderHomeOR TRY
comp/env/ejb/com/genuitec/trader/ejb/TraderHome
?
January 17, 2006 at 2:41 pm #244693
jstorckMemberWell, things are working fine with JBoss, but now when I deploy to OC4J, it seems that the html is being spit out in the browser without being parsed by the browser. I’m looking into that now, but it’s a different error than I was getting before (which was why I posted originally). For the life of me I can’t figure out what I’ve changed to make the browser output the HTML code instead of parsing it. I’m using Firefox — haven’t tried it in IE yet.
Thanks for your reply. Once I get this thing so it is parsing the HTML, I’ll try changing the lookup string.
January 17, 2006 at 2:45 pm #244694
jstorckMemberQuick addition, the HTML pages are parsed, but the JSP pages are not.
January 17, 2006 at 2:57 pm #244697
jstorckMemberYet another addition — TraderWeb example seems to work fine in IE. Firefox seems to have a hiccup with JSP, although not if the app server is JBoss. Real weird. Probably my ignorance of this stuff, and the setup of the app servers. It’d make sense though, if the app server is screwing things up — I wouldn’t blame it on the browsers. Somewhere it’s got to be my fault!
-
AuthorPosts