You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@rocketmq.apache.org by GitBox <gi...@apache.org> on 2022/01/06 12:48:27 UTC

[GitHub] [rocketmq] gogodjzhu opened a new issue #3719: [DISCUSS] Add a system property to override Runtime.getRuntime().availableProcessors()

gogodjzhu opened a new issue #3719:
URL: https://github.com/apache/rocketmq/issues/3719


   I deploy rocketmq in docker environment. While there are some properties which take the number of runtime processors as default. It causes the jvm to start up with the physical setting which is not suitable for my virtual host.
    
   I do know there are some ways to correct this, such as:
   1. add `-XX:ActiveProcessorCount=count` to start up. But only after jdk8u191
   2. upgrade jdk to jdk 11.
   However, it is hard to push such an upgrade in a big company like us. 
   
   Or 
   3. do some code to change all the properties that refer to runtime.
   It's too much work to do so and may not be suitable for different versions.
   
   So I suggest adding an optional system property to accomplish this. 
   
   Thx.
   Best regards.


-- 
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: dev-unsubscribe@rocketmq.apache.org

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



[GitHub] [rocketmq] Git-Yang commented on issue #3719: [DISCUSS] Add a system property to override Runtime.getRuntime().availableProcessors()

Posted by GitBox <gi...@apache.org>.
Git-Yang commented on issue #3719:
URL: https://github.com/apache/rocketmq/issues/3719#issuecomment-1008514680


   I think Runtime.getRuntime().availableProcessors() can be used as default, and supporting parameter configuration should solve your problem. 


-- 
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: dev-unsubscribe@rocketmq.apache.org

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



[GitHub] [rocketmq] Kvicii commented on issue #3719: [DISCUSS] Add a system property to override Runtime.getRuntime().availableProcessors()

Posted by GitBox <gi...@apache.org>.
Kvicii commented on issue #3719:
URL: https://github.com/apache/rocketmq/issues/3719#issuecomment-1020100984


   @Git-Yang well, I think the configuration class parameters should be more concise and concise, configuration parameters in code now appear in many places, Of course this is just my personal opinion😀


-- 
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: dev-unsubscribe@rocketmq.apache.org

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



[GitHub] [rocketmq] caigy commented on issue #3719: [DISCUSS] Add a system property to override Runtime.getRuntime().availableProcessors()

Posted by GitBox <gi...@apache.org>.
caigy commented on issue #3719:
URL: https://github.com/apache/rocketmq/issues/3719#issuecomment-1031043063


   As this problem occurs in docker environment, I think it would be more appropriate to upgrade the JDK version in container, other than change codes in application level. Because such uncompleted support to container in JDK does not only affect `Runtime.getRuntime().availableProcessors()`, but also ParallelGCThreads, CICompilerCount, etc.  
   
   BTW, it seems that this problem has resolved after jdk8u131: https://blogs.oracle.com/java/post/java-se-support-for-docker-cpu-and-memory-limits


-- 
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: dev-unsubscribe@rocketmq.apache.org

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