[Geoserver-devel] Troubles with build server parallel builds

Hi,
recently I have seen a few builds failing due to strange classpath issues,
latest one:

Tests in error:
testRootSettingOnWorkSpace(org.geoserver.web.RESTPanelTest): Error creating bean with name ‘restWrapper’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/rest/target/gs-rest-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘geoServer’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘geoServer’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘catalog’ while setting bean property ‘catalog’; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘localWorkspaceCatalog’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘advertisedCatalog’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘advertisedCatalog’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘secureCatalog’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘accessRulesDao’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationSecurityContext.xml]>: Cannot resolve reference to bean ‘rawCatalog’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘rawCatalog’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: org/opengis/filter/sort/SortBy

I fear this is due to parallel builds accessing concurrently the local repo, and maybe changing
some of the xml files in the parents of the artifacts (maven-metadata-local.xml)

The problem of parallel builds with shared maven repo is unfortunately an unsolved one
(there is a ticket in maven jira), I found this that might help, but not sure if it works or not:
https://github.com/takari/takari-local-repository

Cheers
Andrea

==

GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.

==

Ing. Andrea Aime

@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it


I configured all the geotools/geoserver/geowebcache/etc… jobs on the build server to ensure that none of them run in parallel (using the jenkins lockes and latches plugin). It could be that i missed a combination. Do you know what builds specifically were running in parallel?

···

On Tue, Jun 17, 2014 at 6:18 AM, Andrea Aime <andrea.aime@anonymised.com> wrote:

Hi,
recently I have seen a few builds failing due to strange classpath issues,
latest one:

Tests in error:
testRootSettingOnWorkSpace(org.geoserver.web.RESTPanelTest): Error creating bean with name ‘restWrapper’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/rest/target/gs-rest-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘geoServer’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘geoServer’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘catalog’ while setting bean property ‘catalog’; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘localWorkspaceCatalog’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘advertisedCatalog’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘advertisedCatalog’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Cannot resolve reference to bean ‘secureCatalog’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘accessRulesDao’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationSecurityContext.xml]>: Cannot resolve reference to bean ‘rawCatalog’ while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘rawCatalog’ defined in URL [jar:<http://ares.opengeo.org/jenkins/job/geoserver-master/ws/src/main/target/gs-main-2.6-SNAPSHOT.jar!/applicationContext.xml]>: Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: org/opengis/filter/sort/SortBy

I fear this is due to parallel builds accessing concurrently the local repo, and maybe changing
some of the xml files in the parents of the artifacts (maven-metadata-local.xml)

The problem of parallel builds with shared maven repo is unfortunately an unsolved one
(there is a ticket in maven jira), I found this that might help, but not sure if it works or not:
https://github.com/takari/takari-local-repository

Cheers
Andrea

==

GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.

==

Ing. Andrea Aime

@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it



HPCC Systems Open Source Big Data Platform from LexisNexis Risk Solutions
Find What Matters Most in Your Big Data with HPCC Systems
Open Source. Fast. Scalable. Simple. Ideal for Dirty Data.
Leverages Graph Analysis for Fast Processing & Easy Data Exploration
http://p.sf.net/sfu/hpccsystems


Geoserver-devel mailing list
Geoserver-devel@anonymised.comt
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Justin Deoliveira
Vice President, Engineering | Boundless
jdeolive@anonymised.com
@j_deolive

On Tue, Jun 17, 2014 at 6:31 PM, Justin Deoliveira <
jdeolive@anonymised.com> wrote:

I configured all the geotools/geoserver/geowebcache/etc... jobs on the
build server to ensure that none of them run in parallel (using the jenkins
lockes and latches plugin). It could be that i missed a combination. Do you
know what builds specifically were running in parallel?

I saw geoserver 2.5.x and master run toghether. The file I was talking
about is shared among versions of the same artifact (it's in the folder
that contains all the versions of the artifact as subfolders).

Cheers
Andrea

--

GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

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

On Tue, Jun 17, 2014 at 10:32 AM, Andrea Aime <andrea.aime@anonymised.com>
wrote:

On Tue, Jun 17, 2014 at 6:31 PM, Justin Deoliveira <
jdeolive@anonymised.com> wrote:

I configured all the geotools/geoserver/geowebcache/etc... jobs on the
build server to ensure that none of them run in parallel (using the jenkins
lockes and latches plugin). It could be that i missed a combination. Do you
know what builds specifically were running in parallel?

I saw geoserver 2.5.x and master run toghether. The file I was talking
about is shared among versions of the same artifact (it's in the folder
that contains all the versions of the artifact as subfolders).

Ok, looks like I missed a bit of config on geoserver-master to attached it
to the same lock. Fixed now.

Cheers
Andrea

--

GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

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

--
*Justin Deoliveira*
Vice President, Engineering | Boundless
jdeolive@anonymised.com
@j_deolive <https://twitter.com/j_deolive&gt;