Details
-
Type:
Bug
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: JRuby 1.6.5
-
Fix Version/s: None
-
Component/s: Application Error
-
Labels:None
-
Environment:Google App Engine, appengine-java-sdk-1.5.5, jruby-rack-1.0.10.jar, jruby-jars-1.6.5
-
Number of attachments :
Description
When developing and testing locally it works OK. But when trying to deploy on the Google App Engine it triggers an exception:
javax.servlet.ServletContext log: Application Error
org.jruby.exceptions.RaiseException: Native Exception: 'class java.security.AccessControlException'; Message: access denied (java.lang.RuntimePermission getClassLoader); StackTrace: java.security.AccessControlException: access denied (java.lang.RuntimePermission getClassLoader)
at com.google.appengine.runtime.Request.process-0000000000000000(Request.java)
at java.lang.Class.getClassLoader(Class.java:437)
at org.jruby.javasupport.JavaClass.handleScalaSingletons(JavaClass.java:130)
at org.jruby.javasupport.JavaClass.setupClassMethods(JavaClass.java:1006)
at org.jruby.javasupport.JavaClass.access$700(JavaClass.java:99)
at org.jruby.javasupport.JavaClass$ClassInitializer.initialize(JavaClass.java:650)
at org.jruby.javasupport.JavaClass.setupProxy(JavaClass.java:689)
at org.jruby.javasupport.Java.createProxyClass(Java.java:520)
at org.jruby.javasupport.Java.getProxyClass(Java.java:449)
at org.jruby.javasupport.Java.getInstance(Java.java:358)
at org.jruby.javasupport.JavaUtil.convertJavaToUsableRubyObject(JavaUtil.java:165)
at org.jruby.javasupport.JavaMethod.convertReturn(JavaMethod.java:595)
at org.jruby.javasupport.JavaMethod.invokeDirectWithExceptionHandling(JavaMethod.java:528)
at org.jruby.javasupport.JavaMethod.invokeDirect(JavaMethod.java:380)
at org.jruby.java.invokers.InstanceMethodInvoker.call(InstanceMethodInvoker.java:59)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:167)
at org.jruby.ast.CallOneArgNode.interpret(CallOneArgNode.java:57)
at org.jruby.ast.DAsgnNode.interpret(DAsgnNode.java:110)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
at org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
at org.jruby.runtime.InterpretedBlock.evalBlockBody(InterpretedBlock.java:374)
at org.jruby.runtime.InterpretedBlock.yield(InterpretedBlock.java:347)
at org.jruby.runtime.InterpretedBlock.yield(InterpretedBlock.java:304)
at org.jruby.runtime.Block.yield(Block.java:130)
at org.jruby.ast.YieldNode.interpret(YieldNode.java:113)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.ast.WhileNode.interpret(WhileNode.java:131)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
at org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:169)
at org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:171)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:302)
at org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:144)
at org.jruby.runtime.callsite.CachingCallSite.callIter(CachingCallSite.java:153)
at org.jruby.ast.CallNoArgBlockNode.interpret(CallNoArgBlockNode.java:64)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
at org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:147)
at org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:163)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:292)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:135)
at org.jruby.ast.VCallNode.interpret(VCallNode.java:86)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
[snip. very long stack trace]
To reproduce it you could use the sample application I've uploaded to the Github and replace the JRuby-Jars with the 1.6.5 versions:
https://github.com/jpedrosa/app_engine_ruby_cupcake
Cheers,
Joao