Skip to content

Commit

Permalink
feat(sumo): support for sumo 1.19.0 (#365)
Browse files Browse the repository at this point in the history
* feat: added new TraCI version for sumo 1.19.0
* ci: use sumo 1.19.0
* fix: implementation of VehicleAdd is available since API 20
* ci: built docker image for 1.19.0
* docs: updated sumo version in README
* docs: updated SUMO version in README
  • Loading branch information
kschrab authored Nov 16, 2023
1 parent 13f0d12 commit a4f6c8f
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ kind: Pod
spec:
containers:
- name: maven-sumo
image: eclipsemosaic/mosaic-ci:jdk11-sumo-1.18.0
image: eclipsemosaic/mosaic-ci:jdk11-sumo-1.19.0
command:
- cat
tty: true
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ For further questions we are available via [email protected]
For a successful build you need the following software to be installed:

* **Maven 3.1.x** or higher.
* **Java 11, or 17** - We recommend using the [Adoptium OpenJDK (aka Eclipse Temurin)](https://adoptium.net/?variant=openjdk11).
* **SUMO 1.18.0** - Additionally, the environment variable `SUMO_HOME` should be configured properly.
* **Java 11**, 17, or 21 - We recommend using the [Adoptium OpenJDK (aka Eclipse Temurin)](https://adoptium.net/?variant=openjdk11).
* **SUMO 1.19.0** - Older versions > 1.2.0 are most probably supported, but not tested. The environment variable `SUMO_HOME` should be configured properly.

## Build

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ public enum SumoVersion {
SUMO_1_16_x("1.16.*", TraciVersion.API_20),
SUMO_1_17_x("1.17.*", TraciVersion.API_20),
SUMO_1_18_x("1.18.*", TraciVersion.API_20),
SUMO_1_19_x("1.19.*", TraciVersion.API_21),

/**
* the lowest version supported by this client.
Expand All @@ -52,7 +53,7 @@ public enum SumoVersion {
/**
* the highest version supported by this client.
*/
HIGHEST(SUMO_1_18_x.sumoVersion, SUMO_1_18_x.traciVersion);
HIGHEST(SUMO_1_19_x.sumoVersion, SUMO_1_19_x.traciVersion);

private final String sumoVersion;
private final TraciVersion traciVersion;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ public enum TraciVersion {
API_18(18),
API_19(19),
API_20(20),
API_21(21),

/**
* the lowest version supported by this client.
Expand All @@ -30,7 +31,7 @@ public enum TraciVersion {
/**
* the highest version supported by this client.
*/
HIGHEST(API_20.getApiVersion());
HIGHEST(API_21.getApiVersion());

private final int apiVersion;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public class VehicleAdd
*/
@SuppressWarnings("WeakerAccess")
public VehicleAdd() {
super(TraciVersion.HIGHEST);
super(TraciVersion.API_20);

write()
.command(CommandChangeVehicleValue.COMMAND)
Expand Down
2 changes: 1 addition & 1 deletion test/ci/ci-image-mvn-sumo/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ WORKDIR /home/jenkins
RUN apt-get update && \
apt-get install -y --allow-unauthenticated software-properties-common && \
# adjust this output string to bypass potential caches
echo "Installing SUMO 1.18.0" && \
echo "Installing SUMO 1.19.0" && \
add-apt-repository ppa:sumo/stable && \
apt-get install -y sumo

0 comments on commit a4f6c8f

Please sign in to comment.