Class PerformanceTests
java.lang.Object
test.de.iip_ecosphere.platform.support.TestWithPlugin
test.de.iip_ecosphere.platform.support.aas.TestWithPlugin
de.iip_ecosphere.platform.deviceMgt.PerformanceTests
public class PerformanceTests
extends test.de.iip_ecosphere.platform.support.aas.TestWithPlugin
Performance tests.
- Author:
- Dennis Pidun, University of Hildesheim
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static de.iip_ecosphere.platform.support.aas.Aasprivate static de.iip_ecosphere.platform.support.Serverprivate static de.iip_ecosphere.platform.support.ServerFields inherited from class test.de.iip_ecosphere.platform.support.TestWithPlugin
PROP_AAS_PLUGIN -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate longadd(List<String> ids, de.iip_ecosphere.platform.deviceMgt.registry.DeviceRegistryClient deviceRegistryClient) Adds devices based on their ids.voidTests mass addition of devices.voidTests adding a single device.private voidcreateDevices(List<String> ids) Creates devices for the givenids.generateIds(int count) Creates a sequence of ids.private longremove(List<String> ids, de.iip_ecosphere.platform.deviceMgt.registry.DeviceRegistryClient deviceRegistryClient) Removes devices based on their ids.voidTests mass removal of devices.voidTests the removal of a device.static voidstartup()Initializes the test.Methods inherited from class test.de.iip_ecosphere.platform.support.aas.TestWithPlugin
setAasPluginId, setup, setupAASPluginsMethods inherited from class test.de.iip_ecosphere.platform.support.TestWithPlugin
addPluginLocation, addRunAfterLoading, clear, enableLocalPlugins, loadPlugins, setInstallDir
-
Field Details
-
aas
private static de.iip_ecosphere.platform.support.aas.Aas aas -
implServer
private static de.iip_ecosphere.platform.support.Server implServer -
aasServer
private static de.iip_ecosphere.platform.support.Server aasServer
-
-
Constructor Details
-
PerformanceTests
public PerformanceTests()
-
-
Method Details
-
startup
Initializes the test.- Throws:
IOException- shall not occur
-
addDevice_single
Tests adding a single device.- Throws:
IOException- in case of IO problems, shall not occur
-
addDevice_mass
Tests mass addition of devices.- Throws:
IOException- in case of IO problems, shall not occur
-
removeDevice_single
Tests the removal of a device.- Throws:
IOException- in case of IO problems, shall not occur
-
removeDevice_mass
Tests mass removal of devices.- Throws:
IOException- in case of IO problems, shall not occurInterruptedException- in case of timeouts, shall not occur
-
add
private long add(List<String> ids, de.iip_ecosphere.platform.deviceMgt.registry.DeviceRegistryClient deviceRegistryClient) Adds devices based on their ids.- Parameters:
ids- the idsdeviceRegistryClient- the device registry client to test- Returns:
- the elapsed wall time [ms]
-
remove
private long remove(List<String> ids, de.iip_ecosphere.platform.deviceMgt.registry.DeviceRegistryClient deviceRegistryClient) Removes devices based on their ids.- Parameters:
ids- the idsdeviceRegistryClient- the device registry client to test- Returns:
- the elapsed wall time [ms]
-
generateIds
Creates a sequence of ids.- Parameters:
count- the number of ids to create- Returns:
- the created ids
-
createDevices
Creates devices for the givenids.- Parameters:
ids- the device identifiers- Throws:
IOException- if creation fails
-