-
Notifications
You must be signed in to change notification settings - Fork 4
3. Initial data load
Elan Thangamani edited this page Aug 29, 2020
·
11 revisions
- The following properties would used to setup the initial data for the virtualized service.
virtualan.data.load=<file name from classpath>
- The following information added in the application.properties for the application startup.
server.port=8080
virtualan.datasource.driver-class-name=org.hsqldb.jdbcDriver
virtualan.datasource.jdbcurl=jdbc:hsqldb:mem:dataSource
virtualan.datasource.username=sa
virtualan.datasource.password=
virtualan.application.name=The Service Virtualization Product
virtualan.data.load=initial-load.json
- For the above sample initial-load.json is the file name should be a available in the classpath. Example file: https://github.com/virtualansoftware/virtualan/blob/master/samples/virtualan-openapi-rest/src/main/resources/initial-load.json
-
Using this How to populate the data in the system prepare the data and follow below process to download the JSON to be loaded..
-
Navigate to the following URL to load data using REST API : http://localhost:8080/swagger-ui/index.html?url=/yaml/VirtualService/virtualservices.yaml
-
Run the http://localhost:8080/virtualservices - Get all Mock service data and download the JSON output and That JSON directly loaded as the initial set of data.
-
Now Check-in the JSON in the Virtualized code repository and specify the file in the "virtualan.data.load" in the application properties.
-
Now next build it will load with the these data.
Virtualansoftware@2020