Skip to content

BaiduRpcProtocol第102行,会产生ClassCastException #325

Open

Description

@imqing

具体代码如下,其中的强转String会产生该问题:
requestMeta.addExtFieldsBuilder().setKey(kv.getKey()).setValue((String) kv.getValue());

Activity

  1. Reason94 commented on Sep 28, 2023

    @Reason94
    Collaborator

    目前brpc协议的extField默认只支持String类型,请问你是使用了别的类型吗?
    或者能提供个复现的代码吗?

  2. self-assigned this
    on Sep 28, 2023
  3. imqing commented on Feb 22, 2024

    @imqing
    Author

    目前brpc协议的extField默认只支持String类型,请问你是使用了别的类型吗? 或者能提供个复现的代码吗?

    是的,我当时用了非string 类型

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

questionFurther information is requested

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions