merge from trunk
authorCherian Mathew <c.mathew@bgbm.org>
Wed, 28 Jan 2015 13:26:36 +0000 (13:26 +0000)
committerCherian Mathew <c.mathew@bgbm.org>
Wed, 28 Jan 2015 13:26:36 +0000 (13:26 +0000)
1  2 
.gitattributes
eu.etaxonomy.taxeditor.cdmlib/.classpath
eu.etaxonomy.taxeditor.cdmlib/META-INF/MANIFEST.MF
eu.etaxonomy.taxeditor.cdmlib/build.properties
eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CdmTransientEntityCacher.java
eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/service/CdmServiceRequestExecutor.java
eu.etaxonomy.taxeditor.cdmlib/src/main/resources/etc/jetty/cdmlib-remote-webapp.war
eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/httpInvokerServiceClients.xml
eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/BaseRemotingTest.java
eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/HttpInvokerServicesTest.java

diff --combined .gitattributes
index 067401bb3c34de55260a48764d8798cdb201dd01,95a3ad7ce836e1860c308e63e7724a6f912f3a98..f16fd9a250b00e8bbf83ba4e6ebc7ebe68bec4fa
@@@ -302,6 -302,7 +302,7 @@@ eu.etaxonomy.taxeditor.cdmlib/lib/sprin
  eu.etaxonomy.taxeditor.cdmlib/lib/spring-security-remoting-3.1.3.RELEASE.jar -text
  eu.etaxonomy.taxeditor.cdmlib/lib/stax-1.2.0.jar -text
  eu.etaxonomy.taxeditor.cdmlib/lib/stax-api-1.0.1.jar -text
+ eu.etaxonomy.taxeditor.cdmlib/lib/swagger-annotations-1.3.5.jar -text
  eu.etaxonomy.taxeditor.cdmlib/lib/unitils-core-3.3.jar -text
  eu.etaxonomy.taxeditor.cdmlib/lib/unitils-database-3.3.jar -text
  eu.etaxonomy.taxeditor.cdmlib/lib/unitils-dbmaintainer-3.3.jar -text
@@@ -333,51 -334,22 +334,51 @@@ eu.etaxonomy.taxeditor.cdmlib/lib/yjp-c
  eu.etaxonomy.taxeditor.cdmlib/pom.xml -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/api/application/CdmApplicationRemoteConfiguration.java -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/api/application/CdmApplicationRemoteController.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/api/application/RemotingMonitoredGenericApplicationContext.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/api/application/RemotingMonitoredListableBeanFactory.java -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/api/cache/CdmServiceCacher.java -text
 -eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/api/lazyloading/CdmLazyLoader.java -text
 -eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/remote/CdmPersistentRemoteSource.java -text
 -eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/remote/CdmRemoteSource.java -text
 -eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/remote/CdmRemoteSourceBase.java -text
 -eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/remote/CdmRemoteSourceException.java -text
 -eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/cdm/remote/ICdmRemoteSource.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/CdmEagerLoadingException.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/CdmRemotingException.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CachedCommonServiceImpl.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CdmClientCacheException.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CdmEntityCacheKey.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CdmModelCacher.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CdmModelFieldPropertyFromClass.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CdmRemoteCacheManager.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CdmTransientEntityCacher.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/ICachedCommonService.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/server/CDMServerException.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/source/CdmPersistentRemoteSource.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/source/CdmRemoteSource.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/source/CdmRemoteSourceBase.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/source/CdmRemoteSourceException.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/source/CdmServerInfo.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/source/ICdmRemoteSource.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/service/CdmServiceInterceptorException.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/service/CdmServiceRequestExecutor.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/service/TermServiceRequestExecutor.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/session/CdmClientSessionException.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/session/CdmEntitySession.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/session/CdmEntitySessionManager.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/session/ICdmEntitySession.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/session/ICdmEntitySessionManager.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/session/ISessionEventListener.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/session/mock/MockCdmEntitySessionManager.java -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/java/org/hibernate/collection/internal/AbstractPersistentCollection.java -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/java/org/hibernate/proxy/AbstractLazyInitializer.java -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/resources/cdmlib-ehcache.xml -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/resources/etc/jetty/.svnignore -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/resources/etc/jetty/cdmlib-remote-webapp.war -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/resources/etc/jetty/jetty-runner-9.2.3.v20140905.jar -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/resources/etc/jetty/start-9.2.3.v20140905.jar -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/config.properties -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/httpInvokerServiceClients.xml -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/localApplicationContext.xml -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/mappings/hibernate.cfg.xml -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/remotingApplicationContext.xml -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/remoting_persistence_security.xml -text
  eu.etaxonomy.taxeditor.cdmlib/src/main/resources/eu/etaxonomy/cdm/remoting_services_security.xml -text
 -eu.etaxonomy.taxeditor.cdmlib/src/test/resources/eu/etaxonomy/cdm/datasources/cdm.datasources.xml -text
 +eu.etaxonomy.taxeditor.cdmlib/src/main/resources/log4j.properties -text
  eu.etaxonomy.taxeditor.editor/.classpath -text
  eu.etaxonomy.taxeditor.editor/.project -text
  eu.etaxonomy.taxeditor.editor/META-INF/MANIFEST.MF -text
@@@ -1009,6 -981,7 +1010,7 @@@ eu.etaxonomy.taxeditor.navigation/src/m
  eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/CopyHandler.java -text
  eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/DeleteHandler.java -text
  eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/EditHandler.java -text
+ eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/MoveFactualDataHandler.java -text
  eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/MoveTaxonHandler.java -text
  eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/NewClassificationHandler.java -text
  eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/handler/NewTaxonNodeHandler.java -text
@@@ -1278,7 -1251,6 +1280,7 @@@ eu.etaxonomy.taxeditor.store/src/main/j
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/handler/OpenDistributionEditorWizardHandler.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/handler/OpenPasswordWizzardHandler.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/handler/ShowLoginWindowHandler.java -text
 +eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/handler/ShowRemotingLoginWindowHandler.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/identificationkey/AbstractIdentificaitonKeyWizard.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/io/AbstractIOManager.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/io/ExportManager.java -text
@@@ -1439,7 -1411,6 +1441,7 @@@ eu.etaxonomy.taxeditor.store/src/main/j
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/combo/TermComboElement.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/DefaultLanguageDialog.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/LoginDialog.java -text
 +eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/RemotingLoginDialog.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/UriDialog.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/selection/AbstractFilteredCdmEnumSelectionDialog.java -text
  eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/selection/AbstractFilteredCdmResourceSelectionDialog.java -text
@@@ -1847,49 -1818,13 +1849,49 @@@ eu.etaxonomy.taxeditor.test/META-INF/MA
  eu.etaxonomy.taxeditor.test/build.properties -text
  eu.etaxonomy.taxeditor.test/ide/eclipse/EDITor[!!-~]Tests.launch -text
  eu.etaxonomy.taxeditor.test/pom.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/cdmlib-ehcache.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/datasources.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/eu/etaxonomy/cdm/api/cache/CdmClientCachingTest.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/eu/etaxonomy/cdm/cdm.datasources.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/eu/etaxonomy/cdm/polytomouskey/PolytomousKeyTest.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/eu/etaxonomy/cdm/testRemotingApplicationContext.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/eu/etaxonomy/taxeditor/lazyloading/AbstractLazyInitializerTest.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/eu/etaxonomy/taxeditor/lazyloading/CdmEntityCacherTest.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/eu/etaxonomy/taxeditor/remoting/session/CdmEntitySessionManagerTest.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/h2/cdmTest.h2.db -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/h2/cdmTest.trace.db -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/log4j.properties -text
  eu.etaxonomy.taxeditor.test/src/main/resources/log4j.xml -text
 +eu.etaxonomy.taxeditor.test/src/main/resources/unitils.properties -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/cdm/api/cache/CdmClientCachingTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/cdm/api/cache/CdmModelGetMethodCacherTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/cdm/polytomouskey/PolytomousKeyTest.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/application/menu/general/NewMenuTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/BaseRemotingTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/CDMServer.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/CdmPersistentRemoteSourceTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/CdmRemoteSourceTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/CdmServerTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/CdmServerTestManager.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/HttpInvokerServicesTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/lazyloading/AbstractLazyInitializerTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/lazyloading/CdmEntityCacherTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/lazyloading/CdmServiceCacherTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/lazyloading/RemoteLazyLoadingTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/lazyloading/RemotePersistentCollectionTest.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/navigation/navigator/contextmenu/ClassificationTest.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/newWizard/NewTaxonWizardTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/service/ITestService.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/service/ServiceInterceptorTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/service/ServiceRebasingTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/service/TargetTestService.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/service/TestService.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/session/CdmEntitySessionManagerTest.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/session/MockSessionOwner.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/test/AbstractEditorTest.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/test/ContextMenuHelper.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/test/SwtBotUtils.java -text
 +eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/ui/dialogs/CdmServerInfoTest.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/ui/dialogs/LoginDialogTest.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/ui/selection/AbstractSelectionElementTest.java -text
  eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/ui/selection/ClassificationSelectionElementTest.java -text
