Project

General

Profile

Actions

Task #194

closed

Connector bundles are not found in tests

Added by Radek Tomiška over 7 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Vít Švanda
Category:
Provisioning
Target version:
Start date:
11/17/2016
Due date:
% Done:

100%

Estimated time:
4.00 h
Owner:

Description

When tests on acc module are ran from eclipse, then everything works fine. But when they are ran from command line (e.g. on jenkins), then connector bundle (for basic table connector) can not be found - maybe some classpath issue in test context?

...
testCreateConnectorConfiguration(eu.bcvsolutions.idm.acc.service.DefaultSysSystemServiceTest)  Time elapsed: 0.845 sec  <<< ERROR!
java.lang.IllegalStateException: Connector with key [connId:net.tirasa.connid.bundles.db.table.DatabaseTableConnector:net.tirasa.connid.bundles.db.table:2.2.4] was not found on classpath.
    at eu.bcvsolutions.idm.acc.service.impl.DefaultSysSystemService.createConnectorFormDefinition(DefaultSysSystemService.java:285)
    at eu.bcvsolutions.idm.acc.service.impl.DefaultSysSystemService.getConnectorFormDefinition(DefaultSysSystemService.java:270)
...
Actions #1

Updated by Vít Švanda over 7 years ago

  • Status changed from New to In Progress
Actions #2

Updated by Vít Švanda over 7 years ago

  • Subject changed from Connertor bundles are not found in tests to Connector bundles are not found in tests
  • Status changed from In Progress to Needs feedback
  • Assignee changed from Vít Švanda to Radek Tomiška

Problem was in Reflection util. Same issue is in http://stackoverflow.com/questions/18191869/reflections-including-classes-outside-the-given-package-dropwizard-swagger.
- I found solution. Reflection util must have defined source package where will search.
- I added new property file to ICF module, where is possible define packages for search local connectors.
- Local build (with tests) via mvn is working for now.

Actions #3

Updated by Radek Tomiška over 7 years ago

  • Status changed from Needs feedback to Closed
  • Assignee changed from Radek Tomiška to Vít Švanda
  • % Done changed from 0 to 100

It works smoothly, awesome!

Actions

Also available in: Atom PDF