On Thu, May 26, 2011 at 1:55 AM, Ryan Davis <ryand-r...@zenspider.com> wrote:
> So, to add some history (from (faulty) memory):
>
> + You and I have talked about this and you pointed me to your patches.
> + Some of those patches we can address outright. Some, not so easily.
> + For the easy ones, I already refactored remote_fetcher so that it'll 
> dispatch based on the URL protocol: `send("fetch_#{uri.scheme}", ...)` so you 
> can add fetch_mvn (which is probably just an alias to fetch_http?).

This isn't bad, but there's still the spec resolution, dependencies,
and so on. These might be the "not so easily" patches, where based on
the gem name we branch to mvn logic for resolving a spec.

The current JRuby logic essentially hooks spec resolution to go to our
logic if it's an "mvn" gem name...

FWIW, I have not seen your remote_fetcher refactoring yet...that's
homework for me.

> + The more difficult ones didn't have obvious refactorings we could do 
> iirc... but I don't remember what they were at this point.

The patches we have at the moment are still based on 1.5.1, so we need
to try updating to current RubyGems. They are available by diffing the
jruby-rubygems_1_5_1 branch against RubyGems 1.5.1 using our forked
repository here:

https://github.com/jruby/rubygems/tree/jruby-rubygems_1_5_1

The big maven-related file can be mostly ignored; interesting bits are
the patches to RG source, which we've tried to keep minimal. I welcome
any and all comments on the tweaks we've made here.

> In this specific case, is there a reason why the platform default hook isn't 
> an appropriate place to put your extensions? (like, you're hoping to offload 
> this elsewhere or something)

Mostly because the spec-related methods in question were large and
monolithic. Patching them in defaults would require duplicating their
logic in toto but including our changes, which would be less than
ideal. Of course without attempting to make the same changes against
RG master, I'm not sure if it's an easier monkey patch now.

- Charlie
_______________________________________________
Rubygems-developers mailing list
http://rubyforge.org/projects/rubygems
Rubygems-developers@rubyforge.org
http://rubyforge.org/mailman/listinfo/rubygems-developers

Reply via email to