cancel
Showing results for 
Search instead for 
Did you mean: 

Action Evaluator class not found

alouw
Champ in-the-making
Champ in-the-making
I have defined an action with an evaluator in my web-client-config-custom.xml file. This web-client-config-custom file is contained in a jar file deployed into my "tomcat\webapps\alfresco\WEB-INF\lib" folder (lets call it abc.jar).

During the building of the Action elements (in org.alfresco.web.config.ActionsElementReader) an exception is thrown complaining that it is "Unable to construct action" because it cannot find my evaluator's class. This class does exist but in a different jar file, also deployed to the lib folder.

Changing the evaluator's class to a java class contained in the same jar file (abc.jar) works fine.

Should it be possible to reference a class declared in another jar file as an action evaluator?

This looks like a classloader issue, but could somebody please point me in the right direction to solve this?
2 REPLIES 2

lilyh
Champ in-the-making
Champ in-the-making
Hello alouw,
I am having the same issue here. Have you made any progress?
I will repost if I make progress.
Thank you.

lilyh
Champ in-the-making
Champ in-the-making
Hello,

I managed to get rid of the error.
How did you implement your evaluator class? There has been some changes to the API (unsure how recent) but my class originally only contained the evaluate(Node node) method and worked in earlier versions of Alfresco.
I'm working in 3.2 and am required to implement two methods, evaluate(Node node) and evaluate(Object obj) for the evaluator to work.
I made these changes to the class but it still wouldn't work. I then proceeded to break down the class and recreate it in a new file with the new method and it miraculously started working.
I copied the code across to the new file as I put in debug comments, the final piece of code was basically identical to the modified class (with the new method) but for some weird reason the modified class would still throw the error in Alfresco. Not sure if that makes sense.
Hope this helps.

Lily.