index 42b8f157a620b8191d31257a365d06d434b53052,2cc9dede15dde187a6a1e10e15c6b450c1fc5311..5a63729cd371f2f5825c5c05cf67baf7524ddf1d
@@@ -2,8 -2,10 +2,8 @@@
  <classpath>
        <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
        <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
 -      <classpathentry kind="src" path="src/main/java"/>
 -      <classpathentry kind="src" path="src/test/java"/>
 -      <classpathentry kind="src" path="src/main/resources"/>
 -      <classpathentry kind="src" path="src/test/resources"/>
 +      <classpathentry including="**/*.java" kind="src" path="src/main/java"/>
 +      <classpathentry excluding="**/*.java" kind="src" path="src/main/resources"/>
        <classpathentry exported="true" kind="lib" path="lib/activation-1.1.1.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/antlr-2.7.7.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/aopalliance-1.0.jar"/>
@@@ -58,7 -60,7 +58,7 @@@
        <classpathentry exported="true" kind="lib" path="lib/hibernate-c3p0-4.1.10.Final.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/hibernate-cglib-repack-2.1_3.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/hibernate-commons-annotations-4.0.1.Final.jar"/>
 -      <classpathentry exported="true" kind="lib" path="lib/hibernate-core-4.1.10.Final.jar"/>
 +      <classpathentry exported="true" kind="lib" path="lib/hibernate-core-4.1.10.Final.jar" sourcepath="/home/cmathew/.m2/repository/org/hibernate/hibernate-core/4.1.10.Final/hibernate-core-4.1.10.Final-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/hibernate-ehcache-4.1.10.Final.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/hibernate-entitymanager-4.1.10.Final.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/hibernate-envers-4.1.10.Final.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/org.springframework.oxm-3.2.2.RELEASE.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/org.springframework.test-3.2.2.RELEASE.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/org.springframework.transaction-3.2.2.RELEASE.jar" sourcepath="lib/org.springframework.transaction-3.2.2.RELEASE-sources.jar"/>
--      <classpathentry exported="true" kind="lib" path="lib/org.springframework.web-3.2.2.RELEASE.jar"/>
++      <classpathentry exported="true" kind="lib" path="lib/org.springframework.web-3.2.2.RELEASE.jar" sourcepath="/home/cmathew/.m2/repository/org/springframework/org.springframework.web/3.2.2.RELEASE/org.springframework.web-3.2.2.RELEASE-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/org.springframework.web.servlet-3.2.2.RELEASE.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/osgi-3.6.0.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/p6spy-1.3.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/spring-expression-3.2.2.RELEASE.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/spring-modules-cache-0.7.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/spring-security-config-3.1.3.RELEASE.jar"/>
--      <classpathentry exported="true" kind="lib" path="lib/spring-security-core-3.1.3.RELEASE.jar"/>
++      <classpathentry exported="true" kind="lib" path="lib/spring-security-core-3.1.3.RELEASE.jar" sourcepath="/home/cmathew/.m2/repository/org/springframework/security/spring-security-core/3.1.3.RELEASE/spring-security-core-3.1.3.RELEASE-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/stax-1.2.0.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/stax-api-1.0.1.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/unitils-core-3.3.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/spring-security-remoting-3.1.3.RELEASE.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/jena-core-2.11.2.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/jena-iri-1.0.2.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-commons-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-commons-3.4.1-SNAPSHOT.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-ext-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-ext-3.4.1-SNAPSHOT.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-io-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-io-3.4.1-SNAPSHOT.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-model-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-model-3.4.1-SNAPSHOT.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-persistence-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-persistence-3.4.1-SNAPSHOT.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-print-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-print-3.4.1-SNAPSHOT.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-remote-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-remote-3.4.1-SNAPSHOT.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/cdmlib-services-3.4.1-SNAPSHOT-sources.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/cdmlib-services-3.4.1-SNAPSHOT.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/poi-3.10-FINAL.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/poi-ooxml-3.10-FINAL.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/xmlbeans-2.3.0.jar"/>
        <classpathentry exported="true" kind="lib" path="lib/poi-ooxml-schemas-3.10-FINAL.jar"/>
+       <classpathentry exported="true" kind="lib" path="lib/swagger-annotations-1.3.5.jar"/>
        <classpathentry kind="output" path="target/classes"/>
  </classpath>
index dcc354f5207dc7c9e055746920d219985846e8cd,08ab4e5be42e7662e62ec5f201c5869a5ac86162..7647cd210e43ff58382cfa4775404f647a09d4a8
@@@ -8,9 -8,9 +8,9 @@@ Export-Package: com.google.api
   com.google.api.detect,
   com.google.api.translate,
   eu.etaxonomy.cdm.api.application,
 + eu.etaxonomy.cdm.api.cache,
   eu.etaxonomy.cdm.api.conversation,
   eu.etaxonomy.cdm.api.facade,
 - eu.etaxonomy.cdm.api.lazyloading,
   eu.etaxonomy.cdm.api.service,
   eu.etaxonomy.cdm.api.service.config,
   eu.etaxonomy.cdm.api.service.description,
   eu.etaxonomy.cdm.persistence.dao.hibernate.occurrence,
   eu.etaxonomy.cdm.persistence.dao.hibernate.reference,
   eu.etaxonomy.cdm.persistence.dao.hibernate.taxon,
 - eu.etaxonomy.cdm.persistence.dao.hibernate.validation,
   eu.etaxonomy.cdm.persistence.dao.hibernate.view,
   eu.etaxonomy.cdm.persistence.dao.media,
   eu.etaxonomy.cdm.persistence.dao.name,
   eu.etaxonomy.cdm.persistence.dao.occurrence,
   eu.etaxonomy.cdm.persistence.dao.reference,
   eu.etaxonomy.cdm.persistence.dao.taxon,
 - eu.etaxonomy.cdm.persistence.dao.validation,
   eu.etaxonomy.cdm.persistence.fetch,
   eu.etaxonomy.cdm.persistence.hibernate,
   eu.etaxonomy.cdm.persistence.hibernate.permission,
   eu.etaxonomy.cdm.print.out.pdf,
   eu.etaxonomy.cdm.print.out.taxpub,
   eu.etaxonomy.cdm.print.out.xml,
 - eu.etaxonomy.cdm.remote,
   eu.etaxonomy.cdm.remote.config,
   eu.etaxonomy.cdm.remote.controller,
   eu.etaxonomy.cdm.remote.controller.dto,
   eu.etaxonomy.cdm.validation.annotation,
   eu.etaxonomy.cdm.validation.constraint,
   eu.etaxonomy.remote.dto.rdf,
 + eu.etaxonomy.taxeditor.remoting.cache,
 + eu.etaxonomy.taxeditor.remoting.server,
 + eu.etaxonomy.taxeditor.remoting.source,
 + eu.etaxonomy.taxeditor.session,
 + eu.etaxonomy.taxeditor.session.mock,
 + javassist.util.proxy,
   javax.persistence,
   junit.framework;uses:="org.junit.runner.manipulation,org.junit.runner,org.junit.runner.notification",
 + net.sf.ehcache,
 + net.sf.ehcache.config,
 + net.sf.ehcache.store,
   net.sf.json;uses:="net.sf.json.processors,net.sf.json.util,org.apache.commons.lang.exception",
   org.apache.commons.collections;uses:="org.apache.commons.collections.keyvalue,new org.apache.commons.collections",
   org.apache.commons.io;uses:="org.apache.commons.io.filefilter",
   org.apache.fop.apps,
   org.apache.http,
   org.apache.http.client,
