It requires a little boilerplate but jruby works well and is reasonably performant if you precompile the ruby:<p><pre><code>  require &#x27;java&#x27;

  java_import &#x27;com.amazonaws.services.lambda.runtime.Context&#x27;
  java_import &#x27;java.util.Map&#x27;
   
  class Main
    java_signature &#x27;static String handler(Map&lt;String,String&gt; args, Context context)&#x27;
    def self.handler(args, context)
      puts &quot;hello world&quot;
    end
  end

  # jrubyc --java main.rb</code></pre>