New database support: Timeplus Proton #139
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Proton is an open-source, unified streaming and historical data processing engine in one single binary, powered by ClickHouse.
This PR adds Proton as a supported database in client and server codebase for Pulse.
UI
(a new card is added at the end of database shortcuts. Feel free to adjust this)
You can use a local proton server (via docker or single binary). Make sure 8123 port is opened and use
default
as the database. You can use the docker compose stack at https://github.com/timeplus-io/proton/tree/develop/examples/jdbcCreate charts or dashboard
the sample SQL can be
select _tp_time, cid, speed_kmh from car_live_data limit 10
Please note, by default Proton's query behavior is streaming SQL, looking for new data in the future and never ends. This can be considered as hang for JDBC client. So we recommend to use port 8123, which forces all SQL in table mode.
Note to the code change
Development and Test
Here is the dev stack I used:
I tried to run
gradle assembleServerAndClient
. It didn't always work. Specially lacking of HTML files.So I run
yarn install
andyarn run build
in theclient
folder first to build the frontend first. Then rungradle assembleServerAndClient
in top folder again to generate the server/lib/pulse.jar, the usejava -jar pulse.jar
to run it.