Commit Graph

221 Commits

Author SHA1 Message Date
jway e91d42b7fe move jruby deps into platform java 2015-05-06 20:24:56 -07:00
R. Tyler Croy a362ce153e Merge pull request #98 from zendesk/fix_1.9.3
1.9.3 fixes
2015-04-30 08:11:38 -07:00
Ben Osheroff efd1a80a37 1.9.3 fixes
1.9.3 seems like it should actually still be using the
rb_thread_blocking_region() call, as ...call_without_gvl() isn't defined
in any header (although it is available).

Consuming that implicit declaration was causing crashes.
2015-04-30 07:52:01 -07:00
R. Tyler Croy 4c451b4344 Merge pull request #97 from zendesk/fix_use_after_free
Fix use-after-free bug
2015-04-29 15:54:38 -07:00
Ben Osheroff 30669be4d5 Fix use-after-free bug
it's not safe to simply pluck strings off the heap unless we were also
going to maintain a reference to them.  sidestep this problem by
strdup'ing the topic and brokers strings
2015-04-29 14:33:58 -07:00
R. Tyler Croy a3d8998a6f Image and link, DUH 2015-04-28 15:53:14 -07:00
R. Tyler Croy 76e8841998 Modify the build badge to point to the right travis project 2015-04-28 15:52:12 -07:00
R. Tyler Croy 4aef448dbc Merge pull request #95 from zendesk/mri_offsets
mri, initial offsets
2015-04-28 15:41:33 -07:00
Ben Osheroff 3fbe6969fb update tests with InvalidOffsetError 2015-04-28 15:14:14 -07:00
Ben Osheroff 8832ad28fd update rdoc section with :offset documentation 2015-04-28 11:52:16 -07:00
Ben Osheroff 8e89b75801 add a type to the invalid offset error 2015-04-28 11:50:28 -07:00
R. Tyler Croy e872906465 Merge pull request #92 from zendesk/fix_gvl
use rb_thread_call_without_gvl
2015-04-28 11:39:31 -07:00
Ben Osheroff 4f4e3f9b55 add some documentation to the new MRI consumer functions 2015-04-28 11:07:33 -07:00
Ben Osheroff 8857531cb7 add a constant for the time we ignore the gvl's interrupt requests 2015-04-28 11:06:34 -07:00
Ben Osheroff 752123b83e allow choosing of an inital offset in the MRI consumer 2015-04-28 10:17:09 -07:00
Ben Osheroff 21190d7acd randomize integration test topic 2015-04-28 10:09:30 -07:00
Ben Osheroff 8b7a31a232 add mri script 2015-04-28 10:09:02 -07:00
Ben Osheroff 784a7f3afe 1.9.3 compatibility 2015-04-27 12:32:58 -07:00
R. Tyler Croy dd25bc9586 Merge pull request #94 from zendesk/unify_initialize
Unify Consumer#initialize
2015-04-27 11:16:26 -07:00
Ben Osheroff 71c21d327e delete options in Consumer#initialize before passing along 2015-04-27 10:12:31 -07:00
Ben Osheroff 6db14ceeb7 version 0.23.0 2015-04-27 09:54:02 -07:00
Ben Osheroff 18c73f3f82 update README.md with new consumer info 2015-04-27 09:37:53 -07:00
Ben Osheroff 3792ee206b unify jruby/mri Consumer#initialize
While we do require different options between jruby & mri, there is a
common "topic" option.  The rest we pass in the options hash.
2015-04-27 09:32:16 -07:00
Ben Osheroff d579f2f8ec use rb_thread_call_without_gvl
this allows threaded code on modern (>=2.0) rubies working.  Also,
switch to the single-message form of the rd_kafka call -- the callback
form isn't safe to run without the GVL held, as it enters the ruby
interpreter in rb_yield().
2015-04-21 14:02:48 -07:00
R. Tyler Croy 0690634e4c Reference the appropriate gemspec for releasing 2015-04-09 11:35:48 -07:00
R. Tyler Croy e99c657144 Add suppor for auto-releasing to rubygems.org from travis 2015-04-08 12:55:19 -07:00
R. Tyler Croy f3f23965bd Bump a minor version for an API addition 2015-04-06 17:42:49 -07:00
R. Tyler Croy 9514a82a9d Merge pull request #89 from lsb/master
Add support for a partition key for producers
2015-04-06 17:41:47 -07:00
Lee Butterman f059643efc Add support for a partition key for producers.
Fixes lookout/Hermann#88
2015-04-06 17:35:38 -07:00
R. Tyler Croy 911b527b55 Merge pull request #90 from lookout/add-large-file
Add large file support
2015-04-04 12:38:47 -07:00
jway 96c0a74bf5 0.20.4 add large file support, fix bug passing options 2015-04-04 11:47:29 -07:00
R. Tyler Croy 17a4dba8d2 Merge pull request #86 from phrinx/master
Cleanup jar dependencies
2015-03-28 09:59:12 -07:00
Dirk Koehler 3b03658220 Bring back Jarfile and remove curator from dependency 2015-03-27 17:25:31 -07:00
Dirk Koehler 70f52204c7 Upgrade version to 0.20.3 2015-03-26 23:06:15 -07:00
Dirk Koehler 163c9d70c6 Cleanup jar dependencies
- move Jarfile dependency into gemspec
- upgrade curator to 2.7.1
- fix tests
- remove transient dependencies
2015-03-26 22:58:13 -07:00
R. Tyler Croy 5f783476f8 Bump to 0.20.2 for release 2015-02-23 15:03:07 -08:00
R. Tyler Croy 9dd7152d44 Merge pull request #77 from rb2k/patch-1
Fix MRI documentation in consumer.rb
2014-12-15 08:34:39 -08:00
Marc Seeger b7c35cb78c Fix MRI documentation in consumer.rb 2014-12-14 21:06:11 -05:00
R. Tyler Croy 4661aa75b6 I don't consider this alpha stage anymore 2014-12-14 10:27:43 -08:00
R. Tyler Croy aeaec0269c Merge pull request #76 from rtyler/issues/75-native-zookeeper
Implement a Java-native Zookeeper interface with Curator
2014-11-21 21:01:24 -08:00
R. Tyler Croy 495ac2687a Refactor out the block support from #each_brokers and bring back `timeout` for the ZkGemImpl
[1] pry(main)> d = Hermann::Discovery::Zookeeper.new('zk0.REDACTED.com:2181')
    => #<Hermann::Discovery::Zookeeper:0x57186526
     @impl=
      #<Hermann::Discovery::Zookeeper::CuratorImpl:0x391d1e33
       @curator=
        #<Java::OrgApacheCuratorFrameworkImps::CuratorFrameworkImpl:0x5287ba5f>>,
     @zookeepers="zk0.REDACTED.com:2181">
    [2] pry(main)> d.get_brokers
    log4j:WARN No appenders could be found for logger (org.apache.curator.framework.imps.CuratorFrameworkImpl).
    log4j:WARN Please initialize the log4j system properly.
    log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
    => ["kafka0.REDACTED.com:6667",
     "kafka1.REDACTED.com:6667"]
    [3] pry(main)>

    [1] pry(main)> d = Hermann::Discovery::Zookeeper.new('zk0.REDACTED.com:2181')
    => #<Hermann::Discovery::Zookeeper:0x7b6141f0
     @impl=
      #<Hermann::Discovery::Zookeeper::ZkGemImpl:0x4fb64a52
       @zookeepers="zk0.REDACTED.com:2181">,
     @zookeepers="zk0.REDACTED.com:2181">
    [2] pry(main)> d.get_brokers
    log4j:WARN No appenders could be found for logger (org.apache.zookeeper.ZooKeeper).
    log4j:WARN Please initialize the log4j system properly.
    log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
    => ["kafka0.REDACTED.com:6667",
     "kafka1.REDACTED.com:6667"]
    [3] pry(main)>
