You have to remove the type="com.ReadFiles.ReadFiles" attribute on your
activationSpec definition.

On 8/18/06, Sivashankar <[EMAIL PROTECTED]> wrote:

Guillaume Nodet <[EMAIL PROTECTED]> writes:

>
> This error is caused by an invalid "type" attribute defined on the
> activationSpec.
>
> On 8/18/06, Sivashankar <[EMAIL PROTECTED]> wrote:
> > Hi i am working on deploying a component to servicemix ESB. My component is
> > working properly but it is executing twice. The second time it is throwing
> > exceptions but it is enough for me to run once.
> >
> > for example when i call a constructor once it is called by the server twice
> > and throwing error in the second time.
> >
> > Can any one help me out please.
> >
> > this is the error iam getting before execution of my component...
> >
> >
> > servicemix.bat: Ignoring predefined value for SERVICEMIX_HOME
> > Apache ServiceMix ESB: 3.0-M2-incubating
> >
> > Loading Apache ServiceMix from file: servicemix.xml
> > Into read files, readAll().......
> > Caught: org.springframework.beans.factory.BeanCreationException: Error
> > creating bean with
name 'org.apache.servicemix.jbi.container.ActivationSpec'
> > defin
> > D:\MAINFRAME\Install\aservicemix-3.0-M2-
> > incubating\examples\test\servicemix.xml]: Error setting property values;
> > nested exception is org.springframework.
> > tablePropertyException: Invalid property 'type' of bean class
> > [org.apache.servicemix.jbi.container.ActivationSpec]: Bean property 'type'
is
> > not writable
> > valid setter method. Does the parameter type of the setter match the return
> > type of the getter?
> > org.springframework.beans.factory.BeanCreationException: Error creating
bean
> > with name 'org.apache.servicemix.jbi.container.ActivationSpec' defined in
fi
> > RAME\Install\aservicemix-3.0-M2-incubating\examples\test\servicemix.xml]:
> > Error setting property values; nested exception is
org.springframework.beans.No
> > pertyException: Invalid property 'type' of bean class
> > [org.apache.servicemix.jbi.container.ActivationSpec]: Bean property 'type'
is
> > not writable or has a
> > tter method. Does the parameter type of the setter match the return type of
> > the getter?
> > Caused by: org.springframework.beans.NotWritablePropertyException: Invalid
> > property 'type' of bean class
[org.apache.servicemix.jbi.container.ActivationS
> > roperty 'type' is not writable or has an invalid setter method. Does the
> > parameter type of the setter match the return type of the getter?
> >         at org.springframework.beans.BeanWrapperImpl.setPropertyValue
> > (BeanWrapperImpl.java:699)
> >         at org.springframework.beans.BeanWrapperImpl.setPropertyValue
> > (BeanWrapperImpl.java:575)
> >         at
org.springframework.beans.AbstractPropertyAccessor.setPropertyValue
> > (AbstractPropertyAccessor.java:49)
> >         at
org.springframework.beans.AbstractPropertyAccessor.setPropertyValues
> > (AbstractPropertyAccessor.java:68)
> >         at
org.springframework.beans.AbstractPropertyAccessor.setPropertyValues
> > (AbstractPropertyAccessor.java:57)
> >         at
> >
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.ap
> > plyPropertyValues(AbstractAutowireCapableBeanFactory.java:813)
> >         at
> >
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.po
> > pulateBean(AbstractAutowireCapableBeanFactory.java:589)
> >         at
> >
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.cr
> > eateBean(AbstractAutowireCapableBeanFactory.java:389)
> >         at
> > org.springframework.beans.factory.support.AbstractBeanFactory.getBean
> > (AbstractBeanFactory.java:256)
> >         at
> > org.springframework.beans.factory.support.AbstractBeanFactory.getBean
> > (AbstractBeanFactory.java:167)
> >         at
> >
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstant
> > iateSingletons(DefaultListableBeanFactory.java:253)
> >         at
> > org.springframework.context.support.AbstractApplicationContext.refresh
> > (AbstractApplicationContext.java:332)
> >         at
> > org.apache.xbean.spring.context.FileSystemXmlApplicationContext.<init>
> > (FileSystemXmlApplicationContext.java:150)
> >         at
> > org.apache.xbean.spring.context.FileSystemXmlApplicationContext.<init>
> > (FileSystemXmlApplicationContext.java:101)
> >         at org.apache.servicemix.Main.main(Main.java:80)
> >         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.codehaus.classworlds.Launcher.launchStandard
(Launcher.java:410)
> >         at org.codehaus.classworlds.Launcher.launch(Launcher.java:344)
> >         at org.codehaus.classworlds.Launcher.main(Launcher.java:461)
> >
> >
> >
> >
> >
> >
>

hi Guillaume Nodet

i am trying to give an input from this servicemix.xml to make a FTP server
read files from local directory to an FTP server. My source is Readfiles.java
with its corressponding packages. i don know where i have to specify that type
and also what type....

this is the input xml iam giving to the server.....

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns:sm="http://servicemix.apache.org/config/1.0";>

  <!-- the JBI container -->
  <sm:container id="jbi"
                rootDir="./wdir"
                installationDirPath="./install"
                deploymentDirPath="./deploy"
                flowName="seda" >
<sm:activationSpecs >
<sm:activationSpec componentName="ReadFiles"
                                service="foo:ReadFiles"
type="com.ReadFiles.ReadFiles">

                                <sm:component>
                                     <bean class="com.ReadFiles.ReadFiles">
                             <constructor-arg
type="java.lang.String"><value>D:/ftp/FTP.log</value></constructor-arg>
                             </bean>
                                </sm:component>

</sm:activationSpec>

</sm:activationSpecs>

  </sm:container>

  <!-- message broker -->

</beans>







--
Cheers,
Guillaume Nodet

Reply via email to