Skip to content

bug: 在PluginFilter类中通过requiredRespBody()方法设置为true后,在插件中调用PostRequest..getUpstreamHeaders()方法会偶现(概率很高)报错java.lang.IndexOutOfBoundsException: null #234

@beginnerWJC

Description

@beginnerWJC

Issue description

在PluginFilter类中通过requiredRespBody()方法设置为true后,在插件中调用PostRequest..getUpstreamHeaders()方法会偶现(概率很高)报错java.lang.IndexOutOfBoundsException: null

Environment

  • apisix-java-plugin-runner 0.4.0
  • apisix 3.2.0
  • apisix-dashboard 3.0.0

Minimal test code / Steps to reproduce the issue

1.通过apisix-dashboard创建路由使用ext-plugin-post-resp插件
image
2.写一个简单的java测试插件,并且设置requiredRespBody()和requiredBody()都为true
image
3.多次调用会发现很大概率会报错503
image
4.查看日志发现是getUpstreamHeaders()方法报错java.lang.IndexOutOfBoundsException: null
image

What's the actual result? (including assertion message & call stack if applicable)

What's the expected result?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions