Skip to content
View 1. setVariable.java
/**
* Set the given variable index into the specified object. The "real" class
* and index are pass in to provide functional access.
*
* @param self the object into which to set the variable
* @param realClass the "real" class for the object
* @param index the index of the variable
* @param value the variable's value
*/
public static void setVariable(RubyBasicObject self, RubyClass realClass, int index, Object value) {
View gist:6f5ddeb9cbad33ed155d
AppleCare
bready
checkins
cuppa
daemonization
Ducktales
en
fam
Grey
hardware-accelerated
View jruby_9000.md

The complete version of this post is available on the JRuby blog.

(JRuby is an implementation of the Ruby programming language atop the Java virtual machine, bringing true parallelism, increased performance, and world-class GC to the Ruby world.)

JRuby 9000 is the ninth major release of JRuby. We opted to go with 9000 as a code name and 9.0.0.0 as a version number to separate it from Ruby's version numbers (1.8, 1.9, 2.0 etc).

JRuby 9000 represents years of work by dozens of contributors. It is the single largest JRuby release we've ever done.

  • Compatibility is now up to Ruby 2.2 specification, a leap forward from JRuby 1.7's compatibility with Ruby 1.9.3. This includes all language and syntax features and many updates to core libraries.
  • The execution runtime has been completely rewritten over the past five years, enabling anyone who has taken a college compilers course to contribute help improve JRuby performance.
View Gemfile
source 'https://rubygems.org'
gem 'sequel'
gem 'progress_bar'
gem 'pg'
gem 'aws-sdk'
gem 'oga'
View gist:1900d41e760821fbedf8
diff --git a/src/main/java/org/jruby/ext/openssl/SSL.java b/src/main/java/org/jruby/ext/openssl/SSL.java
index 5bbc76d..79f12b7 100644
--- a/src/main/java/org/jruby/ext/openssl/SSL.java
+++ b/src/main/java/org/jruby/ext/openssl/SSL.java
@@ -183,7 +183,7 @@ public class SSL {
if ( errorClass == null ) { // < Ruby 2.0
errorClass = _SSL(runtime).getClass("SSLError"); // fallback
}
- return Utils.newError(runtime, errorClass, message, false);
+ return Utils.newLightweightError(runtime, errorClass, message, false);
View gist:317e7bf0617cff8e92e7
diff --git a/lib/ruby/stdlib/matrix.rb b/lib/ruby/stdlib/matrix.rb
index fb98d09..b387069 100644
--- a/lib/ruby/stdlib/matrix.rb
+++ b/lib/ruby/stdlib/matrix.rb
@@ -368,14 +368,16 @@ class Matrix
#
# Returns element (+i+,+j+) of the matrix. That is: row +i+, column +j+.
#
+ NIL_ARY = []
+ NIL_ARY_PROC = proc {NIL_ARY}
View gist:5d0ed029532d745c7fd7
[] ~/projects/jruby/fea3892507db7bf3d1d0 $ rvm jruby-1.7.20 do jruby filter_ips.rb
jruby 1.7.20 (1.9.3p551) 2015-05-04 3086e6a on Java HotSpot(TM) 64-Bit Server VM 1.8.0_45-b14 +jit [darwin-x86_64]
Calculating -------------------------------------
kalman 434.000 i/100ms
-------------------------------------------------
kalman 8.971k (± 7.5%) i/s - 178.374k
[] ~/projects/jruby/fea3892507db7bf3d1d0 $ jruby filter_ips.rb
jruby 9.0.0.0-SNAPSHOT (2.2.2) 2015-07-06 bce9d5c Java HotSpot(TM) 64-Bit Server VM 25.45-b02 on 1.8.0_45-b14 +jit [darwin-x86_64]
Calculating -------------------------------------
View gist:6272d168cf165ddf675f
diff --git a/net/http.rb b/net/http.rb
index 18e7ed0..aee7bf6 100644
--- a/net/http.rb
+++ b/net/http.rb
@@ -592,41 +592,41 @@ module Net #:nodoc:
# The +address+ should be a DNS hostname or IP address, the +port+ is the
# port the server operates on. If no +port+ is given the default port for
# HTTP or HTTPS is used.
#
# If none of the +p_+ arguments are given, the proxy host and port are
View gist:c2bff81379844624a7c2
2015-05-28T14:11:20.726-05:00: IRScope: nested_ensures.rb:0 _transaction
0 %self = recv_self()
1 %v_0 = load_implicit_closure()
2 %current_scope = copy(scope<0>)
3 %current_module = copy(module<0>)
4 check_arity(;req: 1, opt: 1, *r: false, kw: false)
5 conn(0:0) = recv_pre_reqd_arg()
6 opts(0:1) = recv_opt_arg(;index:0, req: 1, pre: 1)
7 bne(LBL_0:11, opts(0:1), %undefined)
8 %v_3 = search_const(%current_scope ;name: OPTS, no_priv: false)
View gist:7c7c35f6b1f0df68d717
[] ~/projects/jruby $ jruby -e '[BasicObject.new].flatten!'
NoMethodError: undefined method `respond_to?' for #<BasicObject:0x73846619>
flatten! at org/jruby/RubyArray.java:2844
<top> at -e:1
[] ~/projects/jruby $ jruby -Xbacktrace.style=full -e '[BasicObject.new].flatten!'
NoMethodError: undefined method `respond_to?' for #<BasicObject:0x73846619>
getStackTrace at java/lang/Thread.java:1552
getBacktraceData at org/jruby/runtime/backtrace/TraceType.java:183
getBacktrace at org/jruby/runtime/backtrace/TraceType.java:47
Something went wrong with that request. Please try again.