mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
update netty — https://github.com/netty/netty/issues/2331
This commit is contained in:
@@ -44,9 +44,11 @@ public class Launcher {
|
||||
final URLClassLoader jpsLoader = new URLClassLoader(urls.toArray(new URL[urls.size()]), Launcher.class.getClassLoader());
|
||||
|
||||
// IDEA-120811; speeding up DefaultChannelIDd calculation for netty
|
||||
final String id = UUID.randomUUID().toString();
|
||||
System.setProperty("io.netty.machineId", id.substring(id.length() - 8));
|
||||
System.setProperty("io.netty.processId", Integer.toString(new Random().nextInt(65535)));
|
||||
if (Boolean.parseBoolean(System.getProperty("io.netty.random.id"))) {
|
||||
final String id = UUID.randomUUID().toString();
|
||||
System.setProperty("io.netty.machineId", id.substring(id.length() - 8));
|
||||
System.setProperty("io.netty.processId", Integer.toString(new Random().nextInt(65535)));
|
||||
}
|
||||
|
||||
final Class<?> mainClass = jpsLoader.loadClass(mainClassName);
|
||||
final Method mainMethod = mainClass.getMethod("main", String[].class);
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -17,6 +17,7 @@ package org.jetbrains.io;
|
||||
|
||||
import com.intellij.openapi.diagnostic.Logger;
|
||||
import com.intellij.openapi.util.ActionCallback;
|
||||
import com.intellij.util.SystemProperties;
|
||||
import io.netty.bootstrap.Bootstrap;
|
||||
import io.netty.bootstrap.BootstrapUtil;
|
||||
import io.netty.bootstrap.ServerBootstrap;
|
||||
@@ -44,9 +45,11 @@ public final class NettyUtil {
|
||||
|
||||
static {
|
||||
// IDEA-120811
|
||||
String id = UUID.randomUUID().toString();
|
||||
System.setProperty("io.netty.machineId", id.substring(id.length() - 8));
|
||||
System.setProperty("io.netty.processId", Integer.toString(new Random().nextInt(65535)));
|
||||
if (SystemProperties.getBooleanProperty("io.netty.random.id", false)) {
|
||||
String id = UUID.randomUUID().toString();
|
||||
System.setProperty("io.netty.machineId", id.substring(id.length() - 8));
|
||||
System.setProperty("io.netty.processId", Integer.toString(new Random().nextInt(65535)));
|
||||
}
|
||||
}
|
||||
|
||||
public static void log(Throwable throwable, Logger log) {
|
||||
|
||||
Reference in New Issue
Block a user