@@ -79,4 +79,46 @@ As there are quite a few things to keep in mind, we list here the most important
7979 of the SUT under "cs", eg, "jdk_17_maven/cs/grpc/NAME" would lead to embedded driver be under
8080 "jdk_17_maven/em/embedded/grpc/NAME".
8181
82- - TODO
82+ - Maven: the artifactId for the new modules follow the same convention of using same folder names separated with "-",
83+ eg "evomaster-benchmark-jdk17-em-embedded-NAME" for an embedded driver under JDK 17.
84+
85+ - EMBEDDED: the driver should be called "EmbeddedEvoMasterController", under the package "em.embedded.X", where X is the
86+ main package name of the SUT.
87+ Should be under "src/main" and not "src/test".
88+ The pom file needs to import 2 dependencies:
89+ 1) EM dependencies
90+ 2) SUT as a library
91+ Regarding (1), this should be done by default in the pom file of "jdk_X_Y/cs".
92+ If you make a new "jdk_X_Y", then you need to copy&paste from another top module (settings are the same).
93+ Note, you might still want to override some dependencies in case of library conflicts, eg, you can resolve some of
94+ those issues by redefining the dependency imports by using <exclusions> tags.
95+ Regarding (2), this might be problematic if the default settings of the SUT do build a uber JAR that use a custom
96+ classloader, ie, the typical case of SpringBoot applications (will need to check if same issues with other frameworks
97+ such as Micronaut).
98+ Solving this "might" (eg depending on SpringBoot version) require modifications to the pom.xml (in case of Maven) of the SUT.
99+ In particular, might need to remove the <parent> declaration, and rather include it as a pom import
100+ under the <dependencyManagement> (that would fix all version issues for dependencies, but not for plugins... which
101+ would need to be fixed manually).
102+ Then, in the plugin used for creating the uber JAR, need to make sure to still build the original JAR as well
103+ (so need 2 different names, default based on module for original, and modified name for uber JAR).
104+ Note: for the actual writing of the "EmbeddedEvoMasterController", you can see the EM documentation for it.
105+
106+ - EXTERNAL: first, need to make sure to build an uber JAR in the SUT.
107+ It MUST BE in the form "NAME-sut.jar". Eg, for SpringBoot you can have a setting like:
108+ <configuration>
109+ <finalName>NAME</finalName>
110+ <classifier>sut</classifier>
111+ </configuration>
112+ (btw, recall that NAME is just a placeholder for the actual name...)
113+ The driver "ExternalEvoMasterController" needs to be under the package "em.external.PACKAGE", in similar way as
114+ for embedded driver.
115+ Unfortunately, we currently have no documentation on how to write External Drivers.
116+ An important difference here is that we need to build an uber JAR of the driver itself, named NAME-evomaster-runner.jar.
117+ This is done with the "maven-shade-plugin" plugin (can copy&paste an existing one, and update names in it).
118+ Those JAR files are needed by "dist.py", discussed next, to be able to run experiments.
119+
120+ - Distribution: the "dist.py" file needs to be updated with the new API. Usually, this is just adding 2 lines, one in
121+ which NAME-sut.jar is copied over into the "dist" folder, and one for NAME-evomaster-runner.jar
122+
123+ - If the SUT is a REST API, need to add its OpenAPI schema into "openapi-swagger" folder
124+
0 commit comments