-  org.apache.http.client.methods,
 + org.apache.http.util,
   org.apache.log4j;uses:="org.apache.log4j.helpers,org.apache.log4j.or,org.apache.log4j.spi",
   org.apache.log4j.chainsaw;
    uses:="org.apache.log4j,
   org.hibernate,
   org.hibernate.annotations.common.reflection,
   org.hibernate.cache.internal,
 + org.hibernate.cfg,
   org.hibernate.classic,
   org.hibernate.collection.internal,
 + org.hibernate.collection.spi,
   org.hibernate.criterion,
 + org.hibernate.engine.internal,
 + org.hibernate.engine.spi,
 + org.hibernate.engine.transaction.spi,
   org.hibernate.envers.query.criteria,
 + org.hibernate.internal,
 + org.hibernate.internal.util,
 + org.hibernate.internal.util.collections,
 + org.hibernate.mapping,
 + org.hibernate.persister.collection,
 + org.hibernate.persister.entity,
 + org.hibernate.pretty,
 + org.hibernate.property,
   org.hibernate.proxy,
 + org.hibernate.proxy.pojo.javassist,
   org.hibernate.search,
   org.hibernate.search.spatial.impl,
 + org.hibernate.type,
   org.jadira.usertype.dateandtime.joda,
   org.jadira.usertype.dateandtime.shared.spi,
   org.jboss.logging,
   org.joda.time.format;uses:="org.joda.time",
   org.joda.time.tz;uses:="org.joda.time",
   org.junit;uses:="org.hamcrest",
 + org.junit.runner,
   org.odftoolkit.odfdom,
   org.odftoolkit.odfdom.doc,
   org.odftoolkit.odfdom.doc.office,
   org.odftoolkit.odfdom.dom.element,
   org.odftoolkit.odfdom.dom.element.style,
   org.odftoolkit.odfdom.dom.style,
 + org.springframework.beans,
   org.springframework.beans.factory,
   org.springframework.beans.factory.annotation;
    uses:="org.apache.commons.logging,
     org.springframework.beans.factory.wiring,
     org.springframework.core.type,
     org.springframework.beans.factory",
 + org.springframework.beans.factory.config,
 + org.springframework.beans.factory.support,
 + org.springframework.beans.factory.xml,
   org.springframework.cache.ehcache,
   org.springframework.context;
    uses:="org.springframework.core.io,
     org.aopalliance.intercept,
     org.springframework.context,
     org.springframework.beans.factory",
 + org.springframework.context.support,
   org.springframework.core;uses:="org.springframework.util",
 + org.springframework.core.env,
   org.springframework.core.io;uses:="org.jboss.virtual",
 + org.springframework.core.io.support,
   org.springframework.core.type.classreading,
   org.springframework.orm.hibernate3;
    uses:="org.apache.commons.logging,
     org.springframework.dao,
     org.springframework.transaction.support",
   org.springframework.orm.hibernate4,
 + org.springframework.remoting,
 + org.springframework.remoting.httpinvoker,
 + org.springframework.remoting.support,
   org.springframework.security.access,
   org.springframework.security.authentication,
   org.springframework.security.authentication.event,
     org.springframework.transaction,
     org.apache.commons.logging,
     org.springframework.beans.factory",
 + org.springframework.util,
   org.springframework.web.servlet;
    uses:="org.springframework.web.multipart,
     org.apache.commons.logging,
     org.springframework.context.event,
     javax.servlet,
     org.springframework.ui,
 -   javax.servlet.http"
 +   javax.servlet.http",
 + org.unitils,
 + org.unitils.database,
 + org.unitils.database.annotations,
 + org.unitils.database.util,
 + org.unitils.dbunit.annotation,
 + org.unitils.spring.annotation
  Bundle-Vendor: EDIT
  Bundle-RequiredExecutionEnvironment: JavaSE-1.6
  Require-Bundle: org.eclipse.osgi,
-- org.eclipse.equinox.common
++ org.eclipse.equinox.common,
++ org.apache.commons.httpclient;bundle-version="3.1.0"
  Bundle-ClassPath: .,
   lib/activation-1.1.1.jar,
   lib/antlr-2.7.7.jar,
   lib/poi-3.10-FINAL.jar,
   lib/poi-ooxml-3.10-FINAL.jar,
   lib/xmlbeans-2.3.0.jar,
-  lib/poi-ooxml-schemas-3.10-FINAL.jar
+  lib/poi-ooxml-schemas-3.10-FINAL.jar,
+  lib/swagger-annotations-1.3.5.jar
 -Import-Package: eu.etaxonomy.cdm.api.application
++Import-Package: org.apache.commons.httpclient.methods
index f1e77063eb9b35e474c7dc0a7e027a5aec4ab5cf,89809ef1e9db65bde04e5adc7f8d532a4365eb84..23f98c039f57239e3ec9177c32d9c013a71977c6
@@@ -208,11 -208,13 +208,12 @@@ bin.includes = META-INF/,
                 lib/cdmlib-remote-3.4.1-SNAPSHOT-sources.jar,\\r
                 lib/cdmlib-remote-3.4.1-SNAPSHOT.jar,\\r
                 lib/cdmlib-services-3.4.1-SNAPSHOT-sources.jar,\\r
-                lib/cdmlib-services-3.4.1-SNAPSHOT.jar\r
+                lib/cdmlib-services-3.4.1-SNAPSHOT.jar,\\r
+                lib/swagger-annotations-1.3.5.jar\r
  \r
  jars.compile.order = .\r
  output.. = bin/\r
  source.. = src/main/java/,\\r
 -           src/main/resources/,\\r
 -           src/test/java/\r
 +           src/main/resources/\r
  src.includes = src/\r
  \r
