(0141621)
|
hgbot
|
2022-10-04 08:19
|
|
Directly closing issue as related merge request is already approved.
Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: 83995fe261a9eaeeae0e83108785e94803d48c85
Author: Asier Lostalé <asier.lostale@openbravo.com>
Date: 04-10-2022 06:19:26
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/83995fe261a9eaeeae0e83108785e94803d48c85 [^]
fixes ISSUE-49435: prevents using legacy ThreadGroup
The only direct use in the code was to assign the newly created thread
to the group, which was obtainged from the current thread that was
creaing the new thread.
The Thread super constructor we are using Thread(ThreadGroup, Runnable, String name, long)
documents [1] that if the group is null and there is no security manager,
the group is set to the current thread's thread group. Which is, in
practice, the same that was done before. Also the stackSize parameter
was always 0 which indicates to be ignored.
Taking into account all this, it is possible to use the simpler
constructor Thread(Runnable target, String name).
---
[1] https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Thread.html#%3Cinit%3E(java.lang.ThreadGroup,java.lang.Runnable,java.lang.String,long) [^]
---
M src/org/openbravo/cluster/ClusterServiceManager.java
M src/org/openbravo/service/importprocess/ImportEntryManager.java
---
|
|