Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bytecode enhancement on handling returned Result failure on HelloWorld demo #1

Closed
greenlaw110 opened this issue May 25, 2015 · 0 comments
Assignees
Labels

Comments

@greenlaw110
Copy link
Contributor

The working code is:

    @GetAction("/greeting")
    public Result greeting(String who, int age) {
        return render(who, age);
    }

As I update it as

    @GetAction("/greeting")
    public void greeting(String who, int age) {
        render(who, age);
    }

It raises the follow error:

java.lang.VerifyError: Operand stack overflow
Exception Details:
  Location:
    act/fsa/helloworld/HelloWorldApp.greeting(Ljava/lang/String;I)V @10: ldc
  Reason:
    Exceeded max stack size.
  Current Frame:
    bci: @10
    flags: { }
    locals: { 'act/fsa/helloworld/HelloWorldApp', 'java/lang/String', integer }
    stack: { '[Ljava/lang/Object;', '[Ljava/lang/Object;', integer, 'act/app/AppContext' }
  Bytecode:
    0000000: 05bd 0004 5903 2ab4 002a 1255 1cb8 005b
    0000010: b600 5f12 612b b600 5f12 63b6 0067 572b
    0000020: 5359 041c b800 5b53 b800 6bbf          

        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:274)
        at org.osgl._.classForName(_.java:4586)
        at act.handler.builtin.controller.impl.ReflectedHandlerInvoker.<init>(ReflectedHandlerInvoker.java:52)
        at act.handler.builtin.controller.impl.ReflectedHandlerInvoker.createControllerAction(ReflectedHandlerInvoker.java:206)
        at act.Act$Mode.createRequestHandler(Act.java:70)
        at act.handler.builtin.controller.RequestHandlerProxy.generateHandlers(RequestHandlerProxy.java:216)
        at act.handler.builtin.controller.RequestHandlerProxy.ensureAgentsReady(RequestHandlerProxy.java:193)
        at act.handler.builtin.controller.RequestHandlerProxy.handle(RequestHandlerProxy.java:117)
        at act.handler.DelegateRequestHandler.handle(DelegateRequestHandler.java:18)
        at act.route.Router$ContextualHandler.handle(Router.java:514)
        at act.xio.NetworkClient.handle(NetworkClient.java:40)
        at act.xio.undertow.ActHttpHandler.handleRequest(ActHttpHandler.java:27)
        at io.undertow.server.Connectors.executeRootHandler(Connectors.java:197)
        at io.undertow.server.protocol.http.HttpReadListener.handleEventWithNoRunningRequest(HttpReadListener.java:181)
        at io.undertow.server.protocol.http.HttpReadListener.handleEvent(HttpReadListener.java:108)
        at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:130)
        at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:81)
        at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:45)
        at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
        at org.xnio.ChannelListeners$10.handleEvent(ChannelListeners.java:291)
        at org.xnio.ChannelListeners$10.handleEvent(ChannelListeners.java:286)
        at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
        at org.xnio.nio.NioTcpServerHandle.handleReady(NioTcpServerHandle.java:53)
        at org.xnio.nio.WorkerThread.run(WorkerThread.java:539)
@greenlaw110 greenlaw110 self-assigned this May 25, 2015
greenlaw110 pushed a commit that referenced this issue Jan 16, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant