Author |
Message
|
MooseMcDowell |
Posted: Tue Nov 01, 2011 1:27 pm Post subject: Extraneous jar files when creating bar file from Ant |
|
|
Newbie
Joined: 01 Nov 2011 Posts: 8
|
Hi -
I'm trying to create a bar file for a message flow with 7.0 Toolkit and I keep getting all of these extra jar files that we don't need. I have tried creating a user library and adding it to the attached java projects in the subflows but I can't seem to get rid of them. Are there tricks to ensuring that the projects see these libraries?
Thanks,
Moose
Last edited by MooseMcDowell on Wed Nov 02, 2011 5:15 am; edited 1 time in total |
|
Back to top |
|
 |
Esa |
Posted: Wed Nov 02, 2011 2:33 am Post subject: |
|
|
 Grand Master
Joined: 22 May 2008 Posts: 1387 Location: Finland
|
Please elaborate. There are several possible cases and I need to know which one is your problem.
Which jar files are you talking about? What is in there? What did you try to do?
What is in your user library? Did you put your java compute node class there ( the one that extends MbJavaComputeNode)? |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Nov 02, 2011 2:47 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
The way you add java dependencies to the java compute node project changes how they are added to the BAR file or not.
If you add them in as regular dependencies or import them into your project, then they will be added to the bar file when you build the message flow.
You can then delete them from the bar file before you deploy it...
If you add them as "External Dependencies", then jar files are used to compile classes but not added to the bar file. |
|
Back to top |
|
 |
Esa |
Posted: Wed Nov 02, 2011 3:00 am Post subject: |
|
|
 Grand Master
Joined: 22 May 2008 Posts: 1387 Location: Finland
|
With the exception of the MbJavaComputeNode instance that the java Compute Node points to. The bar file builder needs to access it's source code from a workspace java project and it will build a jar file of the java project. As far as I know it will be this way in V8 too (I have asked the Hursley people).
There are some workarounds. But first I would like to know if the OP is talking about these jars or something else. |
|
Back to top |
|
 |
ganesh |
Posted: Wed Nov 02, 2011 5:48 am Post subject: |
|
|
Master
Joined: 18 Jul 2010 Posts: 294
|
There are some jars which you can delete from the bar files i.e. configmanagerproxy.jar.... ,usually the common jars are deployed at the broker level so you don't need them inside your bar file.
There are unzip and zip tasks available in ant which you can use to open the bar file and delete the not required contents and zip it again. |
|
Back to top |
|
 |
MooseMcDowell |
Posted: Wed Nov 02, 2011 7:05 am Post subject: |
|
|
Newbie
Joined: 01 Nov 2011 Posts: 8
|
Thanks for the responses. The compute node jars were in the right place - it was other jar files...MQ, JDBC, things like that.
It turns out there were a few sub-projects which had internal dependencies on these jar files, so they were being included, as mqjeff mentioned. The projects were removed as dependencies, and the jars were added as user libraries. The bar files seem to be correct, although we haven't tested them yet.
Thank you all for your help on this. |
|
Back to top |
|
 |
|