Unbundle bouncy-castle-java #1210

Closed
voxik opened this Issue Nov 8, 2013 · 6 comments

Projects

None yet

2 participants

@voxik
Contributor
voxik commented Nov 8, 2013

Please unbundle bouncy-castle-java form JRuby. Bundling is not acceptable for Fedora.

@mkristian
Member

that is part of the jruby-openssl gem will be the same 'procedure' as with
the krypt gem with the difference that it is part of jruby source.

for the jruby-core and jruby-stdlib maven artifact I played around to
remove all those jars and declare them as direct dependency inside their
respective poms. I did not continue that road since without a little patch
for the jruby-classloader that would mean that you can NOT install new
version via jruby-openssl gem and alike. but reading about your bundle jars
problem, it would be worth exploring that again.

BTW the jline.jar will be next to come into your way.

@voxik
Contributor
voxik commented Nov 8, 2013

that is part of the jruby-openssl gem

Should be dependency, not part. Hopefully you used just wrong terminology :)

I played around to remove all those jars.

This issue is not just about jar itself, but about every code which comes from https://github.com/nahi/bouncy-castle-java

BTW the jline.jar will be next to come into your way.

jline is different. It is external library. We unbundle it already for some time and put it later on JRuby's class path.

@mkristian
Member

On Fri, Nov 8, 2013 at 4:25 PM, Vít Ondruch notifications@github.comwrote:

that is part of the jruby-openssl gem

Should be dependency, not part. Hopefully you used just wrong terminology
:)

I played around to remove all those jars.

This issue is not just about jar itself, but about every code which comes
from https://github.com/nahi/bouncy-castle-java

but that is basically the jar wrapped in a gem. if you have bouncy-castle
on the classpath you can ignore those dependency (beside a classloader
issue when people want to use a newer version of bouncy-castle same as the
jline below)

BTW the jline.jar will be next to come into your way.

jline is different. It is external library. We unbundle it already for
some time and put it later on JRuby's class path.

if jruby find the jline jar on the classpath it means that if install a
readline gem with a newer jline.jar (packed into the gem) then jruby from
fedora will use the jline from the classpath instead of the one coming from
the gem :(
well that is not such a BIG issue since I think there is no readline gem
yet which can be used ;) but the idea of those extension is that they can
be updated independently from jruby

@voxik
Contributor
voxik commented Nov 8, 2013

but that is basically the jar wrapped in a gem. if you have bouncy-castle on the classpath you can ignore those dependency

Ah, ok ... so we are doing it wrong. We should symlink the jars to their original locations. That way we will preserve the original intended functionality and avoid possible collisions with libraries shipped by updated gems.

But for system packaged JRuby, we will always have to replace the bundled version with version available on the system, as long as RPM/YUM does not support properly more versions :/

Nevertheless, the bouncy-castle-java.rb should be unbundled, although it is just 3 lines of code.

@mkristian
Member

On Fri, Nov 8, 2013 at 5:50 PM, Vít Ondruch notifications@github.comwrote:

but that is basically the jar wrapped in a gem. if you have bouncy-castle
on the classpath you can ignore those dependency

Ah, ok ... so we are doing it wrong. We should symlink the jars to their
original locations. That way we will preserve the original intended
functionality and avoid possible collisions with libraries shipped by
updated gems.

that would be better until we have improved classloader in jruby. it is not
really wrong since the some thing can happen in java project using a jruby
scripting container and having any of the embedded jars in the classpath.
so it is bigger problem.

@mkristian
Member

this is done on both on master and on jruby-1_7 branch.

@mkristian mkristian closed this Apr 8, 2014
@mkristian mkristian added this to the JRuby 1.7.12 milestone Apr 8, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment