You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by avrono <av...@neuralm.com> on 2013/01/04 15:19:42 UTC

WARNING: WebAppInfo not found.

Hi, 

I am having a problem deploying and using the webservice in this 
http://openejb.apache.org/examples-trunk/simple-webservice/
<http://openejb.apache.org/examples-trunk/simple-webservice/>   example

Any ideas how to resolve the "WARNING: WebAppInfo not found." error/warning
?

I have copied the .jar to the Webapps folder of my TomEE installation and I
am trying to run the JUnit test from another project. The test fails with a
ServiceConstructionException

Below is the server startup log (relevant part)


04-Jan-2013 14:11:41 org.apache.openejb.config.ConfigurationFactory
configureApplication
INFO: Configuring enterprise application:
/home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar
04-Jan-2013 14:11:41 org.apache.openejb.config.InitEjbDeployments deploy
INFO: Auto-deploying ejb Calculator: EjbDeployment(deployment-id=Calculator)
04-Jan-2013 14:11:41 org.apache.openejb.config.AppInfoBuilder build
INFO: Enterprise application
"/home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar"
loaded.
04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
createApplication
INFO: Assembling app:
/home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar
04-Jan-2013 14:11:41 org.apache.openejb.cdi.CdiBuilder initSingleton
INFO: Existing thread singleton service in SystemInstance()
org.apache.openejb.cdi.ThreadSingletonServiceImpl@5da37c
04-Jan-2013 14:11:41 org.apache.openejb.cdi.OpenEJBLifecycle
startApplication
INFO: OpenWebBeans Container is starting...
04-Jan-2013 14:11:41 org.apache.webbeans.plugins.PluginLoader startUp
INFO: Adding OpenWebBeansPlugin : [CdiPlugin]
04-Jan-2013 14:11:41 org.apache.webbeans.plugins.PluginLoader startUp
INFO: Adding OpenWebBeansPlugin : [OpenWebBeansJsfPlugin]
04-Jan-2013 14:11:41 org.apache.openejb.cdi.BeansDeployer
validateInjectionPoints
INFO: All injection points are validated successfully.
04-Jan-2013 14:11:41 org.apache.openejb.cdi.OpenEJBLifecycle
startApplication
INFO: OpenWebBeans Container has started, it took 4 ms.
04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
createApplication
INFO: Created Ejb(deployment-id=Calculator, ejb-name=Calculator,
container=My Stateless Container)
04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
createApplication
INFO: Started Ejb(deployment-id=Calculator, ejb-name=Calculator,
container=My Stateless Container)
04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
createApplication
INFO: Deployed
Application(path=/home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar)
04-Jan-2013 14:11:41
org.apache.cxf.service.factory.ReflectionServiceFactoryBean
buildServiceFromClass
INFO: Creating Service {http://superbiz.org/wsdl}CalculatorService from
class org.superbiz.calculator.ws.CalculatorWs
04-Jan-2013 14:11:42 org.apache.cxf.endpoint.ServerImpl initDestination
INFO: Setting the server's publish address to be http://nopath:80
04-Jan-2013 14:11:42 org.apache.tomee.catalina.TomcatWebAppBuilder init
INFO: -------------------------
TomcatWebAppBuilder.init /Calculator
04-Jan-2013 14:11:42 org.apache.tomee.catalina.OpenEJBContextConfig
processAnnotationsUrl
WARNING: WebAppInfo not found.
StandardContextInfo{standardContext=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/Calculator]}
04-Jan-2013 14:11:42 org.apache.tomee.catalina.OpenEJBContextConfig
processAnnotationsUrl
WARNING: WebAppInfo not found.
StandardContextInfo{standardContext=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/Calculator]}
04-Jan-2013 14:11:43 org.apache.tomee.catalina.OpenEJBContextConfig
processAnnotationsUrl
WARNING: WebAppInfo not found.
StandardContextInfo{standardContext=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/Calculator]}
java.lang.NullPointerException
	at
