An open API service indexing awesome lists of open source software.

https://github.com/bnorm/datasite-poc-garden


https://github.com/bnorm/datasite-poc-garden

Last synced: about 1 year ago
JSON representation

Awesome Lists containing this project

README

          

# Architecture
![garden-architecture](docs/garden-architecture.png)

# Port configuration
|application|port|
|---|---|
|gardening-service|9000|
|iot-gateway|9010|
|iot-simulator|9011|
|processor-service|9020|
|reporting-service|9030|
|reporting-ui|9031|

### MongoDB configuration

After starting the Docker compose file, run the following commands to
configuration the Debezium connection to MongoDB.

Configure the replication set in MongoDB:
```shell
docker-compose exec mongo /bin/bash -c 'mongo localhost:27017/datasite-poc <<-EOF
rs.initiate({
_id: "rs0",
"version" : 1,
members: [
{ _id: 0, host: "localhost:27017" }
]
});
EOF'
```

Connection Debezium to MongoDB.
```shell
curl -i -X POST \
-H "Accept:application/json" \
-H "Content-Type:application/json" \
http://localhost:8083/connectors/ \
-d '{
"name": "mongodb_connector",
"config": {
"connector.class" : "io.debezium.connector.mongodb.MongoDbConnector",
"tasks.max" : "1",
"mongodb.hosts" : "rs0/mongo:27017",
"mongodb.name" : "mongo",
"mongodb.members.auto.discover" : false,
"collection.whitelist" : "datasite-poc.*",
"provide.transaction.metadata" : true,
"database.history.kafka.bootstrap.servers" : "kafka:9092"
}
}'
```

### IntelliJ HTTP Requests

Create a `http-client-private.env.json` file in the project root directory with
the following template:
```json
{
"": {
"user_id": ""
}
}
```

Replace `` and the `` values with appropriate
values. For example, you could replace with `local` and `john` respectively.