Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Error on using weblogic.appc for EJB3`

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Folks

I am trying to convert an EJB2.1 bean to a EJB3.0 Bean which can be accessed from EJB2.1 clients.

I am getting the following StackTrace on running Weblogic.appc using Weblogic 10



[java] <Jan 3, 2008 11:36:58 AM IST> <Info> <J2EE> <BEA-160186> <Compiling EAR module 'admin-ejb.jar'>
[java] In EJB EJB3 both the remote home and remote component interface must be specified. Currently, only one of them is specified.
[java] at weblogic.ejb.container.deployer.ClientDrivenBeanInfoImpl.checkClientViews(ClientDrivenBeanInfoImpl.java:1483)
[java] at weblogic.ejb.container.deployer.ClientDrivenBeanInfoImpl.<init>(ClientDrivenBeanInfoImpl.java:149)
[java] at weblogic.ejb.container.deployer.SessionBeanInfoImpl.<init>(SessionBeanInfoImpl.java:106)
[java] at weblogic.ejb.container.deployer.Ejb3SessionBeanInfoImpl.<init>(Ejb3SessionBeanInfoImpl.java:94)
[java] at weblogic.ejb.container.deployer.BeanInfoImpl.createBeanInfoImpl(BeanInfoImpl.java:664)
[java] at weblogic.ejb.container.deployer.MBeanDeploymentInfoImpl.initializeBeanInfos(MBeanDeploymentInfoImpl.java:499)
[java] at weblogic.ejb.container.deployer.MBeanDeploymentInfoImpl.<init>(MBeanDeploymentInfoImpl.java:224)
[java] at weblogic.ejb.container.ejbc.EJBCompiler.getStandAloneDeploymentInfo(EJBCompiler.java:1412)
[java] at weblogic.ejb.container.ejbc.EJBCompiler.setupEJB(EJBCompiler.java:169)
[java] at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:511)
[java] at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:471)
[java] at weblogic.application.compiler.AppcUtils.compileEJB(AppcUtils.java:298)
[java] at weblogic.application.compiler.EJBModule.compile(EJBModule.java:83)
[java] at weblogic.application.compiler.flow.CompileModuleFlow.compileModules(CompileModuleFlow.java:103)
[java] at weblogic.application.compiler.flow.CompileModuleFlow.compile(CompileModuleFlow.java:58)
[java] at weblogic.application.compiler.FlowDriver$FlowStateChange.next(FlowDriver.java:69)
[java] at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
[java] at weblogic.application.compiler.FlowDriver.nextState(FlowDriver.java:36)
[java] at weblogic.application.compiler.FlowDriver.run(FlowDriver.java:26)
[java] at weblogic.application.compiler.EARCompiler.compile(EARCompiler.java:46)
[java] at weblogic.application.compiler.flow.AppCompilerFlow.compileInput(AppCompilerFlow.java:118)
[java] at weblogic.application.compiler.flow.AppCompilerFlow.compile(AppCompilerFlow.java:43)
[java] at weblogic.application.compiler.FlowDriver$FlowStateChange.next(FlowDriver.java:69)
[java] at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
[java] at weblogic.application.compiler.FlowDriver.nextState(FlowDriver.java:36)
[java] at weblogic.application.compiler.FlowDriver.run(FlowDriver.java:26)
[java] at weblogic.application.compiler.Appc.runBody(Appc.java:172)
[java] at weblogic.utils.compiler.Tool.run(Tool.java:158)
[java] at weblogic.utils.compiler.Tool.run(Tool.java:115)
[java] at weblogic.application.compiler.Appc.main(Appc.java:183)
[java] at weblogic.appc.main(appc.java:14)
[java] In EJB EJB3, both the remote home and remote component interface must be specified. Currently, only one of them is specified.



Here is the code:






Can somebody please tell me what is going on?


Markiv
-----------------------------------------------------------------------------------------
package EJB3Code;
import java.rmi.RemoteException;
import javax.ejb.*;
import javax.ejb.EJBHome;

public interface EJB3Home extends EJBHome
{
EJB3Remote create() throws javax.ejb.CreateException, RemoteException;
}


---------------------------------------------------------------------------------------
package EJB3Code;


import java.util.ArrayList;
import java.util.Collection;
import java.lang.annotation.*;
import javax.annotation.PreDestroy;
import javax.ejb.*;

import javax.ejb.Stateless;
import javax.ejb.Init;
import javax.ejb.SessionContext;
import javax.ejb.CreateException;
import javax.ejb.Remove;
import javax.ejb.RemoteHome;
import org.apache.log4j.Category;

@Remote({EJB3Remote.class})
@Stateless(name="EJB3")
@RemoteHome(EJB3Home.class)
public class EJB3EJB implements EJB3Remote
{

private SessionContext ctx;
private static Category log;

@Init
public void ejbCreate() throws CreateException
{

}

public void EJB3EJB() {
log = Log4JCategoryFactory.getCategoryInstanceFor(EJB3EJB.class.getName());
}


@PreDestroy
public void ejbRemove()
{

}

@PostActivate
public void ejbActivate()
{

}


@PrePassivate
public void ejbPassivate()
{

}


public void setSessionContext(SessionContext sc)
{
ctx = sc;
}



public String getPasswordHint(String userName, String districtOid) throws AuthenticationFailedException
{

return passwordHint;
}



}

------------------------------------------------------------------------------------------------

package EJB3Code;


import java.util.Collection;
import javax.ejb.EJBException;
import javax.ejb.EJBObject;


@Remote
public interface EJB3Remote
{

public String getPasswordHint(String userName, String districtOid) throws AuthenticationFailedException;


}

----------------------------------------------------------------------------------------------------
 
Do you pee on your compost? Does this tiny ad?
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic