Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Published Route is incomplete: JAR is missing a directory

While deploying a Route, I notice the following in the log file:

ERROR | SpringOsgiExtenderThread-119 | BundleApplicationContextListener   50 | 194 - org.springframework.osgi.extender - 1.2.1 | Application context refresh failed (OsgiBundleXmlApplicationContext(bundle=api.ApiProductServiceV2, config=osgibundle:/META-INF/spring/*.xml))

org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [api.apiproductservicev2_3_15.ApiProductServiceV2] for bean with name 'route' defined in URL [bundleentry://1669.fwk444558840/META-INF/spring/route.xml]; nested exception is java.lang.ClassNotFoundException: api.apiproductservicev2_3_15.ApiProductServiceV2 not found from bundle [api.ApiProductServiceV2]

 

The Route is not deployed, its services cannot be used.

 

This Route is similar in construction to other Routes that I have. Indeed, in earlier versions this Route could be deployed without errors. But "something happened" and now it cannot be deployed anymore. I googled it and found comparable problems, but the offered suggestions haven't helped me.

I am puzzled by this bean 'route', I don't have something like that, as far as I know. Or is it just because the component is a Route?

 

Upon further investigation, I noticed that the last version, which can be deployed successfully, contains the directories api, beans, com, lib and META-INF. Later versions, which cannot be deployed anymore, lack the api directory. This directory seems to contain the Route. So that explains the error that I am getting. The name api is also found in the Dependencies of the Route, section Export Packages.

 

Now the question is: what do I need to do to generate the api directory and its contents, again.

 

Edit: after advice from a much more experienced Talend developer, I switched to a new workspace. This produced some different results, but still my problems were not solved: clicking Run gave the error message "Exception in thread "main" java.lang.Error: Unresolved compilation problem: at api.apiproductservicev2_3_15.ApiProductServiceV2.main(ApiProductServiceV2.java:1383)". But this line number refers to: "public static void main(String[] args) {", so pretty much unusable.

 

After a restart of the Studio, I got the dreaded message that I have seen before: "Error: Could not find or load main class api.apiproductservicev2_3_16.ApiProductServiceV2"

 

The advice of the other developer is now: reinstall the Studio.

 

I ran the Studio from another machine, tried running the same Route and there it just runs. So the problem is indeed with the Studio on the machine I was using first. I guess I have to reinstall.

Labels (2)
3 Replies
Anonymous
Not applicable
Author

Hello,

Thanks for sharing your information with us. From you description, it seems that there is something wrong with your ESB installation.

Could you please clarify in which Talend version/edition you are? Is there any update when you reinstall your studio?

Best regards

Sabrina

Anonymous
Not applicable
Author

I am using 6.5.1.

 

I have not reinstalled the Studio yet, as that is a lot of work and I have a workaround: I am using a different machine.

Anonymous
Not applicable
Author

Hello,

Does it work as expected when you are using a different machine? What's OS and JDK version are you using in your previous machine?

Best regards

Sabrina