index e182787806c87fc8fdce2319e61ca23614039beb,0000000000000000000000000000000000000000..b3fe25e887861970704016840de7e493c116b20e
mode 100644,000000..100644
--- /dev/null
@@@ -1,497 -1,0 +1,502 @@@
 +// $Id$
 +/**
 + * Copyright (C) 2014 EDIT
 + * European Distributed Institute of Taxonomy
 + * http://www.e-taxonomy.eu
 + *
 + * The contents of this file are subject to the Mozilla Public License Version 1.1
 + * See LICENSE.TXT at the top of this package for the full license terms.
 + */
 +package eu.etaxonomy.taxeditor.remoting.cache;
 +
 +import java.lang.reflect.Field;
 +import java.util.ArrayList;
 +import java.util.Collection;
 +import java.util.HashSet;
 +import java.util.Iterator;
 +import java.util.List;
 +import java.util.Map;
 +import java.util.Set;
 +
 +import javassist.util.proxy.ProxyFactory;
 +import net.sf.ehcache.Cache;
 +import net.sf.ehcache.Element;
 +import net.sf.ehcache.config.CacheConfiguration;
 +import net.sf.ehcache.store.MemoryStoreEvictionPolicy;
 +
 +import org.apache.log4j.Logger;
 +import org.hibernate.collection.spi.PersistentCollection;
 +import org.springframework.util.ReflectionUtils;
 +
 +import eu.etaxonomy.cdm.api.cache.CdmServiceCacher;
 +import eu.etaxonomy.cdm.model.common.CdmBase;
 +import eu.etaxonomy.taxeditor.session.ICdmEntitySessionManager;
 +
 +/**
 + *
 + * This cache guarantees that
 + *  - all objects put will be ancestors of CdmBase
 + *  - all CdmBase objects in the cache will be already de-proxied
 + *  - after any CdmBase object is put in the cache,
 + *  all non-null / non-proxy CdmBase objects in the sub-graph
 + *  will also be present in the cache.
 + *
 + * @author cmathew
 + * @date 14 Oct 2014
 + *
 + */
 +
 +public class CdmTransientEntityCacher  {
 +
 +      private static final Logger logger = Logger.getLogger(CdmTransientEntityCacher.class);
 +
 +
 +    private ICdmEntitySessionManager cdmEntitySessionManager;
 +
 +      private static CdmServiceCacher cdmServiceCacher;
 +
 +      private String cacheId;
 +
 +      private Cache cache;
 +
 +      private Cache cdmlibModelCache;
 +
 +      private static boolean isRecursiveEnabled = true;
 +
 +    public static enum CollectionType {
 +        SET,
 +        LIST,
 +        MAP;
 +
 +        @Override
 +        public String toString() {
 +            return this.name().toLowerCase();
 +        }
 +    }
 +
 +      private CdmTransientEntityCacher() {
 +
 +      }
 +
 +      public CdmTransientEntityCacher(String cacheId, ICdmEntitySessionManager cdmEntitySessionManager) {
 +              this.cacheId = cacheId;
 +
 +              cache = new Cache(getEntityCacheConfiguration(cacheId));
 +              cdmServiceCacher.getDefaultCacheManager().addCache(cache);
 +
 +              cdmlibModelCache = CdmRemoteCacheManager.getInstance().getCdmModelGetMethodsCache();
 +              this.cdmEntitySessionManager = cdmEntitySessionManager;
 +      }
 +
 +      public CdmTransientEntityCacher(Object obj, ICdmEntitySessionManager cdmEntitySessionManager) {
 +              this(obj.getClass().getName() +  String.valueOf(obj.hashCode()), cdmEntitySessionManager);
 +      }
 +
 +      /**
 +       * Returns the default cache configuration.
 +       *
 +       * @return
 +       */
 +      private CacheConfiguration getEntityCacheConfiguration(String cacheId) {
 +              // For a better understanding on how to size caches, refer to
 +              // http://ehcache.org/documentation/configuration/cache-size
 +              return new CacheConfiguration(cacheId, 500)
 +              .memoryStoreEvictionPolicy(MemoryStoreEvictionPolicy.LFU)
 +              .eternal(false)
 +              // default ttl and tti set to 2 hours
 +              .timeToLiveSeconds(60*60*2)
 +              .timeToIdleSeconds(60*60*2);
 +
 +      }
 +
 +      public static void setDefaultCacher(CdmServiceCacher css) {
 +              cdmServiceCacher = css;
 +      }
 +
 +      /**
 +       * Returns the cache corresponding to the cache id
 +       *
 +       * @param cacheId
 +       * @return
 +       */
 +      private Cache getCache() {
 +              return cdmServiceCacher.getDefaultCacheManager().getCache(cacheId);
 +      }
 +
 +      @SuppressWarnings("unchecked")
 +      public <T extends Object> T load(T obj, boolean recursive) {
 +              if(obj instanceof CdmBase) {
 +                      return load(obj, recursive);
 +              } else if (obj instanceof Map) {
 +                      return (T) load((Map<T,T>)obj, recursive);
 +              } else if (obj instanceof Collection) {
 +                      return (T) load((Collection<T>)obj, recursive);
 +              }
 +
 +              return obj;
 +      }
 +
 +      @SuppressWarnings("unchecked")
 +      private <T extends Object> T loadRecursive(T obj, Set<CdmBase> alreadyVisitedEntities) {
 +              if(obj instanceof CdmBase) {
 +                      return (T) loadRecursive((CdmBase)obj, alreadyVisitedEntities);
 +              } else if (obj instanceof Map) {
 +                      return (T) load((Map<T,T>)obj, alreadyVisitedEntities);
 +              } else if (obj instanceof Collection) {
 +                      return (T) load((Collection<T>)obj, alreadyVisitedEntities);
 +              }
 +
 +              logger.info("No caching yet for type " + obj.getClass().getName());
 +
 +              return obj;
 +      }
 +
 +      public <T extends Object> Map<T,T> load(Map<T,T> map, boolean recursive){
 +              if(isRecursiveEnabled && recursive) {
 +                      logger.info("---- starting recursive load for cdm entity map");
 +                      Set<CdmBase> alreadyVisitedEntities = new HashSet<CdmBase>();
 +                      Map<T,T> cachedMap = load(map, alreadyVisitedEntities);
 +                      alreadyVisitedEntities.clear();
 +                      logger.info("---- ending recursive load for cdm entity map \n");
 +                      return cachedMap;
 +              } else {
 +                      return load(map, null);
 +              }
 +      }
 +
 +
 +      private <T extends Object> Map<T,T> load(Map<T,T> map, Set<CdmBase> alreadyVisitedEntities){
 +        if(map == null || map.isEmpty()) {
 +            return map;
 +        }
 +
 +        int originalMapSize = map.size();
 +        Object[] result = new Object[ map.size() * 2 ];
 +        Iterator<Map.Entry<T,T>> iter = map.entrySet().iterator();
 +        int i=0;
 +        while ( iter.hasNext() ) {
 +            Map.Entry<T,T> e = iter.next();
 +            result[i++] = e.getKey();
 +            result[i++] = e.getValue();
 +        }
 +
 +        for(i=0; i<result.length;i++) {
 +              if(alreadyVisitedEntities == null) {
 +                      result[i] = load(result[i], false);
 +              } else {
 +                      result[i] = loadRecursive(result[i], alreadyVisitedEntities);
 +              }
 +        }
 +        map.clear();
 +        for(i = 0; i < originalMapSize; i+=2 ) {
 +            map.put(
 +                    (T)result[i],
 +                    (T)result[i+1]
 +                );
 +        }
 +        return map;
 +      }
 +
 +      public <T extends Object> Collection<T> load(Collection<T> collection, boolean recursive){
 +              Collection<T> loadedCollection;
 +              if(isRecursiveEnabled && recursive) {
 +                      logger.info("---- starting recursive load for cdm entity collection");
 +                      Set<CdmBase> alreadyVisitedEntities = new HashSet<CdmBase>();
 +                      Collection<T> cachedCollection = load(collection, alreadyVisitedEntities);
 +                      alreadyVisitedEntities.clear();
 +                      logger.info("---- ending recursive load for cdm entity collection \n");
 +                      loadedCollection = cachedCollection;
 +              } else {
 +                      loadedCollection = load(collection, null);
 +              }
 +              return loadedCollection;
 +      }
 +
 +      @SuppressWarnings("unchecked")
 +      private <T extends Object> Collection<T> load(Collection<T> collection, Set<CdmBase> alreadyVisitedEntities){
 +              int length = collection.size();
 +              Object[] result = new Object[length];
 +              Iterator<T> collectionItr = collection.iterator();
 +              int count = 0;
 +              while(collectionItr.hasNext()) {
 +                      if(alreadyVisitedEntities == null) {
 +                      result[count] = load(collectionItr.next(), false);
 +              } else {
 +                      result[count] = loadRecursive(collectionItr.next(), alreadyVisitedEntities);
 +              }
 +                      count++;
 +              }
 +
 +              collection.clear();
 +
 +              for ( int i = 0; i < length; i++ ) {
 +                      collection.add((T)result[i]);
 +              }
 +
 +              return collection;
 +      }
 +
 +
 +      /**
 +       * Puts the (Key,Value) pair of ({@link java.util.UUID}, {@link eu.etaxonomy.cdm.model.common.CdmBase}),
 +       * in the cache corresponding to the given cache id
 +       *
 +       * @param cacheId
 +       * @param uuid
 +       * @param cdmEntity
 +       */
 +      public CdmBase load(CdmBase cdmEntity, boolean recursive) {
 +              CdmBase loadedCdmBase;
 +              if(isRecursiveEnabled && recursive) {
 +                      logger.info("---- starting recursive load for cdm entity " + cdmEntity.getClass().getName() + " with id " + cdmEntity.getId());
 +                      Set<CdmBase> alreadyVisitedEntities = new HashSet<CdmBase>();
 +                      CdmBase cb =  loadRecursive(cdmEntity, alreadyVisitedEntities);
 +                      alreadyVisitedEntities.clear();
 +                      logger.info("---- ending recursive load for cdm entity " + cdmEntity.getClass().getName() + " with id " + cdmEntity.getId() + "\n");
 +                      loadedCdmBase =  cb;
 +              } else {
 +                      loadedCdmBase = load(cdmEntity);
 +              }
 +              return loadedCdmBase;
 +
 +      }
 +
 +
 +      private CdmBase load(CdmBase cdmEntity) {
 +              logger.info("loading object of type " + cdmEntity.getClass().getName() + " with id " + cdmEntity.getId());
 +
 +              // start by looking up the cdm entity in the cache
 +              CdmBase cachedCdmEntity = getFromCache(cdmEntity);
 +
 +              if(cachedCdmEntity != null) {
 +                      // if cdm entity was found in cache then return ...
 +                      logger.info(" - object of type " + cdmEntity.getClass().getName() + " with id " + cdmEntity.getId() + " already exists");
 +                      return cachedCdmEntity;
 +              } else {
 +                      // ... else save the entity in the cache
 +                      getCache().put(new Element(generateKey(cdmEntity), cdmEntity));
 +                      logger.info(" - object of type " + cdmEntity.getClass().getName() + " with id " + cdmEntity.getId() + " put in cache");
 +                      return cdmEntity;
 +              }
 +      }
 +
 +      private CdmBase loadRecursive(CdmBase cdmEntity, Set<CdmBase> alreadyVisitedEntities) {
 +
 +              CdmBase cachedCdmEntity = load(cdmEntity);
 +
 +              // we want to recursive through the cdmEntity (and not the cachedCdmEntity)
 +              // since there could be new initialized object in the cdmEntity sub-graph
 +
 +              // start by getting the fields from the cdm entity
 +              String className = cdmEntity.getClass().getName();
 +              CdmModelFieldPropertyFromClass cmgmfc = getFromCdmlibModelCache(className);
 +              if(cmgmfc != null) {
 +                      alreadyVisitedEntities.add(cdmEntity);
 +                      List<String> fields = cmgmfc.getFields();
 +                      for(String field : fields) {
 +                              // retrieve the actual object corresponding to the field.
 +                              // this object will be either a CdmBase or a Collection / Map
 +                              // with CdmBase as the generic type
 +
 +                              // In the case that the returned is either a Collection or a Map
 +                              // the individual objects inside these also need to be loaded
 +                              // by calling the corresponding cachify method in the
 +                              // CdmEntityCachingUtils
 +
 +                              CdmBase cdmEntityInSubGraph = getCdmBaseTypeFieldValue(cdmEntity, cachedCdmEntity, field, alreadyVisitedEntities);
 +                              if(cdmEntityInSubGraph != null) {
 +                                      if(!alreadyVisitedEntities.contains(cdmEntityInSubGraph)) {
 +                                              logger.info("recursive loading object of type " + cdmEntityInSubGraph.getClass().getName() + " with id " + cdmEntityInSubGraph.getId());
 +                                              loadRecursive(cdmEntityInSubGraph, alreadyVisitedEntities);
 +                                      } else {
 +                                              logger.info("object of type " + cdmEntityInSubGraph.getClass().getName() + " with id " + cdmEntityInSubGraph.getId() + "already visited");
 +                                      }
 +                              }
 +                      }
 +              } else {
 +                      throw new CdmClientCacheException("CdmEntity with class " + cdmEntity.getClass().getName() + " is not found in the cdmlib model cache. " +
 +                                      "The cache may be corrupted or not in sync with the latest model version" );
 +              }
 +              return cachedCdmEntity;
 +      }
 +
 +
 +      private CdmBase getCdmBaseTypeFieldValue(CdmBase cdmEntity,
 +                      CdmBase cachedCdmEntity,
 +                      String fieldName,
 +                      Set<CdmBase> alreadyVisitedEntities) {
 +
 +
 +              if(cachedCdmEntity == null) {
 +                      throw new CdmClientCacheException("When trying to set field value, the cached cdm entity cannot be null");
 +              }
 +
 +              Class<?> clazz = cdmEntity.getClass();
 +              try {
 +                      // this call will search in the provided class as well as
 +                      // the super classes until it finds the field
 +                      Field field = ReflectionUtils.findField(clazz, fieldName);
 +
 +                      if(field == null) {
 +                              throw new CdmClientCacheException("Field '" + fieldName
 +                                              + "' not found when searching in class '" + clazz.getName() + "' and its supercalsses");
 +                      }
 +                      field.setAccessible(true);
 +                      Object o = field.get(cdmEntity);
 +
++                      // in the case that we are (re) loading a cdm entity with a null (most probably deleted) field
++                      // we need to set the same field in the corresponding cached cdm entity to null
++                      if(o == null) {
++                          field.set(cachedCdmEntity, null);
++                      }
++
 +                      CdmBase cdmEntityInSubGraph = null;
 +                      if(o != null
 +                                      && !ProxyFactory.isProxyClass(o.getClass())
 +                                      && !(o instanceof PersistentCollection) ) {
 +
 +                              if(CdmBase.class.isAssignableFrom(o.getClass())) {
 +                                      logger.info("found initialised cdm entity '" + fieldName + "' in object of type " + clazz.getName() + " with id " + cdmEntity.getId());
 +                                      cdmEntityInSubGraph  = (CdmBase)o;
 +                                      CdmBase cachedCdmEntityInSubGraph = getFromCache(cdmEntityInSubGraph);
 +
 +                                      if(cachedCdmEntityInSubGraph != null) {
 +                                              if(cachedCdmEntityInSubGraph != cdmEntityInSubGraph) {
 +                                                      field.set(cachedCdmEntity, cachedCdmEntityInSubGraph);
 +                                              }
 +                                      } else {
 +                                              field.set(cachedCdmEntity, cdmEntityInSubGraph);
 +                                      }
 +                              } else if(o instanceof Map) {
 +                                      loadRecursive((Map)o, alreadyVisitedEntities);
 +                              } else if(o instanceof Collection) {
 +                                      loadRecursive((Collection)o, alreadyVisitedEntities);
 +                              }
 +                      }
 +                      // we return the original cdm entity in the sub graph because we
 +                      // want to continue to recurse on the input cdm entity graph
 +                      // and not the one in the cache
 +                      return cdmEntityInSubGraph;
 +              } catch (SecurityException e) {
 +                      throw new CdmClientCacheException(e);
 +              } catch (IllegalArgumentException e) {
 +                      throw new CdmClientCacheException(e);
 +              } catch (IllegalAccessException e) {
 +                      throw new CdmClientCacheException(e);
 +              }
 +      }
 +
 +      public void put(CdmBase cdmEntity) {
 +              CdmEntityCacheKey id = new CdmEntityCacheKey(cdmEntity);
 +              Element cachedCdmEntityElement = getCacheElement(id);
 +
 +              if(cachedCdmEntityElement == null) {
 +                      cachedCdmEntityElement = cdmServiceCacher.getCacheElement(cdmEntity.getUuid());
 +                      if(cachedCdmEntityElement != null) {
 +                              logger.info("Cdm Entity with id : " + cdmEntity.getId() + " already exists in permanent cache. Ignoring put.");
 +                              return;
 +                      }
 +              }
 +
 +              getCache().put(new Element(id, cdmEntity));
 +      }
 +
 +
 +      private Element getCacheElement(CdmEntityCacheKey key) {
 +              return getCache().get(key);
 +      }
 +
 +      public CdmModelFieldPropertyFromClass getFromCdmlibModelCache(String className) {
 +              Element e = cdmlibModelCache.get(className);
 +              if (e == null) {
 +                      return null;
 +              } else {
 +                      return (CdmModelFieldPropertyFromClass) e.getObjectValue();
 +              }
 +      }
 +
 +      public CdmBase getFromCache(CdmEntityCacheKey id) {
 +              Element e = getCacheElement(id);
 +              if (e == null) {
 +                      return null;
 +              } else {
 +                      return (CdmBase) e.getObjectValue();
 +              }
 +      }
 +
 +      public CdmBase getFromCache(Class<? extends CdmBase> clazz, int id) {
 +              CdmEntityCacheKey cacheId = generateKey(clazz,id);
 +              return getFromCache(cacheId);
 +      }
 +
 +      public CdmBase getFromCache(CdmBase cdmBase) {
 +
 +              CdmEntityCacheKey cacheId = generateKey(cdmBase);
 +              CdmBase cachedCdmEntity = getFromCache(cacheId);
 +
 +              if(cachedCdmEntity == null) {
 +                      // ... then try the permanent (uuid-based) cache
 +                      cachedCdmEntity = cdmServiceCacher.getFromCache(cdmBase.getUuid());
 +              }
 +
 +              return cachedCdmEntity;
 +      }
 +
 +      public CdmBase getFromCache(CdmBase cdmBase, Class<? extends CdmBase> clazz) {
 +
 +              cdmBase = CdmBase.deproxy(cdmBase, clazz);
 +              CdmEntityCacheKey cacheId = generateKey(cdmBase);
 +
 +              CdmBase cachedCdmEntity = getFromCache(cacheId);
 +
 +              if(cachedCdmEntity == null) {
 +                      // ... then try the permanent (uuid-based) cache
 +                      cachedCdmEntity = cdmServiceCacher.getFromCache(cdmBase.getUuid());
 +              }
 +
 +              return cachedCdmEntity;
 +      }
 +
 +      public List<CdmBase> getAllEntities() {
 +              List<CdmBase> entities = new ArrayList<CdmBase>();
 +              Map<String, CdmBase> elementsMap = getCache().getAllWithLoader(getCache().getKeys(), null);
 +              for (Map.Entry<String, CdmBase> entry : elementsMap.entrySet()) {
 +                      entities.add(entry.getValue());
 +              }
 +              return entities;
 +      }
 +
 +      public boolean exists(CdmEntityCacheKey key) {
 +              return (getCacheElement(key) != null);
 +      }
 +
 +      public boolean existsAndIsNotNull(CdmEntityCacheKey id) {
 +              return getFromCache(id) != null;
 +      }
 +
 +      public void dispose() {
 +              cache.removeAll();
 +              cache.flush();
 +      }
 +
 +
 +      public static CdmEntityCacheKey generateKey(Class<? extends CdmBase> clazz, int id) {
 +              return new CdmEntityCacheKey(clazz, id);
 +      }
 +
 +
 +      public static CdmEntityCacheKey generateKey(CdmBase cdmBase) {
 +              Class<? extends CdmBase> entityClass = cdmBase.getClass();
 +              int id = cdmBase.getId();
 +              return new CdmEntityCacheKey(entityClass, id);
 +      }
 +
 +      public static boolean isRecursiveEnabled() {
 +              return isRecursiveEnabled;
 +      }
 +
 +      public static void  setRecursiveEnabled(boolean ire) {
 +              isRecursiveEnabled = ire;
 +      }
 +
 +}
