feign.codec.EncodeException: Type definition error: [simple type, class java.util.Collections$3]

Premise:
the feign call of the docking company recently involves the mutual call between two business systems, and I encountered the following errors in the process of processing, so I’ll take them out and record them

Error prompt

feign.codec.EncodeException: Type definition error: [simple type, class java.util.Collections$3]; nested exception is com.fasterxml.jackson.databind.exc.InvalidDefinitionException: No serializer found for… request

reflection

When I see the request, I think of the problem of request parameters. I don’t know what the problem is

I took a closer look at the exposed fegin client interface. The request object was passed in the interface. In order to be lazy, I didn’t write multiple method parameters
mborderservice service class

when I changed the code into multiple parameters and passed them directly, the problem was solved

client calling code, so there was no problem

Read More: