Skip to main content

Appium Multi Region (Mobile)

There is an option to start Appium session using region address.

AndroidDriver driver = new AndroidDriver(new URL("https://ukregion.experitest.com/wd/hub"), dc);
IOSDriver driver = new IOSDriver(new URL("https://ukregion.experitest.com/wd/hub"), dc);

When starting session using region address:

  1. Only devices located in provided region can be used.

  2. Test execution will be faster since command are executed on region components.

It is still possible to start Appium session using cloud address (same as before 21.10)

AndroidDriver driver = new AndroidDriver(new URL("https://uscloud.experitest.com/wd/hub"), dc);
IOSDriver driver = new IOSDriver(new URL("https://uscloud.experitest.com/wd/hub"), dc);

When starting session using cloud address:

  1. Devices in all regions can be used.

  2. Test execution will be faster for devices located in master region.

  3. Test execution will be slower for devices located in remote (other) regions.

Recommendation

For better performance users should choose the cloud region with the lowest latency from client machines where Appium tests are running.

Regions addresses can be provided by cloud administrator

Architecture

The new architecture has 2 goals:

  1. Reduce the load on cloud server.

  2. Improve test execution performance on devices in remote regions (when client is located in the same region).

Appium commands flow (except for starting and ending Appium session)

Address used to create Appium DriverUsed deviceResultAppium command flow
Cloud addressDevice from master regionRecommended. Better performance.Appium Client → Master region proxy → Device Host Machine
Cloud addressDevice from remote regionNot recommended. Slower.Appium Client → Master region proxy → Cloud server → Remote Region Proxy → Device Host Machine
Region addressDevice from the same regionRecommended. Better performance.Appium Client → Remote region proxy → Device Host Machine
Region addressDevice from different regionNot supported. Device will not be found.