index 439e84507f0f4ea37282dba5004e6ae1feb52eb8,0000000000000000000000000000000000000000..218d94dd85531cb159d8be325f7ed0b0473df27c
mode 100644,000000..100644
--- /dev/null
@@@ -1,40 -1,0 +1,39 @@@
- import org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor;
 +package eu.etaxonomy.taxeditor.service;
 +
 +import java.io.IOException;
 +import java.io.OutputStream;
 +
 +import org.springframework.remoting.httpinvoker.HttpInvokerClientConfiguration;
 +import org.springframework.remoting.support.RemoteInvocation;
 +import org.springframework.remoting.support.RemoteInvocationResult;
- public abstract class CdmServiceRequestExecutor extends AuthenticationSimpleHttpInvokerRequestExecutor {
-       
 +
-       
++public abstract class CdmServiceRequestExecutor extends CdmAuthenticatedHttpInvokerRequestExecutor {
++
 +      private RemoteInvocation currentRemoteInvocation;
-       
++
 +      @Override
 +      protected void writeRemoteInvocation(RemoteInvocation invocation, OutputStream os) throws IOException {
 +              currentRemoteInvocation = invocation;
 +              super.writeRemoteInvocation(invocation, os);
 +      }
 +
 +      @Override
 +      protected RemoteInvocationResult doExecuteRequest(HttpInvokerClientConfiguration config,
 +                      java.io.ByteArrayOutputStream baos)
 +                                      throws java.io.IOException,
 +                                      java.lang.ClassNotFoundException {
 +              RemoteInvocationResult rir = fromCache(currentRemoteInvocation);
-               } 
-               
++
 +              if(rir == null) {
 +                      rir = super.doExecuteRequest(config, baos);
 +                      cache(currentRemoteInvocation, rir);
-       
++              }
++
 +              currentRemoteInvocation = null;
 +              return rir;
 +      }
-       
++
 +      public abstract void cache(RemoteInvocation ri, RemoteInvocationResult rir);
++
 +      public abstract RemoteInvocationResult fromCache(RemoteInvocation ri);
 +}
