How to reuse the existing wda agent

I run many test cases with appium on real iphone devices, every time i start a new test case, the appium will build a new wda, this wast a lot of time. but if i use the “usePrebuiltWDA”, appium is not able to connect to the
Anyone can help with this?

i make it in following way:

  1. build WDA following Full manual configuration ->
  2. caps:
// always
capabilities.setCapability(IOSMobileCapabilityType.USE_PREBUILT_WDA, true);
// when i install new version of app with this update WDA in case
capabilities.setCapability(IOSMobileCapabilityType.USE_NEW_WDA, true);
// in all other cases we should have 100% WDA installed on phone
capabilities.setCapability(IOSMobileCapabilityType.USE_NEW_WDA, false);

Thanks, however i found there’s some issue when i use full manual way to build wda…
Anyway I think I can try to use new wda for the first case, then for other test case i set use_prebuilt_wda to true