@Component public class MongoDBInit extends Object
Initialized the database with data found in the classpath. It searches for files in the folder mongodb ending with .ndjson. The filename is used as name of the collection. The contents of this file has to be valid ND-JSON which means that it contains one JSON Object per line.
| Constructor and Description |
|---|
MongoDBInit() |
| Modifier and Type | Method and Description |
|---|---|
void |
initDatabase()
init database with demo data
|
@PostConstruct public void initDatabase()
Copyright © 2015–2016 Taimos GmbH. All rights reserved.