https://github.com/hypertrace/query-service
Query service which exposes APIs to query data from the underlying stores.
https://github.com/hypertrace/query-service
Last synced: 7 months ago
JSON representation
Query service which exposes APIs to query data from the underlying stores.
- Host: GitHub
- URL: https://github.com/hypertrace/query-service
- Owner: hypertrace
- License: other
- Created: 2020-07-01T23:06:49.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2024-11-15T11:11:48.000Z (about 1 year ago)
- Last Synced: 2024-11-15T12:22:08.496Z (about 1 year ago)
- Language: Java
- Size: 967 KB
- Stars: 4
- Watchers: 6
- Forks: 10
- Open Issues: 19
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# Query Service
The Query Service interfaces with Apache Pinot Data Store
## Description
|  |
|:--:|
| *Hypertrace Query Architecture* |
- Query Service serves time series data for attributes/metrics from spans and events. The query interface this exposes is more like a table where you can select any columns, aggregations on them with filters. It's easy to do slicing and dicing of data (only from one table since no JOINs are supported) with this interface.
- Currently Pinot is the only DB layer for this service and queries are directly translated to PQL. However, in future we could add support for more data stores like Presto, Druid etc here.
- This layer doesn't understand the entities and their relationships because the query interface is generic table like interface.
## Building locally
The Query service uses gradlew to compile/install/distribute. Gradle wrapper is already part of the source code. To build Query Service, run:
```
./gradlew dockerBuildImages
```
## Testing
### Running unit tests
Run `./gradlew test` to execute unit tests.
### Testing image
#### With docker-compose
To test your image using the docker-compose setup follow the steps:
- Commit you changes to a branch say `query-service-test`.
- Go to [hypertrace-service](https://github.com/hypertrace/gateway-service) and checkout the above branch in the submodule.
```
cd query-service && git checkout query-service-test && cd ..
```
- Change tag for `hypertrace-service` from `:main` to `:test` in [docker-compose file](https://github.com/hypertrace/hypertrace/blob/main/docker/docker-compose.yml) like this.
```yaml
hypertrace-service:
image: hypertrace/hypertrace-service:test
container_name: hypertrace-service
...
```
- and then run `docker-compose up` to test the setup.
and then run `docker-compose up` to test the setup.
#### With Helm setup
Add image repository and tag in values.yaml file [here](https://github.com/hypertrace/hypertrace/blob/main/kubernetes/platform-services/values.yaml) like below and then run `./hypertrace.sh install` again and you can test your image!
```yaml
query-service:
image:
repository: "hypertrace/query-service"
tagOverride: "test"
```
## Docker Image Source:
- [DockerHub > Query service](https://hub.docker.com/r/hypertrace/Query-service)