On 10/12/2012 19:05, Christian Schneider wrote:
Hi all,
I wanted to report about my progress of trying the CXF libraries (2.7.0) in
syncope. The idea is to test if we can have the cxf libs and spring webservices
at the same time. If this works we can do the migration to cxf in several
steps. If it does not work we have to do all in one go.
I added the cxf libraries below to syncope-core. At first I had a lot of test
failures until Jan hinted that the cxf libraries probably collide with the libs
of the soap connector.
So I removed the cxf libs from the lib directory of the soap connector.
After this change I had all tests except for
org.apache.syncope.core.rest.TaskTestITCase.sync() working. Does anyone know
what this test does exactly. I already understood that it uses a csv table and
a user template to kind of postprocess users. As it fails after adding the cxf
deps I assume it also does a webservice call. Can
someone give me a hint where to dig?
Basically, TaskTestITCase.sync() is testing various aspects involved
with synchronization from external resources, here's why it seems so
complex.
About the involvement of the soap connector, you can read from test
context.xml that the role 8 has the 'ws-target-resource' assigned (and
such resource has an instance of the soap connector).
Since, in the test above, role 8 is assigned to the user template, every
synchronized user will get membership of role 8, and thus it will be
selected for propagation to ws-target-resource via the soap connector.
So assumed I get this last test working the problem with the soap connector
still remains. The way I simply removed the libs is of course just a test to
see if it works. We still have to find a proper solution
for this.
One possibility is to update the soap connector to the current cxf version.
This will probably work until we upgrade the cxf version again.
Hum, I don't see this as a viable option. As you are already pointing
out, we will be forced to keep in sync such dependencies in two separate
projects.
Another possibility would be to remove the libs from the connector and rely on
people adding the libs in another way. As far as I understood the idea of the
connectors is that they simply work without additional
libs so I am not sure if this is an option. I also do not yet understand how
the classloading in the connectors works. Can someone explain this?
More info about this:
https://code.google.com/p/connid/wiki/ConnectorBundles#Class_Loading
There could be some issue in the way how Syncope is managing the
ConnectorFacade via the ConnectorFacadeProxy (in ConnInstanceLoader /
ConnBundleManager).
<dependency>
<groupId>org.codehaus.jettison</groupId>
<artifactId>jettison</artifactId>
<version>1.3.2</version>
</dependency>
Being CXF an ASF project it does not cause any issue, but if you are
adding any extra non-ASF dependency, please take also care of LICENSE
and NOTICE content either at root (included in source and JAR releases)
and under legal_ext (for WAR and ZIP releases).
Regards.
--
Francesco Chicchiriccò
ASF Member, Apache Syncope PMC chair, Apache Cocoon PMC Member
http://people.apache.org/~ilgrosso/