intact-kickstart seems not to work any more

151 views
Skip to first unread message

dominik...@biologie.uni-freiburg.de

unread,
Oct 13, 2011, 2:12:08 PM10/13/11
to intact-developers
Hey guys,

i am trying to combine the backbone of the intact library with my
software and used the intact-kickstart to create database and stuff. I
ran in several problems concerning library dependencies but i think i
managed so far. Though, when trying again the database is not created
any more, not even when i checkout the current intact-kickstart
version and ran again.

The following error occurs:

------------------StartException--------------------------
Exception in thread "main"
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'interactorFetcher' defined in URL [jar:file:/
C:/Users/dominator/.m2/repository/uk/ac/ebi/intact/dataexchange/intact-
enricher/2.1.1/intact-enricher-2.1.1.jar!/uk/ac/ebi/intact/
dataexchange/enricher/fetch/InteractorFetcher.class]: Instantiation of
bean failed; nested exception is
org.springframework.beans.BeanInstantiationException: Could not
instantiate bean class
[uk.ac.ebi.intact.dataexchange.enricher.fetch.InteractorFetcher]:
Constructor threw exception; nested exception is
javax.xml.ws.WebServiceException: Failed to access the WSDL at:
http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl. It failed
with:
http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl.
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:
883)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:
839)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:
440)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory
$1.run(AbstractAutowireCapableBeanFactory.java:409)
at java.security.AccessController.doPrivileged(Native Method)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:
380)
at org.springframework.beans.factory.support.AbstractBeanFactory
$1.getObject(AbstractBeanFactory.java:264)
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:
222)
at
org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:
261)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:
185)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:
164)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:
429)
at
org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:
728)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:
380)
at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:
139)
at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:
105)
at
uk.ac.ebi.intact.core.context.IntactContext.initContext(IntactContext.java:
198)
at
uk.ac.ebi.intact.core.context.IntactContext.initContext(IntactContext.java:
164)
at uk.ac.ebi.intact.kickstart.CreateDatabase.main(CreateDatabase.java:
34)
Caused by: org.springframework.beans.BeanInstantiationException: Could
not instantiate bean class
[uk.ac.ebi.intact.dataexchange.enricher.fetch.InteractorFetcher]:
Constructor threw exception; nested exception is
javax.xml.ws.WebServiceException: Failed to access the WSDL at:
http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl. It failed
with:
http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl.
at
org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:
115)
at
org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:
61)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:
877)
... 18 more
Caused by: javax.xml.ws.WebServiceException: Failed to access the WSDL
at: http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl. It failed
with:
http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl.
at
com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.tryWithMex(RuntimeWSDLParser.java:
162)
at
com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:
144)
at
com.sun.xml.ws.client.WSServiceDelegate.parseWSDL(WSServiceDelegate.java:
264)
at
com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:
227)
at
com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:
175)
at
com.sun.xml.ws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:
104)
at javax.xml.ws.Service.<init>(Unknown Source)
at
uk.ac.ebi.chebi.webapps.chebiWS.model.ChebiWebServiceService.<init>(ChebiWebServiceService.java:
40)
at
uk.ac.ebi.chebi.webapps.chebiWS.client.ChebiWebServiceClient.<init>(ChebiWebServiceClient.java:
27)
at
uk.ac.ebi.intact.dataexchange.enricher.fetch.InteractorFetcher.<init>(InteractorFetcher.java:
53)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown
Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown
Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at
org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:
100)
... 20 more
Caused by: java.io.FileNotFoundException: http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)
at java.net.URL.openStream(Unknown Source)
at
com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.createReader(RuntimeWSDLParser.java:
805)
at
com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.resolveWSDL(RuntimeWSDLParser.java:
262)
at
com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:
129)
... 33 more
------------------StopException--------------------------

In order to sum up, it seems that a ChebiWebServiceService class is
used in the beginning of intact-kickstart trying to address
http://www.ebi.ac.uk/webservices/chebi/webservice?wsdl and fails.

I Just checked and realized that the requested file really isn´t at
its place. There now seems to be a new place for it:
http://www.ebi.ac.uk/webservices/chebi/2.0/webservice?wsdl

Since i cannot change this myself manually in the code, i guess this
is a bug? Or am i getting anything wrong?

Thanks for your efforts in advance!

Cheers,
Dominik

Bruno Aranda

unread,
Oct 14, 2011, 9:01:02 AM10/14/11
to intact-d...@googlegroups.com
Hi Dominik,

I think you are right. I will check the addresses as it seems the service has been moved,

Thanks for letting us know,

Bruno

Bruno Aranda

unread,
Oct 14, 2011, 10:05:01 AM10/14/11
to intact-d...@googlegroups.com
Hi Dominik,

I have identified the reason of the problem. Basically we were using an old version of the ChEBI Web Service. You have two solutions to the problem:

1) Add this in the <dependencies> sections of the pom.xml file to override the ChEBI client transitive dependency.

