restApi date conversion exception
yulinyanga opened this issue · 3 comments
Steps to reproduce
- camunda-platform-7-rest-client-spring-boot version: 7.17.2
- Camunda BPM version: 7.17.0
- JDK version: 1.8
- Operating system: windows 10
- Complete executable reproducer: nothing
- Steps: (what exactly are you doing with the above reproducer?)
Use the list (post) interface of TaskApiClient
It is found that the date format in the request parameter is "yyyy MM dd 'T'HH: mm: ss. SSXXX"
But the date format of camunda server is "yyyy MM dd 'T'HH: mm: ss. SSSZ"
An error is reported when sending the request: 400 Bad Request
I can't provide bean with date format serialization, because this will cause external task client date conversion error.
Is this a bug? What should I do?
thanks
Are you using the feign clients directly? I couldn't reproduce the error with an integration test using the camunda TaskService.
Do you include the jackson-datatype-jsr310 module for date time conversion in Jackson?
@yulinyanga Could you provide some more information on how you're using the library?
Are you using the feign clients directly? I couldn't reproduce the error with an integration test using the camunda TaskService. Do you include the jackson-datatype-jsr310 module for date time conversion in Jackson?
Yes, I use feign clients. And I use java8, not sure if this is relevant. I use jackson-datatype-jsr310 module.
@yulinyanga Could you provide some more information on how you're using the library?
My project dependcies :
<dependency> <groupId>org.camunda.bpm.springboot</groupId> <artifactId>camunda-bpm-spring-boot-starter-rest</artifactId> </dependency> <dependency> <groupId>org.camunda.bpm.springboot</groupId> <artifactId>camunda-bpm-spring-boot-starter-webapp</artifactId> </dependency> <dependency> <groupId>org.camunda.bpm</groupId> <artifactId>camunda-engine-plugin-connect</artifactId> </dependency> <dependency> <groupId>org.camunda.connect</groupId> <artifactId>camunda-connect-connectors-all</artifactId> </dependency> <dependency> <groupId>org.camunda.bpm</groupId> <artifactId>camunda-engine-plugin-spin</artifactId> </dependency> <dependency> <groupId>org.camunda.spin</groupId> <artifactId>camunda-spin-dataformat-all</artifactId> </dependency>
I have temporarily solved this problem,serialize the bean by providing a date,and external task client to configure the same date format.
thanks