wuwen5 opened a new issue, #10631:
URL: https://github.com/apache/dubbo/issues/10631

   <!-- If you need to report a security issue please visit 
https://github.com/apache/dubbo/security/policy -->
   
   - [x] I have searched the [issues](https://github.com/apache/dubbo/issues) 
of this repository and believe that this is not a duplicate.
   
   ### Environment
   
   * Dubbo version: 2.7.x,3.x
   * Operating System version: xxx
   * Java version: xxx
   
   ### Steps to reproduce this issue
   
   ```java
   
   @Bean
   public GenericService testApi() {
       ReferenceConfig<GenericService> config = new ReferenceConfig<>();
       config.setInterface("com.xxx.TestApi");
       config.setGeneric("true");
       //...
       return config.get()
   }
   
   
   @Autowired
   private TestApi testApi;
   
   @Test
   void testLocaDateTime() {
       Person obj = testApi.testApiQueryMethod();
   }
   ```
   
![image](https://user-images.githubusercontent.com/5037807/190542582-6c39ebe5-b1bc-41d6-bf2c-ac2bb5155db0.png)
   
   Unit testing for reproducible problems
   ```java
       @Test
       public void testJava8Time() {
           
           Object localDateTimeGen = PojoUtils.generalize(LocalDateTime.now());
           Object localDateTime = PojoUtils.realize(localDateTimeGen, 
LocalDateTime.class);
           assertEquals(localDateTimeGen, localDateTime.toString());
   
           Object localDateGen = PojoUtils.generalize(LocalDate.now());
           Object localDate = PojoUtils.realize(localDateGen, LocalDate.class);
           assertEquals(localDateGen, localDate.toString());
   
           Object localTimeGen = PojoUtils.generalize(LocalTime.now());
           Object localTime = PojoUtils.realize(localTimeGen, LocalTime.class);
           assertEquals(localTimeGen, localTime.toString());
       }
   ```
   
   ### Expected Behavior
   
   <!-- What do you expect from the above steps?-->
   
   ### Actual Behavior
   
   <!-- What actually happens? -->
   
   If there is an exception, please attach the exception trace:
   
   ```
   Just put your stack trace here!
   ```
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to