EventService lookup from ejb project
hi
We want to use the EventService from with in a class which resides in an ejb project of our portal application.
We used the EventService from within the portal webapp project without problems. With
Object o = p_context.lookup( "java:comp/env/ejb/EventService" );
we could lookup the object and narrow it to the EventServiceHome interface. However this does not work within the ejb project.
We get the error message:
"javax.naming.NameNotFoundException: While trying to look up comp/env/ejb/EventService in /app/ejb/scp_helpers.jar#EJBTTHelper.; remaining name 'comp/env/ejb/EventService'"
We tried another name which we found in different depoyment descriptors: p13n_ejb.jar#EventService . No success.
What name do we have to use or shortly: what are we doing wrong? How could we get the EventService SessionBean from within an ejb project?
look up the resource-ref in web.xml (and weblogic.xml). Add the same in ejb-jar.xml (and weblogic-ejb-jar.xml). The entries are not exactly the same, but the concept is the same.
Best regards...
hi
We want to use the EventService from with in a class
which resides in an ejb project of our portal
application.
We used the EventService from within the portal
webapp project without problems. With
Object o = p_context.lookup(
"java:comp/env/ejb/EventService" );
we could lookup the object and narrow it to the
EventServiceHome interface. However this does not
work within the ejb project.
We get the error message:
"javax.naming.NameNotFoundException: While trying to
look up comp/env/ejb/EventService in
/app/ejb/scp_helpers.jar#EJBTTHelper.; remaining name
'comp/env/ejb/EventService'"
We tried another name which we found in different
depoyment descriptors: p13n_ejb.jar#EventService . No
success.
What name do we have to use or shortly: what are we
doing wrong? How could we get the EventService
SessionBean from within an ejb project?
Similar Messages
-
Duplicate class definition error while invoking EJB from ADF project
Hi,
I am using Jdeveloper TP3 and facing the following problem.
I have built an EJB project and am ran them successfully in the embedded OC4J via a standalone java program.
Now I created another project with ADF capabilities and when I tried to ping the EJB i get the following exception
The application named, current-workspace-app, could not start due to an error.
duplicate class definition: javax/faces/context/FacesContextFactory Invalid class: javax.faces.context.FacesContextFactory Loader
This is happenning due to class conflicts between javaee.jar and trinidad-impl.jar/adf-richclient-impl.jar.
Is there any way of bypassing this class loader issue?Hi,
actually I didn' try the JNDI lookup but used resource injection instead
In a JSF managed bean I use
@EJB Ejb30SessionFacadeLocal myLocalInterface;
public SortableModel getTableModel() {
List rows = new ArrayList<Employees>();
rows = myLocalInterface.queryEmployeesFindAll();
this.tableModel = new SortableModel(rows);
return tableModel;
Its a EJB 3.0 session bean that accesses a Local interface. However, if the remote is on the same server then I would think that using @EJB Ejb30SessionFacadeRemote myRemoteInterface; does similar
Frank -
EJB lookup from another EJB server
Hi people,
I have two application servers on two different computers. One
of them contains an EJB, which I need to access from another EJB
server. I know that I can achieve this using RMI, but will then
security and transaction contexts be propagated to the called
EJB?
Sincerely,
Sergei Batiuk.Here is the solution posted on another forum:
[email protected] Dec 8, 6:03 am show options
Newsgroups: ibm.software.websphere.studio
From: [email protected]
Date: 8 Dec 2004 06:03:04 -0800
Local: Wed, Dec 8 2004 6:03 am
Subject: Re: EJB lookup on from one server to another does not work
Eric,
I dealt with this same problem trying to run 2 local servers (websphere
test servers), using 2 separate WSAD 5.1.2 workspaces. Running on 1
server I have an application that contains an EJB, and running on the
other server is an application that uses an access bean to make a
remote call to my EJB, running on my other server. I too repeately
received the "NameNotFoundException" when trying to lookup my EJB home
reference.
What you have to do to get around this is to modify the server
configuration of the application that contains the EJB that you are
attempting to call remotely. You must open the the server.wsi file for
the server that is running the EJB and go to the "Configuration" tab.
You must check the "Enable administrative console". Once this is
complete, start your server. When it is started, right click on the
server, and select "run administrative console". In the admin console,
select
servers -> application servers -> <your server> -> end points ->
bootstrap address. For "host" you must change "localhost" to either
your ip address or computer name (ive only tried my ip, but your
computer name should work too). When building your properties to get
the initial context, make sure you use
"env.put(Context.PROVIDER_URL, "corbaloc:iiop:<the ip or computer name
listed as the bootstrap host of server running ejb>:<the port listed as
the bootstrap port of server running ejb, which is 2809 in your case>
Restart your server and things should work. -
How can Transformation control be used from an EJB Project?
I want to perform some data transformation directly from within the EJBs. Can Transformation
control be used from an EJB Project? How?William, thanks for the reply.
I bought this drive module from a private party and was surprised to find out what it was. At first I thought it was just Apple's way of protecting the drive during shipping.
I own it and will probably have an hard time returning it. It was advertised as a 750GB Seagate SATA ES hard drive. The price was very reasonable, especially if I was buying it as a Drive Module. So if I can sell it great, if not I want to use the drive.
How can I tell if this is a Xserve RAID module or Drive Module? The box just says Apple Drive Module no mention of RAID. The Apple model # is MA504G/A, and it say Apple Drive Module 750GB SATA (Intel). On the hard drive itself it says Seagate Barracuda ES 750Gbytes.
If this is just the Drive Module and I can use it in my Mac Pro, does it just unplug or unscrew out of the housing it's in and plug into the Mac Pro like a normal drive? And then can it be used like a normal drive to set up a RAID in the Mac Pro with a duplicate bare drive? It's sealed and I don't want to open it until I know I can use it.
Sorry for all the questions but I know enough to be dangerous and this this has me stumped. -
How to lookup an EJB from JSP on a Remote Server in JES2005Q4
Hi,
I am having two different domain (domain1,domain2) respectvely. My ABC.ear j2eee application is deployed on domain2 and its iiop port is 33703.In domain1 i have xyz.war (web application) and it's IIOP port is 3700 .In xyz.war i am having CallEJB.jsp file.In this Jsp file i want to lookup an EJB Service called PaymentEJB(JNDI Name is ejb/PaymentEJB).
The code is below
InitialContext context=new InitialContext();
Object objRef=context.lookup("corbaname:iiop:andaman:33703#ejb/PaymentEJB");
I am getting the following error.
[#|2005-12-14T16:42:03.422+0530|SEVERE|sun-appserver-pe8.1_02|javax.enterprise.resource.corba._DEFAULT_.rpc.transport|_ThreadID=11;|"IOP00410216: (COMM_FAILURE) Unable to create IIOP listener on the specified host/port: all interfaces/3700"
org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 216 completed: No
at com.sun.corba.ee.impl.logging.ORBUtilSystemException.createListenerFailed(ORBUtilSystemException.java:2661)
My doubt is
1.While starting domain1 and domain2 iiop listeners are started on the port 3700 and 33703.in that case why EJB lookup tries to create listener on one more time.
2.I am looking the 33703 port only.but it tries to create port on 3700 why?
3.It was working till JES2005Q1.Is there any patch i need to install? or i need to change anything in my code.
I am frustrated with this error for past one week.I will be happy if some body will give me the peace of mind(thru some solution).Hi,
I am having two different domain (domain1,domain2) respectvely. My ABC.ear j2eee application is deployed on domain2 and its iiop port is 33703.In domain1 i have xyz.war (web application) and it's IIOP port is 3700 .In xyz.war i am having CallEJB.jsp file.In this Jsp file i want to lookup an EJB Service called PaymentEJB(JNDI Name is ejb/PaymentEJB).
The code is below
InitialContext context=new InitialContext();
Object objRef=context.lookup("corbaname:iiop:andaman:33703#ejb/PaymentEJB");
I am getting the following error.
[#|2005-12-14T16:42:03.422+0530|SEVERE|sun-appserver-pe8.1_02|javax.enterprise.resource.corba._DEFAULT_.rpc.transport|_ThreadID=11;|"IOP00410216: (COMM_FAILURE) Unable to create IIOP listener on the specified host/port: all interfaces/3700"
org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 216 completed: No
at com.sun.corba.ee.impl.logging.ORBUtilSystemException.createListenerFailed(ORBUtilSystemException.java:2661)
My doubt is
1.While starting domain1 and domain2 iiop listeners are started on the port 3700 and 33703.in that case why EJB lookup tries to create listener on one more time.
2.I am looking the 33703 port only.but it tries to create port on 3700 why?
3.It was working till JES2005Q1.Is there any patch i need to install? or i need to change anything in my code.
I am frustrated with this error for past one week.I will be happy if some body will give me the peace of mind(thru some solution). -
EJB(EAR file) lookup from separate WAR file
Hi
I have 2 applications (EAR and WAR) deployed in an OC4J instance using Oracle 10g. All my EJB components are in my EAR file and all my front-end/servlet component are in the WAR file. My lookup in the servlet fails, like:
05/01/21 13:47:05 javax.naming.NameNotFoundException: SessionEJB not found
05/01/21 13:47:05 at com.evermind.server.rmi.RMIContext.lookup(RMIContext.java:149)
05/01/21 13:47:05 at com.evermind.server.ApplicationContext.lookup(ApplicationContext.java:248)
05/01/21 13:47:05 at com.evermind.server.ApplicationContext.lookup(ApplicationContext.java:119)
05/01/21 13:47:05 at javax.naming.InitialContext.lookup(InitialContext.java:347)
05/01/21 13:47:05 at efdw.eap.servlet.SessionEJBAction.execute(SessionEJBAction.java:48)
05/01/21 13:47:05 at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:484)
05/01/21 13:47:05 at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:274)
05/01/21 13:47:05 at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
05/01/21 13:47:05 at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
05/01/21 13:47:05 at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
05/01/21 13:47:05 at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
05/01/21 13:47:05 at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:765)
05/01/21 13:47:05 at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
05/01/21 13:47:05 at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790)
05/01/21 13:47:05 at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:208)
05/01/21 13:47:05 at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:125)
05/01/21 13:47:05 at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)
05/01/21 13:47:05 at java.lang.Thread.run(Thread.java:534)
EJB reference in web.xml looks like:
<ejb-ref>
<ejb-ref-name>SessionEJB</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>com.app.bean.SessionEJBHome</home>
<remote>com.app.bean.SessionEJB</remote>
</ejb-ref>
I've added the "parent" attribute in server.xml, something like:
<application name="myapp" path="../applications/myapp.ear" auto-start="true" />
<application name="myweb" path="../applications/myweb.ear" auto-start="true" parent="myapp" />
but the sever.xml file gets reset and there is no parent attribute in the file
lookup in my servlet:
Context ctx = new InitialContext();
Object objref = ctx.lookup("SessionEJB");
sessionEJBHome = (SessionEJBHome)PortableRemoteObject.narrow(objref, SessionEJBHome.class);
beanRemote = sessionEJBHome.create();
I also tried using the jndi.properties file and by specifying context attributes (PROVIDER_URL,INITIAL_CONTEXT_FACTORY,..) nothing worked.
Is there a way I can configure the jndi tree like in weblogic? How do I need to configure the lookup?Hi Naga,
You have to lookup the ejb as follows:
Object objref = ctx.lookup("java:comp/env/ejb/SessionEJB");
location tag in orion-ejb-jar.xml for the EJB determines where the JNDI-name to which this bean will be bound documented in EJB Guide at http://download-west.oracle.com/docs/cd/B14099_01/web.1012/b15505/dtdxml001.htm#sthref1130
<ejb-ref-mapping ... > in orion-web.xml :
This element creates a mapping between an EJB reference, defined in an <ejb-ref> element, and a JNDI location when deploying.
The <ejb-ref> element can appear within the <web-app> element of orion-web.xml or web.xml and is used to declare a reference to an EJB.
-Debu -
Help needed in EJB - to call AS from EJB a Session Bean
Hi All ,
I have been strictly told not to use Web Services as all the applications are on the same server
actually I have to make an EJB invocation to an Application Service from the CAF layer from a Session Bean of another EJB Project(Not a CAF Service).
the CAF layer has 5 parts metadata , permissions , dictionary , ear and ejbmodule.
I added the ejbModule to the Build Path of the calling EJB Session Bean. And so I was able to access the operations of the Application Service which in turn accesses a BAPI(The Appl Service operation returns a String).
But while executing I got the exception java.lang.RuntimeException: java.lang.NoClassDefFoundError
My method :
Normally from a Dynamic Web Project acting as a client to an EJB Session bean, I was able to get access to EJB Local Interface by using
private ConverterLocal converterBean = null;
public void jspInit() {
try {
InitialContext ic = new InitialContext();
converterBean = (ConverterLocal)
ic.lookup("java:comp/env/Converter");
} catch (Exception ex) {
System.out.println("Couldn't create converter bean."+
ex.getMessage());
BigDecimal dollarAmount = converterBean.euroToDollar(value);
So I created a JNDI field in ejb-j2ee-engine.xml
enterprise-beans>
<enterprise-bean>
<ejb-name>com.sap*******.bapi_company_getlist.BAPI_COMPANY_GETLIST</ejb-name>
<jndi-name>COMPANY</jndi-name>
</enterprise-bean>
</enterprise-beans>
And from my Session Bean , I tried to access it using the code in already existing Bean which was working fine
BAPI_COMPANY_GETLISTBeanImpl bean = new BAPI_COMPANY_GETLISTBeanImpl();
try {
InitialContext ctx = new InitialContext();
bean = (BAPI_COMPANY_GETLISTBeanImpl)ctx.lookup("COMPANY");
} catch (NamingException e) {
System.out.println("Converter Bean can't be created");
String send = bean.returnDetails();
And I tried to print the String , but I got the above error
I have a doubt :
1) How do I specify the JNDI name ie in the ejb-j2ee-engine.xml file , what should I add as the name of the ejb
is this sufficient , or are there more steps ??Hi Ekaterina,
I have the document to access my Bean from another Bean.
I could access my Bean from a standalone Java class with this code
Properties props = new Properties();
props.put(Context.INITIAL_CONTEXT_FACTORY,"com.sap.engine.services.jndi.InitialContextFactoryImpl");
props.put(Context.PROVIDER_URL,"hostname:port");
try{
Context ctx = new InitialContext(props);
Object o = ctx.lookup("sap.com/TestEAR/REMOTE/TestBean/com.@#$.TestRemote");
TestRemote testRem = (TestRemote)javax.rmi.PortableRemoteObject.narrow(o, TestRemote.class);
String msg = testRem.getMessage();
System.out.println(msg);
And in this document there is a way shown to access a bean from another Bean.
http://help.sap.com/saphelp_nw04/helpdata/en/13/c8633e0084e946e10000000a114084/frameset.htm
If your client is another enterprise bean, declare the EJB reference in the ejb-jar.xml.
-For more information, see Declaring EJB References.
But the problem is that in EJB 3.0 , I can't see the ejb-jar.xml file .
So how should I have a Bean as a client to another Bean, I am not that familiar with Annotations. -
ClassCastException calling EJB from EJB (diff EARs) Urgent please help !!
Hi,
I�m trying to call a Remote EJB ( in jdev BBEAN.prj ) from another EJB (in jdev ABEAN.prj) located in a different EAR.
In JDEVELOPER (oc4j 9.0.3) I also considered BBEAN as a libreary which is included in the ABEAN project.
So that the ABEAN JAR contains the class definition for the Home and remote interface.
From the ABEAN bean I call this code:
DO ()
private static Context getInitialContext() throws NamingException
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY, "com.evermind.server.rmi.RMIInitialContextFactory");
env.put(Context.SECURITY_PRINCIPAL, "admin");
env.put(Context.SECURITY_CREDENTIALS, "manager");
env.put(Context.PROVIDER_URL, "ormi://GSARNO-1/BBean");
return new InitialContext(env);
BBeanHome BBeanHome = (BBeanHome)PortableRemoteObject.narrow(context.lookup("BBean"), BBeanHome.class);
BBean bBean;
������������..
After having deployed both projects I then run a client (Calling the Do function).
Doing so I keep receiving the following error when calling narrow.
java.lang.ClassCastException
java.lang.Object com.sun.corba.se.internal.javax.rmi.PortableRemoteObject.narrow(java.lang.Object, java.lang.Class)
PortableRemoteObject.java:296
java.lang.Object javax.rmi.PortableRemoteObject.narrow(java.lang.Object, java.lang.Class)
PortableRemoteObject.java:137
java.lang.String mypackage1.impl.MySessionEJBBean.Do()
MySessionEJBBean.java:39
java.lang.String MySessionEJB_StatelessSessionBeanWrapper6.Do()
MySessionEJB_StatelessSessionBeanWrapper6.java:85
java.lang.Object java.lang.reflect.Method.invoke(java.lang.Object, java.lang.Object[])
native code
void com.evermind.server.rmi.RMICallHandler.run(java.lang.Thread)
RMICallHandler.java:119
void com.evermind.server.rmi.RMICallHandler.run()
RMICallHandler.java:48
void EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run()
PooledExecutor.java:803
void java.lang.Thread.run()
Thread.java:484
Can anyone help ?
What should I do to call remote e/o local interfaces located on different EARs ?
I�m using OC4J 9.0.3Hi Giuseppe,
If both EAR files are in the same OC4J instance you do not have to use RMIInitialContextFactory to invoke the EJB. You have to do the following:
In OC4J
1) Make the BBEAN as the parent for ABEAN application defined in the server.xml as follows:
application name="ABEAN" path="../applications/abean.ear" parent="BBEAN" auto-start="true" />
2)
You can define ejb-ref or ejb-local-ref in the deployment descriptor of your application
3) You can use the default InitialContext to lookup your EJB as if both EJBs are in the same application
regards
Debu -
How can I create a new EJB project ?
Hi,
I downloaded the trial version and I don't know how to create an EJB project ?
When I create a new project, I've only the web template to choose.
Where can I find informations about that ?
Thanks.
jackHi Jack,
This version of the Creator allows you to build applications which access existing EJB's, but doesn't create new EJB's from scratch. We are looking into that for future releases.
If you want to access an existing EJB, please see the tutorials:
http://devservices.sun.com/premium/jscreator/standard/learning/tutorials/sessionEJBcomps.pdf
I believe the Sun Java Studio Standard product can help you create EJB's today, if that's what you need:
http://developers.sun.com/prodtech/javatools/jsstandard/index.html
hth,
Val -
JCo 3.0 - RFC call from EJB with SSO
Hello,
I am trying to call abap using JCo 3.0 from EJB (NW CE 1.0). I have configured destination on server with authentication method to use SAP Logon tickets. But when I call my EJB method that looks like this:
JCoDestination dest=JCoDestinationManager.getDestination("RFCCallTest");
JCoRepository repo=dest.getRepository();
JCoFunction f= repo.getFunction("ZMG_RET_NAME");
JCoParameterList in=f.getImportParameterList();
in.setValue(0, "param1");
f.execute(dest);
I get an exception when executing the first line of code:
Message: Exception occurred during lookup of RFC Destination RFCCallTest: No SAP logon ticket found
Category: /System/Security
Location:com.sap.security.core.server.destinations.provider.DestinationsProviderFrame.getDestinationProperties()
When I change the destination authentication method to Technical user it works well.
SSo between the servers works.
This scenarion also works when I use older JCo implementation (2.x)
BR
ViktorHi Bill,
I too faced the same problem for quite some time on SP9. I thought it was the adapter problem that persisted ...but it was not !!
After importing the RFC structure into XI, if the name of the imported RFC program is renamed/changed on R/3 side, then you will get the same error "lookup of binding via CPA-cache failed for AdapterType RFC, AdapterN."
So make sure that RFC program name on the R/3 side was not changed/renamed after you have imported the RFC structure into XI.
If the RFC program name had changed, make sure you reimport the RFC structure to avoid this problem.
Regards,
Sridhar -
How to call external jar files in EJB project for CE
Hi,
I would be thankful if someone could help me with this -
I need to call the external jar files into my EJB project - Here is what I have done and am getting runtime exception as -
java.lang.RuntimeException: java.lang.NoClassDefFoundError: com/glance/pdf/pt/PTDoc
1. Created a EJB project" HelloWorld " using Java perspective in NWDS 7.1 called with client as HelloWorldClient and EAR project as HelloWorldEAR.
2. Am working on HelloWorld project (1st one).
3. In my code I am instantiating a class which is a class in one of the external jar file that I need to refer in my project.
4. I have set the Java Build path but it works only for the compile time and fails during runtime.
5. Have read I need to create external library DC and refer in my project "HelloWorld".
Can anyone help me with exact steps what needs to be done - during creation of external library project and then for my "HelloWorld" EJB project. How would I be able to reference or set the external library project in my EJB project?
Looking forward to hear from experts.
Thanks,
Shiv
Edited by: Shiv Khullar on Aug 30, 2010 9:39 PMHi Edson,
I tried it , but it still gives me runtime exception.
javax.ejb.EJBException: nested exception is: java.lang.RuntimeException: java.lang.NoClassDefFoundError: com/glance/pdf/pt/PTDoc
java.lang.RuntimeException: java.lang.NoClassDefFoundError: com/glance/pdf/pt/PTDoc
Steps I performed are -
1. Created a library project and created 2 Public parts "Compilation" and "Assembly"
2. Build the library project.
Now in my EJB project using Project Explorer - set the classpath and added both compilation jar and assembly jar files.
This is how the classpath entries for external library looks like -
<classpathentry kind="lib" path="/LocalDevelopmentLocalDevelopmentexternallibrarypdftoolsforwatermarkingdemo.sap.com/gen/default/public/WatermarkAssembly/lib/java/demo.sap.comexternallibrarypdftoolsforwatermarking~WatermarkAssembly.jar"/>
<classpathentry kind="lib" path="/LocalDevelopmentLocalDevelopmentexternallibrarypdftoolsforwatermarkingdemo.sap.com/gen/default/public/WatermarkCompilation/lib/java/demo.sap.comexternallibrarypdftoolsforwatermarking~WatermarkCompilation.jar"/>
I have also added the jar files I used in my external library project as "User Library" from Java Build Path . I dont do it , then the code fails during compilation itself.
Regards,
Shiv -
Adapter module:: JAR file in the build path of EJB project
Hi Experts,
I have created one adapter module, for this I have created one EJB project and also associated one EAR project to that.
I have completed my coding and changes in the xml files.
I have followed this -
http://www.sdn.sap.com/irj/scn/index;jsessionid=(J2EE3417500)ID1494558950DB01504425675464955468End?rid=/library/uuid/c0b39e65-981e-2b10-1c9c-fc3f8e6747fa&overridelayout=true
while creating the module.
but after finishing this , I can not see the ejb.jar file corresponding to the ejb project, I can see the class file generated in the build path.
but I can not see the ejb.jar in the EJB project after build.
When I checked the EAR project I found under Deployment descriptor there is a folder called module and there is a jar file named as -
EJB<my ejb project name>.jar
when I am about to deploy this EAR in the server it is showing me to choose the file from EAR project and this EAR project contain the EJB Project .
Request you to please let me know is everything ok with my project ? or please let me know how can I see the ejb.jar file corresponding to the ejb project below the build path.
Thanks
VinnyHi Experts,
I have created one adapter module, for this I have created one EJB project and also associated one EAR project to that.
I have completed my coding and changes in the xml files.
I have followed this -
http://www.sdn.sap.com/irj/scn/index;jsessionid=(J2EE3417500)ID1494558950DB01504425675464955468End?rid=/library/uuid/c0b39e65-981e-2b10-1c9c-fc3f8e6747fa&overridelayout=true
while creating the module.
but after finishing this , I can not see the ejb.jar file corresponding to the ejb project, I can see the class file generated in the build path.
but I can not see the ejb.jar in the EJB project after build.
When I checked the EAR project I found under Deployment descriptor there is a folder called module and there is a jar file named as -
EJB<my ejb project name>.jar
when I am about to deploy this EAR in the server it is showing me to choose the file from EAR project and this EAR project contain the EJB Project .
Request you to please let me know is everything ok with my project ? or please let me know how can I see the ejb.jar file corresponding to the ejb project below the build path.
Thanks
Vinny -
Hi,
i am doin java client proxy in XI.i ve imported the beans generated from XI into an EJB project in NDS and have changed the ejb-jar.xml accordingly.However the "BUILD EJB ARCHIVE" option is not enabled.Can anyone help?
Regards,
DivyaHI
GOOD
GO THROUGH THESE LINKS
http://help.sap.com/saphelp_nw04/helpdata/en/86/58cd3b11571962e10000000a11402f/content.htm
http://www.sapgenie.com/xi/
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f272165e-0401-0010-b4a1-e7eb8903501d
THANKS
MRUTYUN -
EJB project IDE build dos not include properties files
We have property files also which we want included as part of the build process
for EJB projects but if we use the IDE build it does not include them. We have
to therefore export the IDE build and customize it to include *.properties like
this
<zip basedir="${dest.path}" zipfile="${ejb.outputJar}" encoding="UTF8"> <!-- JARs
filenames are encoded UTF8 --> <zipfileset dir="${project.local.directory}" includes="*.properties"
/> </zip>
which causes a problem for us because the exported build file is specific to a
user's local PC and cannot be used in a team environment.
How can we have the IDE build include all the files within an EJB project i.e.
include properties files also.Hey Jamie,
Currently there is no support to include other .properties files into
the internal build. There's a build.properties that you get as part of
an EJB project which you could place your values into and use that as
your template for your team based development and check that into your
source control.
If you'd really like to get gross and hack Workshop a little bit you
could modify the default EJB project template to use your .properties
file for every EJB project you create. This would then splat a copy of
your .properties file into the root of the EJB project.
To do that you'd go to {your BEAHOME}\workshop\templates and crack open
the ejb-project.zip template zip file and merge your settings into the
existing build.properties file. This has the same
effect as replacing the .properties file after you've created your
project only it keeps you from having to perform that step each time.
The downside of this is that each person on your team would then have to
update that template zip file in their workshop installation. (I'd make
sure to backup the original template file before performing this
activity so you can always go back to the original template).
Hope this helps,
-Michael
Jamie wrote:
We have property files also which we want included as part of the build process
for EJB projects but if we use the IDE build it does not include them. We have
to therefore export the IDE build and customize it to include *.properties like
this
<zip basedir="${dest.path}" zipfile="${ejb.outputJar}" encoding="UTF8"> <!-- JARs
filenames are encoded UTF8 --> <zipfileset dir="${project.local.directory}" includes="*.properties"
/> </zip>
which causes a problem for us because the exported build file is specific to a
user's local PC and cannot be used in a team environment.
How can we have the IDE build include all the files within an EJB project i.e.
include properties files also. -
Configuring Log4j for a EJB Project.
Hi,
I have a weblogic EJB project as a Ear file. The project has no web components (so war file). I want to know which is the ideal way to initialize log4j in this situation.
I can use listener class thro' weblogic-application.xml. But there is no neat way to passing the log4j.xml thro' parameter from weblogic-applicaiton.xml file.
If we are using servlet we could use init-parm to passing xml file. I don't want to hard code the xml file location in the listener class.
What is the best practice to initialize log4j for a EJB project?
Thanks in advance.
AnandDan,
I had a similar problem because I wanted to define my own log4j config regardless of what other portal apps were deployed in the BEA domain or what log4j was the default for the domain. This is what I do:
1) Put your log4j config file in the WEB-INF classes dir (or I guess it could be in some other place that the CLASSPATH knows of)
2) Create a servlet that looks like:
import javax.servlet.*;
import javax.servlet.http.*;
import org.apache.log4j.xml.*;
public class Log4jInitServlet extends HttpServlet {
private static final long serialVersionUID = 23456;
public void init(ServletConfig config) throws ServletException {
super.init(config);
DOMConfigurator.configure(Thread.currentThread().getContextClassLoader().getResource("myLog4jConfigFile.xml"));
public void doGet(HttpServletRequest req, HttpServletResponse resp) {
3) Add the servlet definition in the web.xml and add a <load-on-startup>1</load-on-startup>
That should do it.
- Peter
Maybe you are looking for
-
Purchase order output determination thru User exit
Hi, We are trying to find a way to determine the output for PO while creation (me21n) or modification (me22n). We do not want to maintain output condition records for each fax/print/email etc..cases. Can we do below thru a user exit or any other meth
-
Target node creation on condition
Hi I have a requirement where i have to create a target node based on a requiremnt. the source is The target is Line Tar a1
-
I'm having trouble opening pdf files for weeks now. Help please.
I'm having trouble opening pdf files for weeks now. Can someone help me? It
-
Dear Sir ! I install WIM 4.3, but i login Web Manager, there is problem in the below file
-
Trying to duplicate this effect
Of course the guy that did it won't share his way of doing it, says there is a plug-in but it's $250. I'm wondering if anyone here knows how this effect can be made or knowing of the plug-in (Exposure 2) can be gotten for free. Here's the image that