Thursday, April 2, 2015

java.lang.NoSuchMethodError: org.apache.commons.lang.StringUtils.defaultIfEmpty(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String

 

While using the Taleo Connect Client (TCC) for some advanced configurations , for instance for attachments, you might run into some weird java related errors.

 

java.lang.NoSuchMethodError: org.apache.commons.lang.StringUtils.defaultIfEmpty(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    at com.taleo.integration.client.customstep.BaseCustomStep.init(BaseCustomStep.java:120)
    at com.taleo.integration.client.customstep.xml.ExtractAttachedFilePostStep.init(ExtractAttachedFilePostStep.java:424)
    at com.taleo.integration.client.step.BaseCustomStep.init(BaseCustomStep.java:58)
    at com.taleo.integration.client.step.CustomStepWrapper.init(CustomStepWrapper.java:111)
    at com.taleo.integration.client.workflow.WorkflowManager.addSteps(WorkflowManager.java:1006)
    at com.taleo.integration.client.workflow.WorkflowManager.addPostProcessSteps(WorkflowManager.java:977)
    at com.taleo.integration.client.workflow.WorkflowManager.createWorkflow(WorkflowManager.java:172)
    at com.taleo.integration.client.workflow.WorkflowManager.execute(WorkflowManager.java:328)
    at com.taleo.integration.client.rcp.job.ConfigurationExecutionJob.run(ConfigurationExecutionJob.java:109)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76)

 

 

It turns out that the issue was with the TCC installer itself. The fix is to replace commons-lang-2.0.jar with commons-lang-2.6.jar [TCC installation folder]\lib\endorsed

Oracle Sucks !