org.apache.tomee.catalina.TomcatJndiBuilder.mergeJava(TomcatJndiBuilder.java:247)
	at
org.apache.tomee.catalina.TomcatJavaJndiBinder.lifecycleEvent(TomcatJavaJndiBinder.java:30)
	at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
	at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5173)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:618)
	at
org.apache.tomee.webservices.TomcatWsRegistry.deployInFakeWebapp(TomcatWsRegistry.java:200)
	at
org.apache.tomee.webservices.TomcatWsRegistry.addWsContainer(TomcatWsRegistry.java:192)
	at
org.apache.openejb.server.webservices.WsService.afterApplicationCreated(WsService.java:279)
	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:597)
	at
org.apache.openejb.observer.ObserverManager$Observer.invoke(ObserverManager.java:145)
	at
org.apache.openejb.observer.ObserverManager.fireEvent(ObserverManager.java:69)
	at
org.apache.openejb.loader.SystemInstance.fireEvent(SystemInstance.java:105)
	at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:929)
	at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:532)
	at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:528)
	at
org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:1394)
	at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:124)
	at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
	at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1374)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1530)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1540)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1519)
	at java.lang.Thread.run(Thread.java:662)
04-Jan-2013 14:11:43 org.apache.myfaces.ee6.MyFacesContainerInitializer
onStartup
INFO: Added FacesServlet with mappings=[/faces/*, *.jsf, *.faces]
04-Jan-2013 14:11:43
org.apache.myfaces.config.DefaultFacesConfigurationProvider
getStandardFacesConfig
INFO: Reading standard config META-INF/standard-faces-config.xml
04-Jan-2013 14:11:43
org.apache.myfaces.config.DefaultFacesConfigurationProvider
getClassloaderFacesConfig
INFO: Reading config :
jar:file:/home/avrono/TomEE/apache-tomee-plus-1.5.0/lib/primefaces-3.4.2.jar!/META-INF/faces-config.xml
04-Jan-2013 14:11:43 org.apache.myfaces.config.LogMetaInfUtils logArtifact
INFO: Artifact 'myfaces-api' was found in version '2.1.9' from path
'file:/home/avrono/TomEE/apache-tomee-plus-1.5.0/lib/myfaces-api-2.1.9.jar'
04-Jan-2013 14:11:43 org.apache.myfaces.config.LogMetaInfUtils logArtifact
INFO: Artifact 'myfaces-impl' was found in version '2.1.9' from path
'file:/home/avrono/TomEE/apache-tomee-plus-1.5.0/lib/myfaces-impl-2.1.9.jar'
04-Jan-2013 14:11:43 org.apache.myfaces.application.ApplicationImpl
getProjectStage
INFO: Couldn't discover the current project stage, using Production
04-Jan-2013 14:11:43 org.apache.myfaces.config.FacesConfigurator
handleSerialFactory
INFO: Serialization provider : class
org.apache.myfaces.shared_impl.util.serial.DefaultSerialFactory
04-Jan-2013 14:11:43
org.apache.myfaces.config.annotation.DefaultLifecycleProviderFactory
getLifecycleProvider
INFO: Using LifecycleProvider
org.apache.myfaces.config.annotation.Tomcat7AnnotationLifecycleProvider
04-Jan-2013 14:11:43
org.primefaces.webapp.PostConstructApplicationEventListener processEvent
INFO: Running on PrimeFaces 3.4.2
04-Jan-2013 14:11:43 org.apache.myfaces.webapp.AbstractFacesInitializer
initFaces
INFO: ServletContext initialized.
04-Jan-2013 14:11:43 org.apache.openejb.server.webservices.WsService
afterApplicationCreated
INFO: Webservice(wsdl=http://localhost:8080/Calculator,
qname={http://superbiz.org/wsdl}CalculatorService) --> Ejb(id=Calculator)



--
View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: WARNING: WebAppInfo not found.

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi,

webapps folder is for webapp ATM, try to put the jar in <tomee>/apps

Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau



2013/1/4 avrono <av...@neuralm.com>:
> Hi,
>
> I am having a problem deploying and using the webservice in this
> http://openejb.apache.org/examples-trunk/simple-webservice/
> <http://openejb.apache.org/examples-trunk/simple-webservice/>   example
>
> Any ideas how to resolve the "WARNING: WebAppInfo not found." error/warning
> ?
>
> I have copied the .jar to the Webapps folder of my TomEE installation and I
> am trying to run the JUnit test from another project. The test fails with a
> ServiceConstructionException
>
> Below is the server startup log (relevant part)
>
>
> 04-Jan-2013 14:11:41 org.apache.openejb.config.ConfigurationFactory
> configureApplication
> INFO: Configuring enterprise application:
> /home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar
> 04-Jan-2013 14:11:41 org.apache.openejb.config.InitEjbDeployments deploy
> INFO: Auto-deploying ejb Calculator: EjbDeployment(deployment-id=Calculator)
> 04-Jan-2013 14:11:41 org.apache.openejb.config.AppInfoBuilder build
> INFO: Enterprise application
> "/home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar"
> loaded.
> 04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
> createApplication
> INFO: Assembling app:
> /home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar
> 04-Jan-2013 14:11:41 org.apache.openejb.cdi.CdiBuilder initSingleton
> INFO: Existing thread singleton service in SystemInstance()
> org.apache.openejb.cdi.ThreadSingletonServiceImpl@5da37c
> 04-Jan-2013 14:11:41 org.apache.openejb.cdi.OpenEJBLifecycle
> startApplication
> INFO: OpenWebBeans Container is starting...
> 04-Jan-2013 14:11:41 org.apache.webbeans.plugins.PluginLoader startUp
> INFO: Adding OpenWebBeansPlugin : [CdiPlugin]
> 04-Jan-2013 14:11:41 org.apache.webbeans.plugins.PluginLoader startUp
> INFO: Adding OpenWebBeansPlugin : [OpenWebBeansJsfPlugin]
> 04-Jan-2013 14:11:41 org.apache.openejb.cdi.BeansDeployer
> validateInjectionPoints
> INFO: All injection points are validated successfully.
> 04-Jan-2013 14:11:41 org.apache.openejb.cdi.OpenEJBLifecycle
> startApplication
> INFO: OpenWebBeans Container has started, it took 4 ms.
> 04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
> createApplication
> INFO: Created Ejb(deployment-id=Calculator, ejb-name=Calculator,
> container=My Stateless Container)
> 04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
> createApplication
> INFO: Started Ejb(deployment-id=Calculator, ejb-name=Calculator,
> container=My Stateless Container)
> 04-Jan-2013 14:11:41 org.apache.openejb.assembler.classic.Assembler
> createApplication
> INFO: Deployed
> Application(path=/home/avrono/TomEE/apache-tomee-plus-1.5.0/webapps/simple-webservice-1.1.0-SNAPSHOT.jar)
> 04-Jan-2013 14:11:41
> org.apache.cxf.service.factory.ReflectionServiceFactoryBean
> buildServiceFromClass
> INFO: Creating Service {http://superbiz.org/wsdl}CalculatorService from
> class org.superbiz.calculator.ws.CalculatorWs
> 04-Jan-2013 14:11:42 org.apache.cxf.endpoint.ServerImpl initDestination
> INFO: Setting the server's publish address to be http://nopath:80
> 04-Jan-2013 14:11:42 org.apache.tomee.catalina.TomcatWebAppBuilder init
> INFO: -------------------------
> TomcatWebAppBuilder.init /Calculator
> 04-Jan-2013 14:11:42 org.apache.tomee.catalina.OpenEJBContextConfig
> processAnnotationsUrl
> WARNING: WebAppInfo not found.
> StandardContextInfo{standardContext=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/Calculator]}
> 04-Jan-2013 14:11:42 org.apache.tomee.catalina.OpenEJBContextConfig
> processAnnotationsUrl
> WARNING: WebAppInfo not found.
> StandardContextInfo{standardContext=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/Calculator]}
> 04-Jan-2013 14:11:43 org.apache.tomee.catalina.OpenEJBContextConfig
> processAnnotationsUrl
> WARNING: WebAppInfo not found.
> StandardContextInfo{standardContext=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/Calculator]}
> java.lang.NullPointerException
>         at
> org.apache.tomee.catalina.TomcatJndiBuilder.mergeJava(TomcatJndiBuilder.java:247)
>         at
> org.apache.tomee.catalina.TomcatJavaJndiBinder.lifecycleEvent(TomcatJavaJndiBinder.java:30)
>         at
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>         at
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
>         at
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5173)
>         at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>         at
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
>         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
>         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:618)
>         at
> org.apache.tomee.webservices.TomcatWsRegistry.deployInFakeWebapp(TomcatWsRegistry.java:200)
>         at
> org.apache.tomee.webservices.TomcatWsRegistry.addWsContainer(TomcatWsRegistry.java:192)
>         at
> org.apache.openejb.server.webservices.WsService.afterApplicationCreated(WsService.java:279)
>         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:597)
>         at
> org.apache.openejb.observer.ObserverManager$Observer.invoke(ObserverManager.java:145)
>         at
> org.apache.openejb.observer.ObserverManager.fireEvent(ObserverManager.java:69)
>         at
> org.apache.openejb.loader.SystemInstance.fireEvent(SystemInstance.java:105)
>         at
> org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:929)
>         at
> org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:532)
>         at
> org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:528)
>         at
> org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:1394)
>         at
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:124)
>         at
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>         at
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
>         at
> org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1374)
>         at
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1530)
>         at
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1540)
>         at
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1519)
>         at java.lang.Thread.run(Thread.java:662)
> 04-Jan-2013 14:11:43 org.apache.myfaces.ee6.MyFacesContainerInitializer
> onStartup
> INFO: Added FacesServlet with mappings=[/faces/*, *.jsf, *.faces]
> 04-Jan-2013 14:11:43
> org.apache.myfaces.config.DefaultFacesConfigurationProvider
> getStandardFacesConfig
> INFO: Reading standard config META-INF/standard-faces-config.xml
> 04-Jan-2013 14:11:43
> org.apache.myfaces.config.DefaultFacesConfigurationProvider
> getClassloaderFacesConfig
> INFO: Reading config :
> jar:file:/home/avrono/TomEE/apache-tomee-plus-1.5.0/lib/primefaces-3.4.2.jar!/META-INF/faces-config.xml
> 04-Jan-2013 14:11:43 org.apache.myfaces.config.LogMetaInfUtils logArtifact
> INFO: Artifact 'myfaces-api' was found in version '2.1.9' from path
> 'file:/home/avrono/TomEE/apache-tomee-plus-1.5.0/lib/myfaces-api-2.1.9.jar'
> 04-Jan-2013 14:11:43 org.apache.myfaces.config.LogMetaInfUtils logArtifact
> INFO: Artifact 'myfaces-impl' was found in version '2.1.9' from path
> 'file:/home/avrono/TomEE/apache-tomee-plus-1.5.0/lib/myfaces-impl-2.1.9.jar'
> 04-Jan-2013 14:11:43 org.apache.myfaces.application.ApplicationImpl
> getProjectStage
> INFO: Couldn't discover the current project stage, using Production
> 04-Jan-2013 14:11:43 org.apache.myfaces.config.FacesConfigurator
> handleSerialFactory
> INFO: Serialization provider : class
> org.apache.myfaces.shared_impl.util.serial.DefaultSerialFactory
> 04-Jan-2013 14:11:43
> org.apache.myfaces.config.annotation.DefaultLifecycleProviderFactory
> getLifecycleProvider
> INFO: Using LifecycleProvider
> org.apache.myfaces.config.annotation.Tomcat7AnnotationLifecycleProvider
> 04-Jan-2013 14:11:43
> org.primefaces.webapp.PostConstructApplicationEventListener processEvent
> INFO: Running on PrimeFaces 3.4.2
> 04-Jan-2013 14:11:43 org.apache.myfaces.webapp.AbstractFacesInitializer
> initFaces
> INFO: ServletContext initialized.
> 04-Jan-2013 14:11:43 org.apache.openejb.server.webservices.WsService
> afterApplicationCreated
> INFO: Webservice(wsdl=http://localhost:8080/Calculator,
> qname={http://superbiz.org/wsdl}CalculatorService) --> Ejb(id=Calculator)
>
>
>
> --
> View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: WARNING: WebAppInfo not found.

Posted by avrono <av...@neuralm.com>.
Ok, resolvedThis works ....	CalculatorService service = new
CalculatorService();	    	CalculatorWs port = service.getCalculatorPort();	    
if(port !=null) {	    		System.out.println("Port is not null");	    	}	    
else {	    		System.out.println("Port is null");	    	}			int value =
port.sum(i, j);Very useful tutorial / explanation found  here
<http://java.boot.by/ocewsd6-guide/ch06.html>   



--
View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077p4660102.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: WARNING: WebAppInfo not found.

Posted by avrono <av...@neuralm.com>.
Hi Romain, 

The Directory directive solved the WebAppInfo error - thanks !

As for accessing the webservice via injection (annotation) I ran wsimport
and it generated my CalculatorService endpoint as follows:



/**
 * This class was generated by the JAX-WS RI.
 * JAX-WS RI 2.1.6 in JDK 6
 * Generated source version: 2.1
 * 
 */
@WebServiceClient(name = "CalculatorService", targetNamespace =
"http://superbiz.org/wsdl", wsdlLocation =
"http://localhost:8080/Calculator?wsdl")
public class CalculatorService
    extends Service
{

    private final static URL CALCULATORSERVICE_WSDL_LOCATION;
    private final static Logger logger =
Logger.getLogger(com.prsx.wsClient.CalculatorService.class.getName());

    static {
        URL url = null;
        try {
            URL baseUrl;
            baseUrl =
com.prsx.wsClient.CalculatorService.class.getResource(".");
            url = new URL(baseUrl, "http://localhost:8080/Calculator?wsdl");
        } catch (MalformedURLException e) {
            logger.warning("Failed to create URL for the wsdl Location:
'http://localhost:8080/Calculator?wsdl', retrying as a local file");
            logger.warning(e.getMessage());
        }
        CALCULATORSERVICE_WSDL_LOCATION = url;
    }

    public CalculatorService(URL wsdlLocation, QName serviceName) {
        super(wsdlLocation, serviceName);
    }

    public CalculatorService() {
        super(CALCULATORSERVICE_WSDL_LOCATION, new
QName("http://superbiz.org/wsdl", "CalculatorService"));
    }

    /**
     * 
     * @return
     *     returns CalculatorWs
     */
    @WebEndpoint(name = "CalculatorPort")
    public CalculatorWs getCalculatorPort() {
        return super.getPort(new QName("http://superbiz.org/wsdl",
"CalculatorPort"), CalculatorWs.class);
    }

    /**
     * 
     * @param features
     *     A list of {@link javax.xml.ws.WebServiceFeature} to configure on
the proxy.  Supported features not in the <code>features</code> parameter
will have their default values.
     * @return
     *     returns CalculatorWs
     */
    @WebEndpoint(name = "CalculatorPort")
    public CalculatorWs getCalculatorPort(WebServiceFeature... features) {
        return super.getPort(new QName("http://superbiz.org/wsdl",
"CalculatorPort"), CalculatorWs.class, features);
    }

}



I am assuming I do not need to do anything other than ....

private static CalculatorService service;

CalculatorWs port = service.getPort(CalculatorWs.class);
	    	if(port !=null) {
	    		System.out.println("Port is not null");
	    	}
	    	else {
	    		System.out.println("Port is null");
	    	}
			int value = port.sum(i, j);


However, I get a null pointer exception on the getPort



--
View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077p4660101.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: WARNING: WebAppInfo not found.

Posted by Romain Manni-Bucau <rm...@gmail.com>.
probably because the injection type doesn't have all info (@webserviceclient?)

that's said i didn't understand your "not in wtpwebapps" answer.
apps folder is configured in tomee.xml (<Deployments dir="apps" />)

Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau



2013/1/4 avrono <av...@neuralm.com>:
> further to that, I can get the .create working but not via injection
> @WebServiceRef(wsdlLocation =   "http://localhost:8080/Calculator?wsdl")
>
>
>
> --
> View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077p4660084.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: WARNING: WebAppInfo not found.

Posted by avrono <av...@neuralm.com>.
further to that, I can get the .create working but not via injection
@WebServiceRef(wsdlLocation =	"http://localhost:8080/Calculator?wsdl")



--
View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077p4660084.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: WARNING: WebAppInfo not found.

Posted by avrono <av...@neuralm.com>.
Interestingly I can run a Junit test as follows :

package com.prsx.test;
import org.junit.BeforeClass;
import org.junit.Test;

import javax.ejb.embeddable.EJBContainer;
import javax.xml.namespace.QName;
import javax.xml.ws.Service;
import java.net.URL;
import java.util.Properties;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;

public class CalculatorTest {

    @BeforeClass
    public static void setUp() throws Exception {
        Properties properties = new Properties();
        properties.setProperty("openejb.embedded.remotable", "true");
        //properties.setProperty("httpejbd.print", "true");
        //properties.setProperty("httpejbd.indent.xml", "true");
        EJBContainer.createEJBContainer(properties);
    }

    @Test
    public void test() throws Exception {
        Service calculatorService = Service.create(
                //new URL("http://127.0.0.1:4204/Calculator?wsdl"),
                new URL("http://localhost:8080/Calculator?wsdl"),
                new QName("http://superbiz.org/wsdl", "CalculatorService"));

        assertNotNull(calculatorService);

        CalculatorWs calculator =
calculatorService.getPort(CalculatorWs.class);
        assertEquals(10, calculator.sum(4, 6));
        assertEquals(12, calculator.multiply(3, 4));
    }
}



But I cannot do the following :

package com.prsx;



import java.net.MalformedURLException;
import java.net.URL;

import javax.xml.namespace.QName;
import javax.xml.ws.Service;
import javax.xml.ws.WebServiceRef;

import com.myfirst.wsClient.CalculatorService;
import com.myfirst.wsClient.CalculatorWs;

public class HelloPojo {



	public String from() {
		return "POJO";
	}
	
	 public int sum(int i, int j) throws MalformedURLException {
		 /*
	    	CalculatorWs port = service.getCalculatorPort();
	    	if(port !=null) {
	    		System.out.println("Port is not null");
	    	}
	    	else {
	    		System.out.println("Port is null");
	    	}
			int value = port.sum(i, j);
			*/
		 
		 Service calculatorService = Service.create(
	                //new URL("http://127.0.0.1:4204/Calculator?wsdl"),
	                new URL("http://localhost:8080/Calculator?wsdl"),
	                new QName("http://superbiz.org/wsdl",
"CalculatorService"));
		 CalculatorWs calculator = calculatorService.getPort(CalculatorWs.class);
		 int value = calculator.sum(i, j);
		return value;
	    }
}


Any ideas ?



--
View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077p4660083.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: WARNING: WebAppInfo not found.

Posted by avrono <av...@neuralm.com>.
Not found in wtpwebapps folder



--
View this message in context: http://openejb.979440.n4.nabble.com/WARNING-WebAppInfo-not-found-tp4660077p4660082.html
Sent from the OpenEJB User mailing list archive at Nabble.com.