tikafu commented on issue #21891:
URL: https://github.com/apache/pulsar/issues/21891#issuecomment-1902979423

   > I also noticed in your screenshots that you are using Pulsar 2.6.3 . That 
version contains quite a few severe security vulnerabilities (see 
https://pulsar.apache.org/security/ for some, in addition I think there's also 
Log4Shell) and isn't supported or maintained. It's better to upgrade any 
production systems to supported versions to get security fixes and other bug 
fixes.
   
   @lhotari Well, I'd like to reproduce this issue with the latest version of 
pulsar released and jdk-17.0.10.
   
   Step1. Show the version of JVM and pulsar.
   <img width="597" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/b050b9ae-ec11-47e5-adb0-c95210a497dc";>
   
   @Step2. Set the timezone to Asia/Shanghai and start broker.
   <img width="1351" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/eb6f7fb4-9fc4-4999-a29b-0d0980d105ec";>
   
   Step3. Show the JVM version of pulsar client.
   <img width="1439" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/38c14ca6-1e83-41bd-be1f-26cb0c25e782";>
   
   Step4. Produce a message to the broker with java client sdk. Notice that the 
timezone of the client is Asia/Shanghai, too.
   <img width="1439" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/a105978f-4334-489a-a277-dee7fba2c410";>
   The message id is 15:0:-1.
   
   Step5. Consume a message print publish time to console.Notice that the 
timezone of the client is Asia/Shanghai, too.
   <img width="1439" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/2b8fc0f6-ed33-485e-a2a9-66bdfe4a5e61";>
   The publish time is 1705890250190.
   
   Step6. Get the publish time of message with admin sdk. Notice that the 
timezone of the client is Asia/Shanghai, too.
   <img width="1439" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/10e97fa2-bb74-4b0d-98d3-4afd731ce1d5";>
   The publish time is 1705890250190, too. Everything is ok up to now.
   
   Step7. Set the timezone to GMT and restart broker.
   <img width="1439" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/24e90fb3-f6d9-421e-98c1-c6fbe73a29bf";>
   
   Step8. Consume the same message print publish time to console.Notice that 
the timezone of the client is still Asia/Shanghai.
   <img width="1439" alt="image" 
src="https://github.com/apache/pulsar/assets/10616763/9593d1fb-d75f-4265-96b0-80a827e046c6";>
   The publish time is 1705890250190, which is the same as before.
   
   Step9. Get the publish time of message with admin sdk. Notice that the 
timezone of the client is still Asia/Shanghai.
   
   
   
   
   
   
   > @tikafu Just wondering if this is a JVM bug? You seem to be running the 
client tests with 1.8.0_201 which was released January 15, 2019, over 5 years 
ago. Could you test with a recent JVM version? If you are stuck on Java 8, 
please use a recent version from Eclipse Temurin (or others), 
https://adoptium.net/temurin/releases/?version=8 .
   
   @lhotari OK, I will have a test with a recent JVM version and a recent 
pulsar version.


-- 
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]

Reply via email to