You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by "ruqinhu (via GitHub)" <gi...@apache.org> on 2023/11/14 05:59:24 UTC

[PR] Optimize to final type [skywalking-java]

ruqinhu opened a new pull request, #648:
URL: https://github.com/apache/skywalking-java/pull/648

   Optimize to final type


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "wu-sheng (via GitHub)" <gi...@apache.org>.
wu-sheng commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1811990588

   I am not following. Instrument process only happens on booting and/or class first loaded.Nothing more.
   Do you have any evidence to prove the performance has been impacted?


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "ruqinhu (via GitHub)" <gi...@apache.org>.
ruqinhu commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1811988556

   > Why ClassNotFound is a high frequency thing?
   
   It is unnecessary to judge whether it is empty. Will JIT also optimize it?
   


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "wu-sheng (via GitHub)" <gi...@apache.org>.
wu-sheng commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1811995611

   We are happy to accept change if this thing really impacts perf.


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "ruqinhu (via GitHub)" <gi...@apache.org>.
ruqinhu commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1809663865

   > Why do you propose this change?
   
   Minimize mutability: When a variable is declared as final, its value cannot be changed once it has been initialized. This is useful for declaring constants or other values that should not be modified.


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "ruqinhu (via GitHub)" <gi...@apache.org>.
ruqinhu closed pull request #648: Optimize to final type
URL: https://github.com/apache/skywalking-java/pull/648


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "ruqinhu (via GitHub)" <gi...@apache.org>.
ruqinhu commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1811993037

   > I am not following. Instrument process only happens on booting and/or class first loaded.Nothing more. Do you have any evidence to prove the performance has been impacted?
   
   i see,


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "wu-sheng (via GitHub)" <gi...@apache.org>.
wu-sheng commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1809620928

   Why do you propose this change?


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "ruqinhu (via GitHub)" <gi...@apache.org>.
ruqinhu commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1809671486

   > In theory, it is. But usually, the compiler and JIT would do that automatically, as they detected no one is going to change that, it is safe to cache during process.
   > 
   > And the codes you changed seem to be not called in high frequency.
   
   Okay, then I'll turn it of
   


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "ruqinhu (via GitHub)" <gi...@apache.org>.
ruqinhu closed pull request #648: Optimize to final type
URL: https://github.com/apache/skywalking-java/pull/648


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "ruqinhu (via GitHub)" <gi...@apache.org>.
ruqinhu commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1811957393

   > In theory, it is. But usually, the compiler and JIT would do that automatically, as they detected no one is going to change that, it is safe to cache during process.
   > 
   > And the codes you changed seem to be not called in high frequency.
   
   org.apache.skywalking.apm.agent.core.plugin.loader.InterceptorInstanceLoader#load seem to  called in high frequency.
   
   Remove not used check, because Class.forName not find class, will throw ClassNotFoundException instead of null.


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "wu-sheng (via GitHub)" <gi...@apache.org>.
wu-sheng commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1811982200

   Why ClassNotFound is a high frequency thing?


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Optimize to final type [skywalking-java]

Posted by "wu-sheng (via GitHub)" <gi...@apache.org>.
wu-sheng commented on PR #648:
URL: https://github.com/apache/skywalking-java/pull/648#issuecomment-1809667212

   In theory, it is. But usually, the compiler and JIT would do that automatically, as they detected no one is going to change that, it is safe to cache during process.
   
   And the codes you changed seem to be not called in high frequency.


-- 
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: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org