diff --git a/java/google/registry/rde/JSchModule.java b/java/google/registry/rde/JSchModule.java index 70c9ab7b8..93a885353 100644 --- a/java/google/registry/rde/JSchModule.java +++ b/java/google/registry/rde/JSchModule.java @@ -16,7 +16,6 @@ package google.registry.rde; import static java.nio.charset.StandardCharsets.UTF_8; -import com.google.appengine.api.ThreadManager; import com.jcraft.jsch.JSch; import com.jcraft.jsch.JSchException; import dagger.Module; @@ -33,7 +32,6 @@ public final class JSchModule { @Config("rdeSshIdentity") String identity, @Key("rdeSshClientPrivateKey") String privateKey, @Key("rdeSshClientPublicKey") String publicKey) { - applyAppEngineKludge(); JSch jsch = new JSch(); try { jsch.addIdentity( @@ -48,14 +46,4 @@ public final class JSchModule { JSch.setConfig("StrictHostKeyChecking", "no"); return jsch; } - - /** - * Overrides the threadFactory used in JSch and disable {@link Thread#setName(String)} in order to - * ensure GAE compatibility. By default it uses the default executor, which fails under GAE. This - * is currently a Google-specific patch that needs to be sent upstream. - */ - private static void applyAppEngineKludge() { - JSch.threadFactory = ThreadManager.currentRequestThreadFactory(); - JSch.useThreadNames = false; - } }