index 3a83b405aecb2adeaaead0e5f5b18e00b0d3a176,0000000000000000000000000000000000000000..8f6a35dafad9e55962dbe443b6db79df81a433ff
mode 100644,000000..100644
Binary files differ
index 9e64417e984a3326b44c77daa2395907be49daec,e3c0f9fd8ef75e7c6a175a3d9c1a5fd0d74c6dba..1338a2d5946fccd0ffae322d8fac5d04dc1da286
  <?xml version="1.0" encoding="UTF-8"?>\r
  <beans xmlns="http://www.springframework.org/schema/beans"\r
 -      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\r
 -      xmlns:context="http://www.springframework.org/schema/context"\r
 -      xmlns:tx="http://www.springframework.org/schema/tx"\r
 -      xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd\r
 +  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context"\r
 +  xmlns:tx="http://www.springframework.org/schema/tx"\r
 +  xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd\r
      http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd\r
      http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">\r
  \r
 -      \r
 -   <bean id="agentService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/agent.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IAgentService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="annotationService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/annotation.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IAnnotationService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="auditeventService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/auditevent.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IAuditEventService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="classificationService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/classification.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IClassificationService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="collectionService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/collection.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.ICollectionService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="commonService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/common.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.ICommonService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="descriptionService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/description.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IDescriptionService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -   <bean id="editGeoService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/editgeo.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.ext.geo.IEditGeoService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="featureNodeService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/featurenode.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IFeatureNodeService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="featureTreeService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/featuretree.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IFeatureTreeService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="groupService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/group.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IGroupService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="identificationKeyService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/identificationkey.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IIdentificationKeyService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="locationService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/location.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.ILocationService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="markerService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/marker.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IMarkerService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="mediaService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/media.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IMediaService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="nameService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/name.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.INameService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="occurrenceService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/occurrence.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IOccurrenceService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="polytomousKeyNodeService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/polytomouskeynode.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IPolytomousKeyNodeService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="polytomousKeyService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/polytomouskey.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IPolytomousKeyService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="referenceService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/reference.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IReferenceService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -<!-- \r
 -   <bean id="serviceService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/service.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IService</value>\r
 -              </property>\r
 -      </bean>\r
 - -->\r
 - \r
 -   <bean id="taxonNodeService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/taxonnode.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.ITaxonNodeService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="taxonService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/taxon.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.ITaxonService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="termService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/term.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.ITermService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="userService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/user.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IUserService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="vocabularyService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/vocabulary.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IVocabularyService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -   <bean id="workingSetService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/workingset.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IWorkingSetService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -   <bean id="grantedAuthorityService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/grantedauthority.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IGrantedAuthorityService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -   <bean id="databaseService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/database.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.IDatabaseService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -   <bean id="lsidAuthorityService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsidauthoruty.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.lsid.LSIDAuthorityService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -   <bean id="lsidMetadataService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsidmetadata.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.lsid.LSIDMetadataService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -   <bean id="lsiDataService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsiddata.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.lsid.LSIDDataService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -\r
 -      <bean id="providerManager"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/authenticationManager.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>org.springframework.security.authentication.AuthenticationManager</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -      <bean id="primerService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/primer.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.molecular.IPrimerService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -      <bean id="amplificationService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/amplification.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.molecular.IAmplificationService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 -      \r
 -      <bean id="sequenceService"\r
 -              class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 -              <property name="serviceUrl">\r
 -                      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/sequence.service</value>\r
 -              </property>\r
 -              <property name="serviceInterface">\r
 -                      <value>eu.etaxonomy.cdm.api.service.molecular.ISequenceService</value>\r
 -              </property>\r
 -              <property name="httpInvokerRequestExecutor">\r
 -                      <bean class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 -              </property>\r
 -      </bean>\r
 +\r
 +  <bean id="agentService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/agent.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/agent.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IAgentService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="annotationService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/annotation.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/annotation.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IAnnotationService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="auditeventService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/auditevent.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/auditevent.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IAuditEventService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="classificationService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/classification.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/classification.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IClassificationService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="collectionService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/collection.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/collection.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.ICollectionService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="commonService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/common.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/common.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.ICommonService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="descriptionService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/description.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/description.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IDescriptionService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="editGeoService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/editgeo.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/editgeo.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.ext.geo.IEditGeoService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="featureNodeService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/featurenode.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/featurenode.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IFeatureNodeService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="featureTreeService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/featuretree.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/featuretree.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IFeatureTreeService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="groupService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/group.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/group.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IGroupService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="identificationKeyService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/identificationkey.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/identificationkey.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IIdentificationKeyService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="locationService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/location.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/location.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.ILocationService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="markerService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/marker.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/marker.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IMarkerService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="mediaService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/media.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/media.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IMediaService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="nameService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/name.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/name.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.INameService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="occurrenceService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/occurrence.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/occurrence.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IOccurrenceService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="polytomousKeyNodeService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/polytomouskeynode.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/polytomouskeynode.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IPolytomousKeyNodeService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="polytomousKeyService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/polytomouskey.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/polytomouskey.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IPolytomousKeyService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="referenceService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/reference.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/reference.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IReferenceService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <!-- <bean id="serviceService" class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean"> \r
 +    <property name="serviceUrl"> <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/service.service</value> \r
 +    </property> <property name="serviceInterface"> <value>eu.etaxonomy.cdm.api.service.IService</value> \r
 +    </property> </bean> -->\r
 +\r
 +  <bean id="taxonNodeService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/taxonnode.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/taxonnode.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.ITaxonNodeService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="taxonService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/taxon.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/taxon.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.ITaxonService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="termService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/term.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/term.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.ITermService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean class="eu.etaxonomy.taxeditor.service.TermServiceRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="userService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/user.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting-public/user.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IUserService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
