This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[jabley@176282-app1 ruby-ffi~mercurial]$ jruby -rffi -d -e 'puts FFI::Platform::ARCH' | |
java.lang.NoClassDefFoundError: Could not initialize class com.sun.jna.Native | |
at com.sun.jna.NativeLibrary.<clinit>(NativeLibrary.java:55) | |
at org.jruby.ext.ffi.jna.DynamicLibrary.open(DynamicLibrary.java:59) | |
at org.jruby.ext.ffi.jna.DynamicLibrary$s_method_2_0$RUBYINVOKER$open.call(org/jruby/ext/ffi/jna/DynamicLibrary$s_method_2_0$RUBYINVOKER$open.gen) | |
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:293) | |
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:152) | |
at org.jruby.ast.CallTwoArgNode.interpret(CallTwoArgNode.java:59) | |
at org.jruby.ast.ConstDeclNode.interpret(ConstDeclNode.java:97) | |
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?> | |
<project> | |
<parent> | |
<artifactId>rails-ui</artifactId> | |
<groupId>com.example</groupId> | |
<version>1.0-SNAPSHOT</version> | |
</parent> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>com.example</groupId> | |
<artifactId>rails-ui-webapp</artifactId> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'java' | |
import org.apache.commons.lang.StringUtils | |
class UsersController < ApplicationController | |
# GET /users | |
# GET /users.xml | |
def index | |
@users = [] | |
@is_blank = StringUtils.isBlank("a".to_java_string) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'java' | |
import org.apache.commons.lang.StringUtils | |
class UsersController < ApplicationController | |
# GET /users | |
# GET /users.xml | |
def index | |
@users = [] | |
@is_blank = StringUtils.isBlank("a".to_java_string) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cat bench-hash-creation.rb | |
require 'benchmark' | |
n = 1_000_000 | |
Benchmark.bm do |x| | |
x.report('arrays') { | |
k = [] | |
v = [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16-Jul-2009 23:40:00 org.apache.catalina.core.ApplicationContext log | |
SEVERE: unable to create shared application instance | |
org.jruby.rack.RackInitializationException: no such file to load -- jopenssl | |
from file:/opt/apache-tomcat-6.0.18/webapps/fui/WEB-INF/lib/jruby-rack-0.9.4.jar!/jruby/rack/rails.rb:43:in `require_frameworks_with_servlet_env' | |
from /opt/tomcat/webapps/fui/WEB-INF/gems/gems/rails-2.3.2/lib/initializer.rb:134:in `process' | |
from /opt/tomcat/webapps/fui/WEB-INF/gems/gems/rails-2.3.2/lib/initializer.rb:113:in `run' | |
from /opt/tomcat/webapps/fui/WEB-INF/config/environment.rb:9 | |
from /opt/tomcat/webapps/fui/WEB-INF/config/environment.rb:26:in `load' | |
from file:/opt/apache-tomcat-6.0.18/webapps/fui/WEB-INF/lib/jruby-rack-0.9.4.jar!/jruby/rack/rails.rb:26:in `load_environment' | |
from file:/opt/apache-tomcat-6.0.18/webapps/fui/WEB-INF/lib/jruby-rack-0.9.4.jar!/jruby/rack/rails.rb:151:in `new' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ./rubyConvertToJava.sh | |
Initialized empty Git repository in /home/jabley/work/github/gist-154155/jruby/.git/ | |
remote: Counting objects: 110007, done. | |
remote: Compressing objects: 100% (28508/28508), done. | |
remote: Total 110007 (delta 76485), reused 109755 (delta 76233) | |
Receiving objects: 100% (110007/110007), 43.86 MiB | 95 KiB/s, done. | |
Resolving deltas: 100% (76485/76485), done. | |
Buildfile: build.xml | |
init: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cat target/surefire-reports/cuke4duke.internal.CucumberRunnerTest.txt | |
------------------------------------------------------------------------------- | |
Test set: cuke4duke.internal.CucumberRunnerTest | |
------------------------------------------------------------------------------- | |
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 1.772 sec <<< FAILURE! | |
shouldBeAbleToRunSingleFeature(cuke4duke.internal.CucumberRunnerTest) Time elapsed: 1.759 sec <<< ERROR! | |
org.apache.bsf.BSFException: Exception | |
at org.jruby.javasupport.bsf.JRubyEngine.exec(JRubyEngine.java:102) | |
at cuke4duke.internal.CucumberRunner.initializeCucumber(CucumberRunner.java:36) | |
at cuke4duke.internal.CucumberRunner.<init>(CucumberRunner.java:16) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cat target/surefire-reports/cuke4duke.junit.FeatureTest.txt | |
------------------------------------------------------------------------------- | |
Test set: cuke4duke.junit.FeatureTest | |
------------------------------------------------------------------------------- | |
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.016 sec <<< FAILURE! | |
initializationError(cuke4duke.junit.FeatureTest) Time elapsed: 0.001 sec <<< ERROR! | |
org.apache.bsf.BSFException: Exception | |
at org.jruby.javasupport.bsf.JRubyEngine.exec(JRubyEngine.java:102) | |
at cuke4duke.internal.CucumberRunner.initializeCucumber(CucumberRunner.java:36) | |
at cuke4duke.internal.CucumberRunner.<init>(CucumberRunner.java:16) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Initialized empty Git repository in /home/jabley/work/github/gist-154155/cucumber/.git/ | |
remote: Counting objects: 18583, done. | |
remote: Compressing objects: 100% (6411/6411), done. | |
remote: Total 18583 (delta 12708), reused 17034 (delta 11535) | |
Receiving objects: 100% (18583/18583), 3.91 MiB | 78 KiB/s, done. | |
Resolving deltas: 100% (12708/12708), done. | |
Note: moving to "v0.3.11" which isn't a local branch | |
If you want to create a new branch from this checkout, you may do so | |
(now or later) by using -b with the checkout command again. Example: | |
git checkout -b <new_branch_name> |
OlderNewer