<!-- ChEBI Web service client - Overrides old 1.1 -->
        <dependency>
            <groupId>uk.ac.ebi.chebi.webapps.chebiWS.client</groupId>
            <artifactId>chebiWS-client</artifactId>
            <version>2.0</version>
            <exclusions>
                <exclusion>
                    <groupId>com.sun.xml.bind</groupId>
                    <artifactId>jaxb-xjc</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>javax.xml.ws</groupId>
                    <artifactId>jaxws-api</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

2) I have updated the dependencies of intact-kickstart to the latest stable version. Using the newer dependencies the problem with the ChEBI web service automatically disappears (basically, the version 2.0 is used). Should you want to use the latest version, just update the intact-kickstart project with subversion.

Hope this helps!

Bruno

dominik...@biologie.uni-freiburg.de

unread,
Oct 20, 2011, 1:45:45 PM10/20/11
to intact-developers
Hi Bruno,

thanks for the quick reply and your effort!

I checked out the whole intact-kickstart again and for different
reasons it did not work... Have you checked the intact-kickstart
after your changes?
The project compiles fine, but when starting the class
"CreateDatabase" it give me the following exception:
"nested exception is java.lang.NoSuchMethodError:
javax.persistence.spi.PersistenceUnitInfo.getValidationMode()Ljavax/
persistence/ValidationMode;"

I just copied the "hibernate-jpa-2.0-api-1.0.1.Final.jar" in order to
remove the error, and just ran into a new one:

Exception in thread "main"
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name
'org.springframework.dao.annotation.PersistenceExceptionTranslationPostProcessor#0'
defined in class path resource [META-INF/base.spring.xml]:
Initialization of bean failed; nested exception is
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'entityManagerFactory' defined in class path
resource [META-INF/base.spring.xml]: Invocation of init method failed;
nested exception is java.lang.ArrayStoreException:
sun.reflect.annotation.EnumConstantNotPresentExceptionProxy
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:
527)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:
456)
at org.springframework.beans.factory.support.AbstractBeanFactory
$1.getObject(AbstractBeanFactory.java:291)
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:
222)
at
org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:
288)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:
194)
at
org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:
710)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:
410)
at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:
139)
at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:
105)
at
uk.ac.ebi.intact.core.context.IntactContext.initContext(IntactContext.java:
172)
at
uk.ac.ebi.intact.core.context.IntactContext.initContext(IntactContext.java:
138)
at uk.ac.ebi.intact.kickstart.ExportToFasta.main(ExportToFasta.java:
39)


When running intact-kickstart on netbeans instead of eclipse, i get a
more precise error message:
error: in class file uk\ac\ebi\intact\model\Experiment.class(uk\ac\ebi
\intact\model:Experiment.class): unknown enum constant
javax.persistence.CascadeType.DETACH
error: in class file uk\ac\ebi\intact\model\Experiment.class(uk\ac\ebi
\intact\model:Experiment.class): unknown enum constant
org.hibernate.annotations.CascadeType.DETACH
error: in class file uk\ac\ebi\intact\model\Experiment.class(uk\ac\ebi
\intact\model:Experiment.class): unknown enum constant
org.hibernate.annotations.CascadeType.DETACH
error: in class file uk\ac\ebi\intact\model\Publication.class(uk\ac\ebi
\intact\model:Publication.class): unknown enum constant
org.hibernate.annotations.CascadeType.DETACH
error: in class file uk\ac\ebi\intact\model\Publication.class(uk\ac\ebi
\intact\model:Publication.class): unknown enum constant
javax.persistence.CascadeType.DETACH

And netbeans is right! ;-) The cascadeType.DETACH is not supported in
the older hibernate.anotations libraries included in intact-kickstart.
When i tried to import the newer ones containing CascadeType.DETACH,
i ran into several compatibility issues, so i guess some library
updates weren´t done in conjunction with some others...

Can you help me out in this issue? When i checked out the intact-
kickstart months ago, it worked fine with just few modifications, but
now i just see ugly exceptions ;-)

Cheers,
Dominik
> On 14 October 2011 14:01, Bruno Aranda <brunoara...@gmail.com> wrote:
>
>
>
>
>
>
>
> > Hi Dominik,
>
> > I think you are right. I will check the addresses as it seems the service
> > has been moved,
>
> > Thanks for letting us know,
>
> > Bruno
>
> > On 13 October 2011 19:12, dominik.mert...@biologie.uni-freiburg.de <
> >>http://www.ebi.ac.uk/webservices/chebi/webservice?wsdland fails.

Bruno Aranda

unread,
Oct 21, 2011, 4:43:03 AM10/21/11
to intact-d...@googlegroups.com
Hi,

It is responding as if you hadn't updated the main pom.xml file. I am running a few checks, but could you run the command

mvn dependency:tree

in the command line so I can compare the exact dependencies? You seem oto have problems with the jpa/hibernate dependencies. Could you check that the parent in the pom.xml file says version 41 of the intact-hibernate-master?

Tell me how that works!

Bruno
Reply all
Reply to author
Forward
0 new messages