-         class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
++        class="org.springframework.remoting.httpinvoker.SimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="vocabularyService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/vocabulary.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/vocabulary.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IVocabularyService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="workingSetService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/workingset.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/workingset.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IWorkingSetService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="grantedAuthorityService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/grantedauthority.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/grantedauthority.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IGrantedAuthorityService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="databaseService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/database.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/database.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IDatabaseService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="lsidAuthorityService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsidauthoruty.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsidauthoruty.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.lsid.LSIDAuthorityService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="lsidMetadataService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsidmetadata.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsidmetadata.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.lsid.LSIDMetadataService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="lsiDataService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsiddata.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/lsiddata.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.lsid.LSIDDataService</value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="providerManager"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/authenticationManager.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/authenticationManager.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>org.springframework.security.authentication.AuthenticationManager\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="primerService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/primer.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/primer.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.molecular.IPrimerService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="amplificationService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/amplification.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/amplification.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.molecular.IAmplificationService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="sequenceService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/sequence.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/sequence.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.molecular.ISequenceService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="entityValidationResultService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/entityvalidationresult.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/entityvalidationresult.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IEntityValidationResultService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
 +\r
 +  <bean id="entityConstraintViolationService"\r
 +    class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">\r
 +    <property name="serviceUrl">\r
-       <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/entityconstraintviolation.service\r
-       </value>\r
++      <value>http://${remoteServer}:${remotePort}/${remoteContext}/remoting/entityconstraintviolation.service</value>\r
 +    </property>\r
 +    <property name="serviceInterface">\r
 +      <value>eu.etaxonomy.cdm.api.service.IEntityConstraintViolationService\r
 +      </value>\r
 +    </property>\r
 +    <property name="httpInvokerRequestExecutor">\r
 +      <bean\r
 +        class="org.springframework.security.remoting.httpinvoker.AuthenticationSimpleHttpInvokerRequestExecutor" />\r
 +    </property>\r
 +  </bean>\r
  \r
  \r
  \r
