On Monday, 4 August 2014 08:57:19 UTC-4, Martin Ennemoser wrote: > > I have a ruby script which instruments Net::HTTP requests in Rails > applications. This works as follows: When Ruby loads the Net::HTTP class, I > alias the request method. At every http request, my instrumented method > gets executed. So that this works, I need to execute my script BEFORE ruby > loads the standard library and BEFORE Rails gets loaded. >
Why do you need to load *before* Net::HTTP? If you use something like alias_method_chain, you can inject your wrapper after-the-fact. Hard to troubleshoot much farther without seeing how you're hooking into Net::HTTP. --Matt Jones -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscr...@googlegroups.com. To post to this group, send email to rubyonrails-talk@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/ae4c3e1a-4d65-45d6-9794-9c7efb0ab4fd%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.