Actually
My goal is to deploy a cxf groovy service possibly using the aegis
service. I thought I was successful but get this error. When I do
compile the script this is working file. I also attached my conf
files.
Thanks
29 sept. 2007 09:57:28 org.springframework.web.context.ContextLoader
initWebApplicationContext
GRAVE: Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name
'org.apache.cxf.frontend.ServerFactoryBean--2003537636':
Initialization of bean
failed; nested exception is
org.springframework.beans.TypeMismatchException: Failed to convert
property value of type [java.lang.String] to required type [java.lang.
Class] for property 'serviceClass'; nested exception is
java.lang.IllegalArgumentException: Cannot find class [HelloWorld].
Root cause: java.lang.ClassNotFoundExcepti
on: HelloWorld
Caused by: org.springframework.beans.TypeMismatchException: Failed to
convert property value of type [java.lang.String] to required type
[java.lang.Class] for propert
y 'serviceClass'; nested exception is
java.lang.IllegalArgumentException: Cannot find class [HelloWorld].
Root cause: java.lang.ClassNotFoundException: HelloWorld
Caused by: java.lang.IllegalArgumentException: Cannot find class
[HelloWorld]. Root cause: java.lang.ClassNotFoundException: HelloWorld
at
org.springframework.util.ClassUtils.resolveClassName(ClassUtils.java:223)
at
org.springframework.beans.propertyeditors.ClassEditor.setAsText(ClassEditor.java:63)
at
org.springframework.beans.TypeConverterDelegate.doConvertTextValue(TypeConverterDelegate.java:320)
at
org.springframework.beans.TypeConverterDelegate.doConvertValue(TypeConverterDelegate.java:304)
at
org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:192)
at
org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:138)
at
org.springframework.beans.BeanWrapperImpl.convertForProperty(BeanWrapperImpl.java:380)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1079)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:835)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:423)
at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:144)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:279)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:360)
at
org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:241)
at
org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:184)
at
org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3764)
at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4216)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:740)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)
at
org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920)
at
org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:120)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1022)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:736)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014)
at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at
org.apache.catalina.core.StandardService.start(StandardService.java:448)
at
org.apache.catalina.core.StandardServer.start(StandardServer.java:700)
at org.apache.catalina.startup.Catalina.start(Catalina.java:552)
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:585)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:295)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:433)
On 9/29/07, Freeman Fang <[EMAIL PROTECTED]> wrote:
> Hi Guillaume,
>
> I just recall we programmatically publish endpoint in CXFServlet at very
> first version, but now we all delegate to spring to do it. You can refer to
> http://fisheye6.cenqua.com/browse/celtixfire/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/servlet/CXFServlet.java?r=448031
>
> to get roughly idea how we do it before, but I don't think it's a good
> way now, spring is more flexsiable.
>
> Best Regard
>
> Freeman
>
> Jeff.Yu wrote:
> > Hi,
> >
> > Do you mean you want to publish the endpoint without spring
> > configuration? If you want to do this, you need to write your servlet
> > to publish the endpoint programmatically.
> >
> > Thanks
> > Jeff
> >
> > tog wrote:
> >> Thanks
> >> This is working fine now ...
> >> I got a cxf groovy service running inside tomcat now.
> >> Is there a way to get rid of the spring configuration ? Should I write
> >> my own servlet as a mix of the groovy servlet and cxf servlet ?
> >>
> >> Thanks
> >> Guillaume
> >>
> >> On 9/27/07, Jeff.Yu <[EMAIL PROTECTED]> wrote:
> >>
> >>> Hi, Guillaume
> >>>
> >>> See my comments inline.
> >>>
> >>> Thanks
> >>> Jeff
> >>>
> >>> tog wrote:
> >>>
> >>>> Hiya,
> >>>>
> >>>> I would like to publish an aegis service in tomcat using groovyws. As
> >>>> a starting point, I have tried the java_first_pojo samples (2.0.2). I
> >>>> deployed successfully but could not access it using
> >>>> http://localhost:8080/services/hello_world?wsdl
> >>>>
> >>>>
> >>> The URL should be:
> >>> http://localhost:8080/helloworld/services/hello_world?wsdl
> >>>
> >>>
> >>>> I then would like to avoid spring configuration and publish my
> >>>> endpoint in Java. The doc
> >>>> http://cwiki.apache.org/CXF20DOC/servlet-transport.html says I just
> >>>> need to use EndPoint.publish(...) ...
> >>>> Could someone give me more detail on this ?
> >>>>
> >>>>
> >>> There are two ways to publish the endpoint, one is using CXF interal
> >>> API
> >>> [1], the other is JAX-WS based [2] that you are looking for.
> >>>
> >>> [1]
> >>> http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/java_first_pojo/src/demo/hw/server/Server.java?view=markup
> >>>
> >>> [2]
> >>> http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/java_first_jaxws/src/demo/hw/server/Server.java?view=markup
> >>>
> >>>
> >>>> Thanks
> >>>> Guillaume
> >>>>
> >>>>
> >>>>
> >>>>
> >>
> >>
> >>
> >
>
--
Best Regards
Guillaume
http://cheztog.blogspot.com
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app
PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd">
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<!-- START SNIPPET: webxml -->
<web-app>
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>WEB-INF/beans-groovy.xml</param-value>
</context-param>
<listener>
<listener-class>
org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>
<servlet>
<servlet-name>CXFServlet</servlet-name>
<display-name>CXF Servlet</display-name>
<servlet-class>
org.apache.cxf.transport.servlet.CXFServlet
</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>CXFServlet</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>
</web-app>
<!-- END SNIPPET: webxml --><?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<!-- START SNIPPET: beans -->
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:simple="http://cxf.apache.org/simple"
xmlns:lang="http://www.springframework.org/schema/lang"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/lang http://www.springframework.org/schema/lang/spring-lang-2.0.xsd
http://cxf.apache.org/simple http://cxf.apache.org/schemas/simple.xsd">
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
<lang:groovy id="helloworld" script-source="classpath:HelloWorld.groovy" scope="prototype">
</lang:groovy>
<lang:groovy id="helloworldImpl" script-source="classpath:HelloWorldImpl.groovy" scope="prototype">
</lang:groovy>
<simple:server serviceClass="HelloWorld" address="/HelloWorld">
<simple:serviceBean>
<ref bean="helloworldImpl" />
</simple:serviceBean>
</simple:server>
</beans>
<!-- END SNIPPET: beans -->