Skip to content

@SpringQueryMap not working with Java Record #1266

@marcusvoltolim

Description

@marcusvoltolim

Describe the bug
The problem is with @SpringQueryMap because it uses PageableSpringQueryMapEncoder which extends BeanQueryMapEncoder, limiting it to just these two encoders.

In feign.QueryMap, you can define mapEncoder as either BEAN or FIELD.

Image

Solution: Defines the Bean:

   @Bean
    public QueryMapEncoder feignQueryMapEncoderPageable() {
        return new FieldQueryMapEncoder();
    }

However, it is incompatible with Pageable throwing exception:

Request processing failed: java.lang.IllegalStateException: Duplicate key serialVersionUID (attempted merging values -4541509938956089562 and 1232825578694716871)] with root cause

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions