App Query Service

The Query Service provides materialised view objects for entities stored in the Obcerv Platform, and exposes additional query capabilities that are not directly supported by the Obcerv Platform.

The Query Service exposes a gRPC API which is not publicly exposed and only internally accessible by Obcerv Apps.

Some apps require access to the Query Service to provide functionality.

Lifecycle

Install with defaults

helm install obcerv-app-query-service itrs/obcerv-app-query-service \
     --version 1.0.0.XX -n itrs --wait

Install with overrides

  1. Create a chart config file, named app.yaml containing content similar to:
service:   
  threadPoolSize: 10 
  resources:    
    requests:
      memory: "500Mi"
      cpu: "500m"
    limits:
      memory: "2G"
      cpu: "2"
db:
  resources:
    requests:
      memory: "2G"
      cpu: "2"
    limits:
      memory: "3G"
      cpu: "4"          
  1. To install the chart, run:
helm install -f app.yaml obcerv-app-query-service itrs/obcerv-app-query-service \
            --version 1.0.0.XX -n itrs --wait

Storage

The Query Service only stores the latest versions of Entities and keeps some history for signals and a few attributes. Thus, the storage requirements are fairly low, and it has by default 5GB of storage allocated to data, and 2GB storage allocated to the Write-Ahead log (WAL). The Persistent Volume Claims (PVC) used by the Query Service are;

PVC Mount
app-query-service-data /data
app-query-service-wal /wal

The allocated storage can be changed by modifying the PVCs in Kubernetes, or the defaults can be overridden at install time by setting db.dataDiskSize and db.walDiskSize in the chart config file.

db:
  dataDiskSize: 10Gi
  walDiskSize: 5Gi

Uninstall

To uninstall, run:

helm uninstall obcerv-app-query-service -n itrs

Upgrade

To upgrade the Query Service, first uninstall and then install it again.

None of the data stored in the Query Service is authorative, and the state is re-built from the Platform on re-install.

Resource allocation

The App deploys a query service and a database with the following default resource allocations:

service:
  threadPoolSize: 10
  resources:   
    requests:
      memory: "500Mi"
      cpu: "500m"
    limits:
      memory: "2G"
      cpu: "2"
db:
  resources:
    requests:
      memory: "2G"
      cpu: "2"
    limits:
      memory: "3G"
      cpu: "4"

The following additional parameters are available:

["Obcerv"] ["User Guide"]

Was this topic helpful?