Which SUN J2EE Certification?
Hi,
I am currently studying Java to get a better understanding of the underlying technology for EP 6.0.
I've just completed the Java Programmer Certification and want to move onto one of the three available J2EE certifications available.
The following are available:
- SUN Certified Web Component Developer
- SUN Certified Business Component Developer
- SUN Certified Developer for Java Web Services
I'm sure they are all relevant in some way but since there is a considerable time investment involved I'd like to start with the most relevant one. Can anyone recommend which is the most appropriate to start with?
Thanks in advance for any help.
Richard
Hi.Based on the course outline, i personally think Web Component Developer should be started. It covers the basics on web development. Depends on your job scope, if you want to explore further to web service, then SUN Certified Developer for Java Web Services will be next.
Similar Messages
-
I encountered a bug while using the deploytool to deploy
an EAR file to the Sun J2EE 1.3_01 server.
I submitted a bug report to Sun via the Sun Java Developer Connection.
(Sorry, it has not been assigned a BugID yet)
Question:
Does anybody know if the web container in Sun's
J2EE 1.3_01 server supports access to local enterprise beans?
Screenshots of the bug are available at
http://sync4j.sourceforge.net/deploymentbug/
Full details below....
-Sean
category: j2ee
subcategory: deployment
release: 1.3_01
hardware: x86
OSversion: windows_2000
synopsis: java.lang.ClassCastException thrown during deployment of Session bean
java -version
java version "1.3.1_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01)
Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)
C:\j2sdkee1.3\bin>j2ee -version
Java 2 Enterprise Edition version 1.3_01, build 1.3_01-b01
I built a EJB 2.0 compliant stateful session bean.
The session bean has a remote interface (ISyncRemote),
a remote home interface (ISyncHomeRemote),
a local interface (ISyncLocal),
and a local home interface (ISyncHomeLocal).
I built an HTTP Servlet that is supposed to access
the Stateful Session Bean using ISyncHomeLocal and
ISyncLocal
I run "deploytool.bat" in GUI mode to perform the deployment.
During deployment, the deploytool GUI displays a message
box which states:
"There was a deployment error.
java.rmi.ServerException: RemoteException occurred in server thread;
nested exception is:
java.rmi.RemoteException: An error was encountered while loading
a web component.
Please refer to
<J2EE_HOME>/logs/<machine-name>/j2ee//j2ee/error.log
for more information. Please verify your Application with the
Verifier tool."
The "error.log" file did not contain any useful information.
I ran the J2EE "verifier.bat" tool to verify that my EAR archive is OK.
The Sun J2EE server output this error string:
"java.lang.ClassCastException:
com.sun.enterprise.deployment.EjbExternalDescriptor"
Here is the full output from the Sun J2EE server:
C:\j2sdkee1.3\bin>j2ee -verbose
J2EE server listen port: 1050
Naming service started:1050
Binding DataSource, name = jdbc/EstoreDB, url =
jdbc:cloudscape:rmi:CloudscapeDB;create=true
Binding DataSource, name = jdbc/Cloudscape, url =
jdbc:cloudscape:rmi:CloudscapeDB;create=true
Binding DataSource, name = jdbc/DB1, url =
jdbc:cloudscape:rmi:CloudscapeDB;create=true
Binding DataSource, name = jdbc/DB2, url =
jdbc:cloudscape:rmi:CloudscapeDB;create=true
Binding DataSource, name = jdbc/InventoryDB, url =
jdbc:cloudscape:rmi:CloudscapeDB;create=true
Binding DataSource, name = jdbc/XACloudscape, url = jdbc/XACloudscape__xa
Binding DataSource, name = jdbc/XACloudscape__xa, dataSource =
COM.cloudscape.core.RemoteXaDataSourc
e@245536
Starting JMS service...
Initialization complete - waiting for client requests
Binding: < JMS Destination : jms/Queue , javax.jms.Queue >
Binding: < JMS Destination : jms/Topic , javax.jms.Topic >
Binding: < JMS Cnx Factory : TopicConnectionFactory , Topic , No properties >
Binding: < JMS Cnx Factory : jms/TopicConnectionFactory , Topic , No properties
>
Binding: < JMS Cnx Factory : QueueConnectionFactory , Queue , No properties >
Binding: < JMS Cnx Factory : jms/QueueConnectionFactory , Queue , No properties
>
Starting web service at port: 8000
Starting secure web service at port: 7000
J2EE SDK/1.3
Starting web service at port: 9191
J2EE SDK/1.3
J2EE server startup complete.
Compiling c:\j2sdkee1.3\repository\rbi\gnrtrTMP\Sync4j Server enterprise
application\sync4j\server\s
yncbean\SyncBean_LocalHomeImpl.java ....
Compiling c:\j2sdkee1.3\repository\rbi\gnrtrTMP\Sync4j Server enterprise
application\sync4j\server\s
yncbean\SyncBean_EJBLocalObjectImpl.java ....
Compiling c:\j2sdkee1.3\repository\rbi\gnrtrTMP\Sync4j Server enterprise
application\sync4j\server\s
yncbean\SyncBean_RemoteHomeImpl.java ....
Compiling c:\j2sdkee1.3\repository\rbi\gnrtrTMP\Sync4j Server enterprise
application\sync4j\server\s
yncbean\SyncBean_EJBObjectImpl.java ....
rmic sync4j.server.syncbean.SyncBean_RemoteHomeImpl...
rmic sync4j.server.syncbean.SyncBean_EJBObjectImpl...
c:\j2sdkee1.3\repository\rbi\applications\Sync4j Server enterprise
application1004172068449Server.ja
r
Binding name:`java:comp/env/ejb/ISyncHomeRemote`
Binding name:`java:comp/env/ejb/ISyncHomeLocal`
java.lang.ClassCastException:
com.sun.enterprise.deployment.EjbExternalDescriptor
at com.sun.enterprise.deployment.EjbReferenceDescriptor.getValue
(EjbReferenceDescriptor.java
:202)
at com.sun.enterprise.naming.NamingManagerImpl.bindObjects
(NamingManagerImpl.java:394)
at com.sun.web.server.WebService.addContext(WebService.java:148)
at com.sun.web.server.ServletDeployerImpl.loadWebComponents
(ServletDeployerImpl.java:214)
at
com.sun.enterprise.tools.deployment.backend.JarInstallerImpl.deployWebComponent
s
(JarInsta
llerImpl.java:791)
at
com.sun.enterprise.tools.deployment.backend.JarInstallerImpl.deployApplication
(JarInstall
erImpl.java:219)
at
org.omg.stub.com.sun.enterprise.tools.deployment.backend._JarInstallerImpl_Tie.
invoke(Un
known Source)
at com.sun.corba.ee.internal.corba.ServerDelegate.dispatch
(ServerDelegate.java:355)
at com.sun.corba.ee.internal.iiop.ORB.process(ORB.java:273)
at com.sun.corba.ee.internal.iiop.RequestProcessor.process
(RequestProcessor.java:84)
at com.sun.corba.ee.internal.orbutil.ThreadPool$PooledThread.run
(ThreadPool.java:99)
Does the Sun J2EE server implementation support the invocation
of Session EJB's via a Local interface?
Does the Sun J2EE server implementation allow a Servlet to invoke
Session EJB's via the bean's Local interface?
While researching this issue, I read the J2EE 1.3 final specification.
The spec says:
"The EJB container is required to access to local enterprise beans.
We recommend that the web container also support access to local
enterprise beans."
Does the web container in Sun's J2EE server support access to local enterprise beans?I'm pretty much sure that you cannot access a
local Session bean from outside the EJB container.Please read the J2EE 1.3 specification before posting messages about EJB and J2EE.
According to the J2EE 1.3 specification:
"The EJB container is required to support access to local enterprise beans. We recommend that the web container also support access to local enterprise beans.
No support is provided for access to local enterprise beans from the application client container or the applet container."
If you use local interfaces for your session bean,
than your client must be local too. A local client is
a client that is collocated in the same JVM with the
session/entity that provides the local view and which
can be tightly coupled to the bean.My client is running in the same JVM as my EJB. The client is a servlet. The servlet is running in the same JVM as the EJB.
For what its worth, the error that I observed occurs during deployment. I haven't figured out why deployment is failing. -
When I am trying to upgrade my iOS version I am getting an error message saying " the iPad software update server could not be contacted", I also get an error message prior to that which says the certification of the server is invalid?
Temporarily disable any security software on the computer and try again.
-
O-R Relations in Sun J2EE SERVER/OC4j
The O-R Mappings in Sun J2EE SERVER using Deployer Tool
Not working ...
I badly need help....Raj -
You can use an old style (pfd 1 I think) of the ejb2.0 cmp/cmr with OC4J/Orion. The container will manage the relationships for you. I use it quite frequently in fact, though it is not advertised too heavily in the documentation. Once the ejb2.0 spec is incorporated fully into OC4J - you will have to make the odd change here-and-there.
For instance, create your abstract implementation classes -
Dept and Emp...
public abstract class DeptEJB implements EnityBean
//abstract getters/setters
public abstract void setDeptName(String deptName);
public abstract String getDeptName();
(etc)
// abstract 1-* relationship methods
public void addEmp(Emp emp) throws RemoteException,FinderException,NamingException,CreateException
this.getEmps().add(emp);
public abstract void setEmps(Collection emps);
public abstract Collection getEmps();
Create your abstract implementation class for Emp as well. While this relationship is certainly bi-directional (i.e. known to both) I am only doing a uni-directional relationship in this case.
After you have done this, you will need to put the relationship into the ejb-jar.xml file....You will need to create an ejb2.0 style descriptor.
For instance....
<?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>
<entity>
<description>Dept Entity Bean</description>
<display-name>Department</display-name>
<ejb-name>Dept</ejb-name>
<home>mypackage.DeptHome</home>
<remote>mypackage.Dept</remote>
<ejb-class>mypackage.impl.DeptEJB</ejb-class>
<persistence-type>Container</persistence-type>
<prim-key-class>java.lang.String</prim-key-class>
<abstract-schema-name>Dept</abstract-schema-name>
<cmp-version>2.X</cmp-version>
<reentrant>False</reentrant>
... Put all of your cmp fields as usual...
... In that same list (different than current ejb2.0)...
... place your cmr field ...
<cmp-field>
<field-name>emps</field-name>
</cmp-field>
</entity>
<!-- Also do you Emp entity descriptor -->
<entity>
<description>Emp Entity Bean</description>
<display-name>Employee</display-name>
<ejb-name>Empejb-name>
<home>mypackage.EmpHome</home>
<remote>mypackage.Emp</remote>
<ejb-class>mypackage.impl.EmpEJB</ejb-class>
<persistence-type>Container</persistence-type>
<prim-key-class>java.lang.String</prim-key-class>
<abstract-schema-name>Emp</abstract-schema-name>
<cmp-version>2.X</cmp-version>
<reentrant>False</reentrant>
... Put all of your cmp fields as usual...
<cmp-field>
<field-name>some_field</field-name>
</cmp-field>
... etc ...
</entity>
... The rest of your enterprise bean information
</enterprise-beans>
..... Next comes the relationships section ...
<<<<<NOTE - this differs somewhat from the final EJB2.0 spec
<<<<and you will need to make any required changes once it
<<<becomes final in OC4J
<relationships>
<ejb-relation>
<ejb-relation-name>dept-emps</ejb-relation-name>
<ejb-relationship-role>
<ejb-relationship-role-name>
dept-has-emps
</ejb-relationship-role-name>
<multiplicity>one</multiplicity>
<role-source>
<ejb-name>Dept</ejb-name>
</role-source>
<cmr-field>
<cmr-field-name>emps</cmr-field-name>
<cmr-field-type>java.util.Collection</cmr-field-type>
</cmr-field>
</ejb-relationship-role>
<ejb-relationship-role>
<ejb-relationship-role-name>
emps-belong-to-dept
</ejb-relationship-role-name>
<multiplicity>many</multiplicity>
<role-source>
<ejb-name>Emp</ejb-name>
</role-source>
</ejb-relationship-role>
</ejb-relation>
</relationships>
... Finish off your deployment descriptor as usual
When deployed successfully, OC4J will create your entity tables and your relationship tables (build off of the primary ids of you entity beans). You can add and remove employees from your dept.
Okay - that is a quick way to look at it from ejb2.0 (as it exists today in OC4J) container managed relationships. As stated, this will change somewhat when the spec is finalized in OC4J (they are quiet about when that will happen).
If you want to do container managed relationships in ejb1.1 - go to the Orion support site www.atlassian.com and go to this link:
http://kb.atlassian.com/content/orionsupport/articles/complex-or.html
Hope I have helped somewhat and haven't completely confused the issue!
Cheers
Ray
Thanx for the information...
I am Using J2EE RI Server ...
can i have an example Code like Dept-Emp with 1-* Relation Ship
i am trying the same...
Plz clarify...
* Shouls We Create the Relation ship fields and relation
in the DataBase itself
OR
The Container Will Manage for us
Cheers
Raj -
Run client execution problem when running Sun J2EE tutorial example
Hi,
I'm trying to run the Sun J2EE tutorial example, CartApp.
When come to run the client application I got the following error:
The command:
E:\Dev\src\J2EE_J2EE_tutorial\examples\ears>runclient -client CarApp.ear -name CartClient -textauth
The error:
Application threw an exception:java.io.IOException: CarApp.ear does not exist
The deployment complete without error.
I tried to the the APPCPATH to :
set APPCPATH=E:\Dev\src\J2EE_J2EE_tutorial\examples\ears\CartAppClient.jar
set APPCPATH=CartAppClient.jar
On both set, it gave the same error above.
Did someone known the problem I have ?
Thnakshi ,
I think u have given other disply name to your J2EE client ,
Anyway check disply name of J2EE client through deploytool.
u have to use that display name to access the j2ee client .
suppose ur j2ee client displyname is testclient, u can use:
runclient -client ConverterApp.ear -name testclient
hope this will help u,
babu. -
I am having problem with starting Sun J2EE Server 1.4. I had no problem with starting and stopping the server until today. I was not able to figure out what the problem is. I have tried reinstallation but did not work either. I also have reinstalled my J2SDK, but did not fix the problem. I am using J2SDK1.4.2_03 on Windows 2003 Server. Before the problem occured, I was working on a simple JMS applcation and trying to connect to J2EE server from a standalone JMS client at different machine. I am not sure what really caused the problem, but uninstalling it and reinstalling it does not change anything.
Here is my error message when I do start-domain domain1 at asadmin mode:
asadmin> start-domain domain1
Starting Domain domain1, please wait.
Log redirected to C:\Sun\AppServer\domains\domain1\logs\server.log.
abnormal subprocess termination: Detailed Message:Error: org/apache/commons/launcher/LaunchFilter
CLI156 Could not start the domain domain1.
I have tried to start it by using startserv.bat at domain1 directory and also the desktop shortcut Start Default Domain. Nothing works. I'do apprecited it if you can share any ideas or suggestions regarding this issue.
Thank you in advance.I made some changes to my enviroment variables and added jar files to the J2SDK <<J2SDK_HOME>>/jre/lib/ext folder in order to run the standalone JMS client.
Here is my classpath settings:
.;C:\Sun\AppServer\lib\j2ee.jar;
C:\Sun\AppServer\lib\appserv-admin.jar;
C:\Sun\AppServer\lib\appserv-rt.jar;
C:\Sun\AppServer\lib\appserv-rt.jar;
C:\Sun\AppServer\lib\appserv-ext.jar;
C:\Sun\AppServer\lib\install\applications\jmsra\imq.jar;
C:\Sun\AppServer\lib\install\applications\jmsra\imqadmin.jar;
C:\Sun\AppServer\lib\install\applications\jmsra\imqjmsra.jar;
C:\Sun\AppServer\lib\install\applications\jmsra\imqutil.jar;
C:\Sun\AppServer\imq\lib\fscontext.jar;C:\J2EE\tutorial\j2eetutorial14\examples\ejb\simplemessage\SimpleMSGAppClient.jar
I also have added appserv-rt.jar, appserv-rt.jar, appserv-ext.jar, imq.jar, imqadmin.jar, imqjmsra.jar, and imqutil.jar in the <<J2SDK_HOME>>/jre/lib/ext/ folder. I know they were redundant but just wanted to make sure. Can any of these be causing the problem?
Again, thank you and let me know if you need any other info. -
I would like to know which Sun Cert Java Course I should take ???
I am a very good C programmer that is trying to learn Java programming.
I know my way around all the various programming statements such as if-then-else, switch etc etc ...
I know the basics of an Applet and a Stand Alone application ...
I feel that I need some grounding on OO Technology ...
I would like to learn JAVA from where I am ...
I have also been reading up a lot on Java Programming lately ...
I am more of an Intermediate programmer ...
I have seen the Sun Certified Java courses web page and is quite confused by the many assortment of courses available ...
I would like to ask which Java Course is right for me at my level of programming experiences ???
Thanks in advance !!!
AndyMy limited understanding is that there are two main tests you can go for. The first is the Programmer certification, which tests your knowledge of the Java language itself, so you're asked questions about very specific things about the language syntax and such. I think these questions are stupid, because they serve no practical purpose, and some questions are more of a test of your memory.
Then you can take the Developer certification, which is focused more on evaulating and writing programs.
I haven't taken either, but there are some good resources for preparing for these tests.
http://www.javaprepare.com/quests/test.html -
Sun J2ee webservice tutorial doubt
Hi,
I am trying to understand how the JAX RPC static stub client is built in Sun Webservices tutorial
http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JAXRPC3.html
Here we have HelloIF and HelloImpl classes. Both these classes are in the
package helloservice.
package helloservice;
public interface HelloIF extends Remote {
}These have been built using
asant build, asant create-war, asant deploy-war commands.Now the client HelloClient.java is in package staticstub.
package staticstub;
import javax.xml.rpc.Stub;
public class HelloClient {
public static void main(String[] args) {
HelloIF hello = (HelloIF)stub;
}}I wanted to know how does HelloClient compile WITHOUT importing package helloservice in which HelloIF has been declared.
Isn't this against the basic java rules.
Or is there a smart way ANT does.
Can someone please explain or give me a plain javac command to compile the HelloClient.java
regards
VasimHello,
Could you post a stack trace?
Thanks,
Bruce
zbcong wrote:
>
hello
i want to deploy the jax-rpc sample that come with the sun's tutorial(hello) and
can works well in the tomcat into wls7,but the wls tell me that some files can't
be found,then i add enough jar files under the jwsdp to the lib directory of the
war package till the deployment success,but when i invoke it in the browser,the
browser tell me "no jax-rpc context available",why?and the same package even can't
be deployed in the jboss,the jboss always complain that the "class not found",but
i am sure the classes is included in the lib jar files,why?who can help me?
thank you -
Sun J2EE 1.4 RI generated .ear in WebSphere 5.1, not working
Just tried to install a .ear generated by Sun's J2EE 1.4 RI deploytool in WebSphere 5.1 server. Did not work, I got in the admin console
The EAR file could be corrupt and/or incomplete.
com.ibm.etools.archive.exception.DeploymentDescriptorLoadException: META-INF/application.xml
After a while I found this stacktrace information in captured stderr log
com.ibm.etools.archive.exception.DeploymentDescriptorLoadException: META-INF/application.xml
Stack trace of nested exception:
com.ibm.etools.j2ee.exception.WrappedRuntimeException: IWAE0099E An Exception occurred while parsing xml: Line #: 2 :Column #: 227
Stack trace of nested exception:
org.xml.sax.SAXParseException: Document root element "application", must match DOCTYPE root "null".
at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
at com.ibm.etools.j2ee.xml.bridge.GeneralXmlDocumentReader.parse(GeneralXmlDocumentReader.java:208)
at com.ibm.etools.j2ee.xml.bridge.GeneralXmlDocumentReader.parseDocument(GeneralXmlDocumentReader.java:231)
at com.ibm.etools.j2ee.xml.DeploymentDescriptorImportExport.importFrom(DeploymentDescriptorImportExport.java:186)
at com.ibm.etools.j2ee.xml.DeploymentDescriptorImportExport.importFrom(DeploymentDescriptorImportExport.java:177)
at com.ibm.etools.j2ee.xml.DeploymentDescriptorImportExport.load(DeploymentDescriptorImportExport.java:220)
at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doLoad(XMLResourceImpl.java:135)
When I look at the application.xml from my .ear, it looks fine (and XMLSpy can validate against schema)
<?xml version="1.0" encoding="UTF-8"?>
<application xmlns="http://java.sun.com/xml/ns/j2ee" version="1.4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/application_1_4.xsd">
<description>Application description</description>
<display-name>WuergServiceApp</display-name>
<module>
<ejb>ejb-jar-ic.jar</ejb>
</module>
</application>
So, I guess WebSphere is NOT supporting J2EE 1.4 at this time, is it? Found in the samples section comment "WebSphere supports Web Services for J2EE (JSR 109) which builds on a client-programming model on JAX-RPC". So JSR 109 seems to be a bit different from J2EE 1.4 (final)???
Anyone else trying to use J2EE 1.4 stuff in WebSphere?
MertenGrmpf, same problem with application.xml in BEA WebLogic Server 8.1SP2
<Error> <Deployer> <BEA-149027> <Unable to activate application, appsdirWuergServiceApp_ear, from source, d:\work\soap\WebLogic81SP2\server\samples\domains\examples\applications\WuergServiceApp.ear.
Reason: weblogic.management.DeploymentException: Error while loading descriptors: Error
processing file 'META-INF/application.xml'.
weblogic.xml.process.XMLProcessingException: XML document does not appear to contain a properly formed DOCTYPE header
Seems Bea supports J2EE 1.3, there application.xml has to start with
<!DOCTYPE application PUBLIC '-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN' 'http://java.sun.com/dtd/application_1_3.dtd'>
Merten -
I would like to know which Sun Cert JAVA Course should I take ???
I am a very good C programmer that is trying to learn Java programming.
I know my way around all the various programming statements such as if-then-else, switch etc etc ...
I know the basics of an Applet and a Stand Alone application ...
I feel that I need some grounding on OO Technology ...
I would like to learn JAVA from where I am ...
I have also been reading up a lot on Java Programming lately ...
I am more of an Intermediate programmer ...
I have seen the Sun Certified Java courses web page and is quite confused by the many assortment of courses available ...
I would like to ask which Java Course is right for me at my level of programming experiences ???
Thanks in advance !!!
Andywww.jcert.org has the information laid out a little better. I picked up Java without a formal course and I had about the same specs as you (although I had done a fair amount of c++ work). I would suggest the Java book by van der Linden (I know I'm not spelling the name right). I think it's called Just Java 2. Also Thinking in Java by Eckel has gotten good recommendations. For exam prep, the Exam Cram book by Brogden is highly recommended, but it won't teach you OO.
-
TOMCAT 4.0 & SUN J2EE Implementation 1.3.1
Did anybody have any success configuring those two together?????
It seems like no meter what I do Tomcat is only looking at its own Context.
I had no problem accessing EJB sitting on SUN's J2EE Impl from IBM WAS, by specifying different javax.naming.Context.PROVIDER_URL property
Properties prop = System.getProperties();
prop.setProperty(javax.naming.Context.PROVIDER_URL, "iiop://localhost:1050");
javax.naming.Context ctx = new javax.naming.InitialContext(prop);
Can't wait for your replies.
AlexHi oleg68, I want to ask you some question.
I deployed the cart application in the j2ee samples successfully and run it correctly on my localhost .In order to test its distributed character, I want to launch the application on another host.
So I just copy the client classes the jar file returned during deployment to another host(also installed the j2ee sdk and enviroment variable was set up correctly). it is equal to say I launch the client application on another host in the same way as on localhost.
but once I run the client applicaiton in that host to invoke the the EJB on my localhost, exception wiil be thrown as follows:
javax.naming.CommunicationException: Can't find SerialContextProvider
at com.sun.enterprise.naming.SerialContext.getProvider(SerialContext.jav
a:63)
at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:120
at javax.naming.InitialContext.lookup(InitialContext.java:350)
at CartClient.main(CartClient.java:20)
How can i dispose it,
Thanks -
Access a jsp which calls j2ee app of a appserver from a webserver
Hi,
I am trying to call a j2ee application which is running on a appserver like weblogic from a webserver.
Is it possible to run like this?i am executing the jsp in tomcat server which has its datasource in weblogic 7.the code is as follows...............
<%!Connection conn=null;Statement stmt=null;ResultSet rs=null;
public void closeConn(JspWriter out) {
try
rs.close();
stmt.close();
conn.close();
catch (Exception ex)
System.out.println("Exception while closing");
%>
<%@ page import="java.sql.*,javax.naming.*,java.util.*,weblogic.jdbc.common.*"%>
<%
try
System.out.println("get initial context");
weblogic.jdbc.common.internal.RmiDataSource ds=null;
Hashtable ht=new Hashtable();
ht.put(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory");
System.out.println("after factory setting");
ht.put(Context.PROVIDER_URL,"t3://10.11.32.120:4001,10.11.32.120:6001");
System.out.println("after provider url setting");
Context ctx=new InitialContext(ht);
System.out.println("after initial context set");
ds=(weblogic.jdbc.common.internal.RmiDataSource)ctx.lookup("MyDS");
System.out.println("after datasource set");
conn=ds.getConnection();
stmt=conn.createStatement();
rs=stmt.executeQuery("select * from purchaseorder");
while(rs.next()) {
out.println();
out.print("POID="+rs.getInt(1)+",");
out.print("ITEM="+rs.getString(2)+",");
out.print("QTY="+rs.getInt(3)+",");
out.print("DATE="+rs.getString(4));
catch (Exception ex)
System.out.println(ex.toString());
finally {
try {
closeConn(out);
catch(Exception ex) { System.out.println("Error while closing"); }
%>
...I am getting the following output.......
get initial context
after factory setting
after provider url setting
after initial context set
java.lang.ClassCastException: weblogic.jdbc.common.internal.RmiDataSource_WLStub
Exception while closing
so the problem is at the retrieving the datasource from the initial context which is looking in weblogic7.
i want to know whether this experiment would work.........i tried by using the
weblogic.jdbc.common.internal.RmiDataSource instead of javax.sql.Datasource which we normally use when we execute the same jsp in weblogic.I also put the weblogic.jar also in tomcat's classpath.
could anyone throw some light on this topic.Any help would be appreciated
Kiran chandra.kHi Kiran,
Looking at the code you sent and the error, it looks like you should be casting the ds object to a javax.sql.DataSource object not a weblogic.jdbc.common.internal.RmiDataSource object.
You may find some useful info at the following URL:
http://edocs.bea.com/wls/docs81/jdbc/rmidriver.html#1026007 -
BEA vs SUN architect certifications
Hi guys,
does anyone know whether the "BEA certified architect" (now rebranded to "Oracle SOA Architect Certified Expert") includes the "SUN Certified enterprise architect"?
A company requires the SUN certification, a candidate has the BEA one but says that Oracle ensures that the BEA one includes the SUN one, does someone know whether this statement is true?
thanks a lot.
MaxMassimo Ruocchio wrote:
Hi guys,
does anyone know whether the "BEA certified architect" (now rebranded to "Oracle SOA Architect Certified Expert") includes the "SUN Certified enterprise architect"?
A company requires the SUN certification, a candidate has the BEA one but says that Oracle ensures that the BEA one includes the SUN one, does someone know whether this statement is true?
thanks a lot.
MaxRefering to:
http://education.oracle.com/pls/web_prod-plq-dad/db_pages.getpage?page_id=326
http://education.oracle.com/pls/web_prod-plq-dad/db_pages.getpage?page_id=365
http://education.oracle.com/pls/web_prod-plq-dad/db_pages.getpage?page_id=318
http://education.oracle.com/pls/web_prod-plq-dad/db_pages.getpage?page_id=3
http://education.oracle.com/pls/web_prod-plq-dad/db_pages.getpage?page_id=140
http://education.oracle.com/pls/web_prod-plq-dad/db_pages.getpage?page_id=352
I believe these are currently separate, though there may be some content overlap.
Please drill down links yourself.
I am not authorative in this area; but I hope you find the links useful. -
Hi All,
I'm planning to do Sun Java Certified Architect certification. Currently I'm working as Java Developer.
Do i need to complete the SJCP (Sun Java Certified Programmer) then proceed to Architect ? Can i do the architect certification Directly? What is the eligibility ?
Can anybody please give me the web-sites where i can get Sample Questions, Tutorials, Articles, Document for Java Certification?
Thanks,
J.KathirHello J.Kathir
I just joined this forum and this is a my first post. The best site that i ever found is a certpaper dot com. You will find many practice test, study guide, new questions and answers and study tips. This site allow you to download pdf books and other exam related study material. This is not a dumps providing site but a site that guides you about the IT certifications. -
Error deploying Sun j2ee tutorial
I want to see some JSF examples and tried to deploy simple WAR files from SUN. These are downloadable via http://java.sun.com/j2ee/1.4/download.html#tutorial
An example war file I tried is guesNumber.war.
If I deploy this in Oracle Application Server 10g Release 2 (10.1.2.0.2) it doesn't work - computer says no. Error : Unknown assembly root-tag attribute: xmlnsTry changing this line in your web.xml <br>
<web-app xmlns="http://java.sun.com/xml/ns/j2ee" version="2.4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"><br>
to
<br>
<web-app><br>
Remove the xmlns bits in the tag
regards
Vasu
Maybe you are looking for
-
1. I recieved a new iphone 4 after a repair right as itunes 10.5 was released. 2. In order to activate my phone I needed to sync with itunes, so I decided to update itunes before I activated my phone so it would download the new features. 3a. During
-
Switching iPhone from PC to Mac, from one computer to another??
I just got my iPhone. Haven't activated it yet, b/c I also ordered a Macbook Pro. Should I wait until the Macbook comes to activate my iPhone? Or can I just activate it using my PC, and then switch it over to the Macbook? I know that you cant do that
-
Function calling in a oaf page
Hello, I created a function which calls an SIT. Now in my page, i created a link using personalization and has given the function name and in this way, the SIT page opens as soon as i click the function. What i want here is to open the SIT page in a
-
PLD - Item Warhouse table used in a sales order based on itemcode and WH.
I was wondering if anyone can help with a PLD relation. I have created a UDF on the item warehosue labelled 'BIN Location'. In my sales order template I have selected this table via the ALT functionality and selected the BIN Location field. In the re
-
Error while trying activate planning area
Hi APO Gurus, I am faced with a problem of not being able to activate a planning area although my live cache is operational. This is a fresh installation of APO and when I view the Model (000) and Active Version (000) I see the message at the bottom