|
|
Here, I'll walk you through the java source code, responsible for starting the [AAS Server](What-am-I-looking-at-here#aas-server). Additional startup procedures are explained in the documentation for the [`start_component.sh`](TODO) and the [`run_demo.sh`](TODO) scripts.
|
|
|
Here, I'll walk you through the java source code, responsible for starting the [AAS Server](What-am-I-looking-at-here#aas-server). Additional startup procedures are explained in the documentation for the [`start_component.sh`](implementation/start_component.sh) and the [`run_demo.sh`](implementation/run_demo.sh) scripts.
|
|
|
|
|
|
The discussed file can be found [here](https://gitlab.hrz.tu-chemnitz.de/s6869070--tu-dresden.de/vws-spielwiese/-/blob/b1802bdd98650bdb666f03483f1e13c7f99bf4b8/basyx.lichterkette/src/main/java/de/olipar/basyx/lichterkette/AASServer.java).
|
|
|
The discussed file can be found [here](https://gitlab.hrz.tu-chemnitz.de/vws-demo/vws-spielwiese/-/blob/64e67bdaae14ef6945ab3e73b5a9c70c9c1ced67/basyx.lichterkette/src/main/java/de/olipar/basyx/lichterkette/AASServer.java).
|
|
|
|
|
|
This is very similar to the [AAS Registry starter](AAS-Registry-starter-walkthrough).
|
|
|
This is very similar to the [AAS Registry starter](implementation/AAS-Registry-starter-walkthrough).
|
|
|
|
|
|
We'll skip the license header, imports and comments, as they are either pretty much self explanatory or not the product of conscious development effort.
|
|
|
|
... | ... | @@ -21,13 +21,13 @@ We then define a `main`-method, as this class is executable. It will be called t |
|
|
final int HOSTPORT = Common.getHostPort();
|
|
|
logger.info("Local host port is set to " + HOSTPORT);
|
|
|
```
|
|
|
Here, we invoke the static method `getHostPort()` of the [`Common`-class](TODO). The port on which to host the AAS Server is grabbed from an environment variable, if present and set to a fallback value if not. The set port is then logged via the `Logger` object acquired above.
|
|
|
Here, we invoke the static method `getHostPort()` of the [`Common`-class](implementation/Common-class-walkthrough). The port on which to host the AAS Server is grabbed from an environment variable, if present and set to a fallback value if not. The set port is then logged via the `Logger` object acquired above.
|
|
|
|
|
|
```java
|
|
|
final String REGISTRYPATH = Common.getRegistryPath();
|
|
|
logger.info("Registry path set to " + REGISTRYPATH);
|
|
|
```
|
|
|
Here, the path to the registry is set via the similar to above. More details can be found in the walkthrough of the [`Common`-class](TODO).
|
|
|
Here, the path to the registry is set via the similar to above. More details can be found in the walkthrough of the [`Common`-class](implementation/Common-class-walkthrough).
|
|
|
|
|
|
```java
|
|
|
startAASServer(REGISTRYPATH, HOSTPORT);
|
... | ... | |