-
Notifications
You must be signed in to change notification settings - Fork 3
More detail
Java adaptor from Chronicle queue to kdb+
Repo contains:
- Producer app that writes messages to a Chronicle Queue.
- A sample kdb+ database.
- An Adapter app that reads messages from Chronicle Queue and writes them to kdb+
--spring.config.location=classpath:/,<PATH_TO_FILE>
- server.port: What port to run web component on e.g. 9090
- server.servlet.context-path: Path to access web component on e.g. /producer
- producer.messageFrequency: How freqently (in millis) to send a message to the queue e.g. 1000 for every second
- chronicle.quote.queue: Destination filesystem folder for queue to be persisted e.g. C:\ChronicleQueue\Producer\quote
server.port=9090
server.servlet.context-path=/producer
producer.messageFrequency=10
chronicle.quote.queue=C:\ChronicleQueue\Producer\quote
Run java application as follows:
- java -jar producer-0.1.jar --spring.config.location=classpath:/,C:/gitWorkarea/kdb-chronicle-queue/Producer/config/producer.properties
- Start message creation as follows: -- Http GET request to [http://localhost:9090/producer/quoteLoader?Command%3A%20start%2Fstop=start]
- Stop message creation as follows: -- Http GET request to [http://localhost:9090/producer/quoteLoader?Command%3A%20start%2Fstop=stop]
--spring.config.location=classpath:/,<PATH_TO_FILE>
- server.port: What port to run web component on e.g. 8080
- chronicle.source: Patch to Chronicle Queue file
- adapter.tailerName: Name Queue tailer to enable stop / re-start
- kdb.host: Server running kdb+ database
- kdb.port: kdb+ port
- kdb.login: kdb+ login credentials
- kdb.connection-enabled=true
- kdb.destination: Name of kdb+ table to write to
- kdb.destination.function: Name of function to use when writing to table
server.port=8080
management.endpoint.shutdown.enabled=true
management.endpoint.info.enabled=true
management.endpoints.web.exposure.include=*
management.endpoints.web.base-path=/adapter
management.endpoint.health.show-details=always
chronicle.source=C:\ChronicleQueue\Producer\quote
adapter.tailerName=quoteTailer
kdb.host=localhost
kdb.port=5000
kdb.login=username:password
kdb.connection-enabled=true
kdb.destination=quote
kdb.destination.function=.u.upd
Run java application as follows:
- java -jar adapter-0.1.jar --spring.config.location=classpath:/,C:/gitWorkarea/kdb-chronicle-queue/Adapter/config/adapter.properties
If app can connect to source queue and kdb+ destination it will start transfer immendiately.
Spring Boot Actuator allows interrogation, monitoring and interaction with configured Spring Boot applications.
- Adapter App Health: http://localhost:8080/adapter/health
- Adapter processing status: http://localhost:8080/adapter/status
- Shutdown Adapter: http://localhost:8080/adapter/shutdown