2014-11-21 20:39:11 -08:00
R. Tyler Croy 136e0ace47 Add suppot for optionally using Curator if it's on the classpath for broker discovery
This change makes the loading of the 'zk' gem optional and implicit, as well as
the reliance on Curator being available in the JRuby runtime's classpath.

If neither Zookeeper client implementation are available, an exception will be
raised when attmepting to use Zookeeper-based discovery

Fixes #75
2014-11-21 18:06:56 -08:00
R. Tyler Croy c46156a7d1 Move the `zk` gem from a explicit gem dependency to an implicit dependency
This will give us some optionality on how we want to reach out and contact
Zookeeper across multiple environments. See #75
2014-11-21 15:16:01 -08:00
R. Tyler Croy 8ed1ba91ba Merge pull request #74 from lookout/add-errors
include errors file
2014-11-17 17:09:47 -08:00
jway b4699845c5 include errors file 2014-11-17 17:01:44 -08:00
R. Tyler Croy 7fe085a0c0 Merge pull request #73 from lookout/fix-execeptioning
fixup exception handling in consumer
2014-11-14 07:53:55 -08:00
jway 6300705af9 fixup exception handling in consumer 2014-11-13 16:23:40 -08:00
james 4ef0bb0498 Merge pull request #71 from rtyler/log4j-upgrade
Force a more recent version of log4j as a jar dependency
2014-11-12 09:19:18 -08:00
R. Tyler Croy c6ab5e760c Force a more recent version of log4j as a jar dependency
The log4j has distributed some bad packages in the past but this release looks
safe to include
2014-11-12 08:53:44 -08:00
R. Tyler Croy d89d17119b Jump up to 0.20 2014-10-31 12:25:46 -07:00