index 6eea426932dc6eea9ca0a8f28514a98724ee6ead,0000000000000000000000000000000000000000..62a21d7ac6ea9c893068d511eb6ca40570cd3fda
mode 100644,000000..100644
--- /dev/null
@@@ -1,183 -1,0 +1,184 @@@
-     
 +/**
 + * Copyright (C) 2014 EDIT
 + * European Distributed Institute of Taxonomy
 + * http://www.e-taxonomy.eu
 + *
 + * The contents of this file are subject to the Mozilla Public License Version 1.1
 + * See LICENSE.TXT at the top of this package for the full license terms.
 + */
 +package eu.etaxonomy.taxeditor.httpinvoker;
 +
 +import java.io.IOException;
 +import java.lang.reflect.Field;
 +import java.util.Map;
 +
 +import org.junit.AfterClass;
 +import org.junit.Assert;
 +import org.junit.BeforeClass;
 +import org.junit.Test;
 +import org.springframework.core.io.ClassPathResource;
 +import org.springframework.core.io.Resource;
 +import org.unitils.UnitilsJUnit4;
 +import org.unitils.database.DatabaseUnitils;
 +import org.unitils.database.annotations.Transactional;
 +import org.unitils.database.util.TransactionMode;
 +import org.unitils.spring.annotation.SpringApplicationContext;
 +
 +import eu.etaxonomy.cdm.api.application.CdmApplicationRemoteController;
 +import eu.etaxonomy.cdm.model.name.NomenclaturalCode;
 +import eu.etaxonomy.taxeditor.remoting.cache.CdmClientCacheException;
 +import eu.etaxonomy.taxeditor.remoting.cache.CdmTransientEntityCacher;
 +import eu.etaxonomy.taxeditor.remoting.source.CdmPersistentRemoteSource;
 +import eu.etaxonomy.taxeditor.remoting.source.CdmRemoteSource;
 +import eu.etaxonomy.taxeditor.remoting.source.CdmRemoteSourceException;
 +import eu.etaxonomy.taxeditor.remoting.source.ICdmRemoteSource;
 +import eu.etaxonomy.taxeditor.session.CdmEntitySession;
 +import eu.etaxonomy.taxeditor.session.ICdmEntitySessionManager;
 +import eu.etaxonomy.taxeditor.session.ISessionEventListener;
 +
 +
 +/**
 + * Base class for remoting tests, responsible for
 + * - starting / stop the cdm server
 + * - running some basic connection tests
 + * - setting up the remote configuration.
 + *
 + */
 +@Transactional(TransactionMode.DISABLED)
 +@SpringApplicationContext("file:./target/classes/eu/etaxonomy/cdm/testRemotingApplicationContext.xml")
 +public class BaseRemotingTest extends UnitilsJUnit4 {
 +    //private static final Logger logger = Logger.getLogger(BaseRemotingTest.class);
 +
 +    private static final Resource TEST_REMOTE_APPLICATION_CONTEXT_RESOURCE =
 +            new ClassPathResource("/eu/etaxonomy/cdm/testRemotingApplicationContext.xml");
 +
 +    private static CdmApplicationRemoteController remoteApplicationController;
 +    private static ICdmRemoteSource cdmRemoteSource;
 +    private static CdmPersistentRemoteSource remotePersistentSource;
 +
 +    public static boolean useManagedServer = true;
 +
 +    public static final Resource CDMLIB_DISK_STORE_RESOURCE =
 +            new ClassPathResource("/eu/etaxonomy/cache");
-     
++
 +    protected static ICdmEntitySessionManager cdmEntitySessionManager;
-         
++
 +    @BeforeClass
 +    public static void initializeBaseRemotingTest() {
 +        //NOTE: Run this the cdmTest H2 DB whenever it needs to be
 +      //      recreated e.g. after a model change
 +      //DatabaseUnitils.disableConstraints();
 +
 +              try {
 +                      System.setProperty("ehcache.disk.store.dir", CDMLIB_DISK_STORE_RESOURCE.getFile().getAbsolutePath());
 +              } catch (IOException e) {
 +                      throw new CdmClientCacheException(e);
 +              }
-     
++
 +        useManagedServer = (System.getProperty("use.managed.server") == null) ? useManagedServer : Boolean.valueOf(System.getProperty("use.managed.server"));
 +        if(useManagedServer) {
 +            try {
 +                CDMServer.getInstance().start();
 +            } catch (Exception e) {
 +                e.printStackTrace();
 +                Assert.fail("Server failed to start. Reason : " + e.getMessage());
 +            }
 +
 +        initializeController(CDMServer.getInstance().getName(),
 +                CDMServer.getInstance().getHost(),
 +                CDMServer.getInstance().getPort(),
 +                CDMServer.getInstance().getContextPath(),
 +                NomenclaturalCode.ICNAFP);
 +        }
 +    }
 +
-     
++
 +    @Test
 +    public void disableConstraints() {
 +      // To be run on the src/test/resources/h2/cdmTest h2 db after
 +      // updating the unitils.properties 'database.url' property
 +      DatabaseUnitils.disableConstraints();
 +    }
++
 +    public static void initializeController(String sourceName, String host, int port, String contextPath, NomenclaturalCode ncode) {
 +
 +        cdmRemoteSource = CdmRemoteSource.NewInstance(sourceName, host, port, contextPath, ncode);
 +        remoteApplicationController =
 +                CdmApplicationRemoteController.NewInstance(cdmRemoteSource,
 +                        false,
 +                        null,
 +                        null);
 +
 +        try {
 +            remotePersistentSource = CdmPersistentRemoteSource.NewInstance(sourceName);
 +        } catch (CdmRemoteSourceException e) {
 +            Assert.fail("Default Remote Persistent Source failed to load. Reason : " + e.getMessage());
 +        }
 +        cdmEntitySessionManager = getRemoteApplicationController().getCdmEntitySessionManager();
 +    }
 +
 +
 +
 +    protected static CdmApplicationRemoteController getRemoteApplicationController() {
 +        return remoteApplicationController;
 +    }
 +
 +    protected static ICdmRemoteSource getCdmRemoteSource() {
 +        return cdmRemoteSource;
 +    }
 +
 +    protected static CdmPersistentRemoteSource getCdmPersistentRemoteSource() {
 +        return remotePersistentSource;
 +    }
-     
-     
++
 +    protected static ICdmEntitySessionManager getCdmEntitySessionManager() {
 +      return cdmEntitySessionManager;
 +    }
-       Map<ISessionEventListener, CdmEntitySession> ownerSessionMap = 
++
++
 +    protected static CdmEntitySession getSession(ISessionEventListener sessionOwner) {
-     
++      Map<ISessionEventListener, CdmEntitySession> ownerSessionMap =
 +                      (Map<ISessionEventListener, CdmEntitySession>) getFieldValueViaReflection(cdmEntitySessionManager, "ownerSessionMap");
 +      return ownerSessionMap.get(sessionOwner);
 +    }
-     
++
 +    protected static CdmTransientEntityCacher getActiveSession() {
 +      return (CdmTransientEntityCacher) getFieldValueViaReflection(cdmEntitySessionManager, "activeSession");
 +    }
++
 +    protected static CdmTransientEntityCacher getCacher(ISessionEventListener sessionOwner) {
 +      return (CdmTransientEntityCacher) getFieldValueViaReflection(getSession(sessionOwner), "cdmTransientEntityCacher");
 +    }
 +
 +    @AfterClass
 +    public static void cleanup() {
 +        try {
 +            CDMServer.getInstance().stop();
 +        } catch (Exception e) {
 +            Assert.fail("Server could not be stopped. Reason : " + e.getMessage());
 +        }
 +    }
 +
 +
 +    protected static Object getFieldValueViaReflection(Object object, String fieldName) {
 +        Class<?> clazz = object.getClass();
 +        try {
 +            Field field = clazz.getDeclaredField(fieldName);
 +            field.setAccessible(true);
 +            return field.get(object);
 +        } catch (NoSuchFieldException e) {
 +            e.printStackTrace();
 +        } catch (SecurityException e) {
 +            e.printStackTrace();
 +        } catch (IllegalArgumentException e) {
 +            e.printStackTrace();
 +        } catch (IllegalAccessException e) {
 +            e.printStackTrace();
 +        }
 +        return null;
 +    }
 +
 +
 +
 +
 +}
index b05d362e99c5daf70eb36269de5d1710f38cf924,0000000000000000000000000000000000000000..be22f3a7fca79170f93ab2ab9390d389113c09ef
mode 100644,000000..100644
--- /dev/null
@@@ -1,34 -1,0 +1,61 @@@
- * Copyright (C) 2014 EDIT
- * European Distributed Institute of Taxonomy
- * http://www.e-taxonomy.eu
- *
- * The contents of this file are subject to the Mozilla Public License Version 1.1
- * See LICENSE.TXT at the top of this package for the full license terms.
- */
 +/**
-       private static final Logger logger = Logger.getLogger(HttpInvokerServicesTest.class);
-       @Test
-       public void whenCallingMethodsOnRemoteServicesThenSuceed() {
-               try {
-                       String dbSchemaVersion = getRemoteApplicationController().getDatabaseService().getDbSchemaVersion();
-                       logger.info("dbSchemaVersion is " + dbSchemaVersion);
-               } catch (CdmSourceException e) {
-                       Assert.fail("pinging database service on active cdm server should not have thrown CdmSourceException");
-               }
-       }
++ * Copyright (C) 2014 EDIT
++ * European Distributed Institute of Taxonomy
++ * http://www.e-taxonomy.eu
++ *
++ * The contents of this file are subject to the Mozilla Public License Version 1.1
++ * See LICENSE.TXT at the top of this package for the full license terms.
++ */
 +package eu.etaxonomy.taxeditor.httpinvoker;
 +
++import org.apache.log4j.Level;
 +import org.apache.log4j.Logger;
 +import org.junit.Assert;
++import org.junit.BeforeClass;
 +import org.junit.Test;
++import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
++import org.springframework.security.core.Authentication;
++import org.springframework.security.core.context.SecurityContextHolder;
++import org.springframework.security.core.context.SecurityContextImpl;
 +
 +import eu.etaxonomy.cdm.config.CdmSourceException;
++import eu.etaxonomy.cdm.model.name.NomenclaturalCode;
 +
 +/**
 + * Class to test the HttpInvoker services exposed by the CDM Sever
 + *
 + */
 +public class HttpInvokerServicesTest extends BaseRemotingTest {
++    private static final Logger logger = Logger.getLogger(HttpInvokerServicesTest.class);
++
++    @BeforeClass
++    public static void initializeHttpInvokerServicesTest() {
++        logger.setLevel(Level.INFO);
++        initializeController("default", "127.0.0.1", 8080, "", NomenclaturalCode.ICNAFP);
++    }
++
++    @Test
++    public void whenCallingMethodsOnRemoteServicesThenSucceed() {
++        try {
++            SecurityContextHolder.clearContext();
++
++            String username = "admin";
++            String pw = "kups366+RU";
++
++            SecurityContextImpl sc = new SecurityContextImpl();
++            Authentication token = new UsernamePasswordAuthenticationToken(username,pw);
++            Authentication authentication = getRemoteApplicationController().getAuthenticationManager().authenticate(token);
++
++            authentication = new UsernamePasswordAuthenticationToken(username,pw, authentication.getAuthorities());
++            sc.setAuthentication(authentication);
++
++            SecurityContextHolder.setContext(sc);
++            getRemoteApplicationController().getDatabaseService();
++            String dbSchemaVersion = getRemoteApplicationController().getDatabaseService().getDbSchemaVersion();
++            logger.info("dbSchemaVersion is " + dbSchemaVersion);
++        } catch (CdmSourceException e) {
++            Assert.fail("pinging database service on active cdm server should not have thrown CdmSourceException");
++        }
++    }
 +
 +}