Java 应用程序-获取错误“;此插座已由另一方端接;在实际设备上执行并行执行时

Java 应用程序-获取错误“;此插座已由另一方端接;在实际设备上执行并行执行时,java,android,appium,appium-android,Java,Android,Appium,Appium Android,我们的目标是在5台物理设备上并行运行测试脚本。我们正在启动具有5个不同端口的appium服务器,所有5个设备都连接在一个USB集线器中 如果我们确实在关闭设备后启动,然后再打开,它可以正常工作一次 但当我们再次运行它时,它开始抛出错误“此套接字已被另一方终止” 我们在启动appium服务器时尝试了“抑制adb杀死服务器”,但它仍然会继续关闭设备上的应用程序。测试脚本仅在一台设备上正常运行 错误日志: Sending command to android: {"cmd":"shutdown"} [

我们的目标是在5台物理设备上并行运行测试脚本。我们正在启动具有5个不同端口的appium服务器,所有5个设备都连接在一个USB集线器中

如果我们确实在关闭设备后启动,然后再打开,它可以正常工作一次

但当我们再次运行它时,它开始抛出错误“此套接字已被另一方终止”

我们在启动appium服务器时尝试了“抑制adb杀死服务器”,但它仍然会继续关闭设备上的应用程序。测试脚本仅在一台设备上正常运行

错误日志:

Sending command to android: {"cmd":"shutdown"}
[Appium] Had trouble ending session 514a0afc-a0e7-4205-ba39-ac93650bac9d: Android bootstrap socket crashed: Error: This socket has been ended by the other party
[debug] [BaseDriver] Event 'quitSessionFinished' logged at 1560747742093 (10:32:22 GMT+0530 (India Standard Time))
[debug] [W3C (514a0afc)] Encountered internal error running command: Error: Android bootstrap socket crashed: Error: This socket has been ended by the other party
[debug] [W3C (514a0afc)]     at Socket.socketClient.on.err (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/appium-android-driver/lib/bootstrap.js:97:21)
[debug] [W3C (514a0afc)]     at Socket.emit (events.js:193:13)
[debug] [W3C (514a0afc)]     at Socket.writeAfterFIN [as write] (net.js:406:8)
[debug] [W3C (514a0afc)]     at write (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/appium-android-driver/lib/bootstrap.js:122:25)
[debug] [W3C (514a0afc)]     at Promise._execute (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/bluebird/js/release/debuggability.js:313:9)
[debug] [W3C (514a0afc)]     at Promise._resolveFromExecutor (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/bluebird/js/release/promise.js:483:18)
[debug] [W3C (514a0afc)]     at new Promise (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/bluebird/js/release/promise.js:79:10)
[debug] [W3C (514a0afc)]     at AndroidBootstrap.sendCommand (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/appium-android-driver/lib/bootstrap.js:118:18)
[debug] [W3C (514a0afc)]     at AndroidBootstrap.sendCommand [as shutdown] (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/appium-android-driver/lib/bootstrap.js:173:18)
[debug] [W3C (514a0afc)]     at AndroidDriver.shutdown [as deleteSession] (/home/palashjain/node-v11.14.0-linux-x64/lib/node_modules/appium/node_modules/appium-android-driver/lib/driver.js:412:28)
请让我知道,如果你需要任何更多的信息来理解这个问题