cancel
Showing results for 
Search instead for 
Did you mean: 

Get services from ServiceRegistry over SpringRemote?

huima
Champ in-the-making
Champ in-the-making
I got a go ahead to do CMS implementation on top of Alfresco and setting up my development environment and processes to be productive.

I am going to use Foundation API and build the app right on top of Alfresco - inside the same web application as the webclient, which will be used as an additional admin client. As I am learning the foundation API, making own content models and writing code, I would like to test my code against the real repository.

I've already learnt that I could try to create my own unit tests based on BaseAlfrescoTestCase, but was wondering whether I could cheat a little and deploy Alfresco webclient into my appserver with an additional spring code that exposes service registry to my remote code via spring remoting? That would make everything walk in a park, but since I didn't find any wiki or forum articles about this kind of remoting - I assume that it most likely won't work. I assume that some code like authentication / authorization uses ThreadLocal or something similar and that doesn't  work well with such remoting.

But should it work?

If anyone can say affirmative "no" or "yes", it could save time from me .
2 REPLIES 2

mrogers
Star Contributor
Star Contributor
No.   The services are not "Serializable".

However where is this "remote code"?   You are running in the local web-app ?

huima
Champ in-the-making
Champ in-the-making
Well I was thinking writing local junit tests or even local webapplication, which would include the code which would use the repository.

If it would have been possible to run them fast locally, it wold have ment faster development time and ease of development in write, test and debug cycle 😄