Update to work with Bundler & Rails 3.0 and make easier to apply #1

Open
wants to merge 29 commits into
from

Conversation

Projects
None yet
5 participants

Hello

Thanks for developing resque-statsd. We had some difficulty using this with Rails 3.0 & Bundler. Specifically, the way we had to use environment variables meant we couldn't simply add extend Resque::Plugins::Statsd in the right places like we do with other extensions because the initializer hadn't run yet.

Our patch doesn't work with Rails 2.x, it would need to be adjusted to try both ENV['RAILS_ENV'] as well as Rails.env.

Thanks

Mat & Jon

MrJoy and others added some commits Aug 25, 2011

Making config actually work properly.
Using a separate helper class to avoid weirdness with module lifecycle (yes yes, I need to learn how that aspect of Ruby works in more depth.).
Owner

jamster commented Aug 25, 2011

Thanks for contributing! I've actually lost my statsd/graphite setup due to a cloud server failure and my lack of time to get it back up, so I haven't messed around with it for quite some time. But, you've given me incentive to get it back up and test all this. Super busy this week, hope to get it in this weekend and I'll happily merge your commits.

Cheers,
Jason

We have a working puppet recipe if that helps, let me know if you'd like a copy.

M.

On Aug 25, 2011, at 1:46 PM, jamster wrote:

Thanks for contributing! I've actually lost my statsd/graphite setup due to a cloud server failure and my lack of time to get it back up, so I haven't messed around with it for quite some time. But, you've given me incentive to get it back up and test all this. Super busy this week, hope to get it in this weekend and I'll happily merge your commits.

Cheers,
Jason

Reply to this email directly or view it on GitHub:
#1 (comment)

Owner

jamster commented Aug 26, 2011

Yep, if you have that script handy, that would be great!

Install puppet, then put this somewhere and run:

puppet apply graphite.pp

Enjoy!

M.
PS: Designed for ubuntu

On Aug 26, 2011, at 6:29 AM, jamster wrote:

Yep, if you have that script handy, that would be great!

Reply to this email directly or view it on GitHub:
#1 (comment)

Owner

jamster commented Aug 28, 2011

didn't see an attachment. was there one? (never used puppet before, is it like ruby gems where it will pull from a centralized source?)

Here are the contents of the attachment. If you've not used puppet before it might be a bit of a pain.

On an ubuntu system copy the contents of this file to graphite.pp and do the following:

gem install puppet
puppet apply graphite.pp

It should work but it might not, if your ubuntu system is setup in a different way you might find a few dependencies missing but it might just work. Add --debug to the puppet command if you want to debug it, or you can just read the recipe and run the commands/install the packages manually.

Good luck.

M.

On Aug 28, 2011, at 9:24 AM, jamster wrote:

didn't see an attachment. was there one? (never used puppet before, is it like ruby gems where it will pull from a centralized source?)

Reply to this email directly or view it on GitHub:
#1 (comment)

noahhl and others added some commits Oct 6, 2011

Namespace things a bit.
(So if you're tracking something BESIDES Resque jobs in your app, you don't get frustrated...)
Making this monkey patch work with a similar one adding functionality…
… to the same Resque.push function

Old code was getting over-written by the last-included module monkey-patch
Add a before_perform_statsd method
(Updated to match new queue/job-name split, etc.)

Conflicts:

	lib/resque/plugins/statsd.rb
While we're at it, what is the point of including the test suite in t…
…he gem?

It just bloats deployments and doesn't actually make it easy/feasible to run the
tests out of the gems anyway.

So, if you wanna run the tests (if/when they ever exist) -- clone the repo.

ninetwentyfour pushed a commit to ninetwentyfour/resque-statsd that referenced this pull request Mar 30, 2013

Merge pull request #1 from jeremy/master
Switch statsd-ruby dependency back to the official gem
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment