Fat wars with Apache Jena dependencies

Hi,

We make extensive use of Apache Jena to interface with Stardog.
We deploy basically all our applications as Java web applications in local Tomee instances or cloud based through Bluemix or AWS. We have noticed that the size of our applications is at least 25mb in compressed form due to the ‘heavy’ dependencies of the Jena connector ( through the sesame bridge ).

In local instances we can solve this by loading all the dependencies into the Tomee installation, but remote that is not an option.

Would there be a way forward to create a ‘slim’ set of dependencies?
We are aware that basic Jena is 10mb in compressed size as well.

Bart

Hi,

Are you pulling your dependencies from maven.stardog.com? Which dependencies specifically are you using related to Stardog?

Is a 25mb war/ear causing a problem? I’m not sure exactly what you’re build looks like but you can try creating skinny wars with the maven-ear-plugin. You could also try using Proguard to generate a minimal set of dependencies.

I should add that using Proguard may do bad things, void your warranty and be mean to cute little kittens. I’m also not sure if the Stardog folks would be ok with that since I believe it may be in violation of the license agreement but I don’t know so check first.

The only dependency I use in my code is
stardog-jena:5.0-beta

This pulls in the 25mb of compressed dependencies

Hi, apologies for the delays. After looking into this, I’m afraid at best we would only be able to shave 2-3MB out of that dependency. Have you tried telling maven/gradle to exclude the bits that your application doesn’t need (e.g., Sesame)?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.