Open MOZGIII opened 4 years ago
Indeed, operator-way is more native for k8s and gives more flexibility.
Few more thoughts related to a topic:
Various flows may belong to different vector instances. It can be useful to have "Kind: Vector" with specification how to deploy Vector itself (instances count, daemonset/deployment/statefulset, antiaffinity, resources requests/limits, hpa) and specify it in sinks/flows. It brings more flexibility in deploying, ability to control vector components more granular, use "microservice-like" approach when broken components don't not affect other flows.
It's good to support clean yaml instead/together with described:
raw: |
drop_invalid = true
=>
config:
drop_invalid: true
Use case: ability to use native tools to generate manifests from templates (jsonnet/tanka, pulumi, etc...)
In case of operators it's possible to bring maturity model which will be useful for companies. Just an example of idea: https://sdk.operatorframework.io/docs/operator-capabilities/
Thanks @afonisky. @MOZGIII, where do you think this sits in our Kubernetes roadmap phases? 2?
This would be phase 3. We'll probably need a full-blown RFC for this.
Now you can use Kubernetes Vector Operator for configuring Vector in Kubernetes with CRDs
I think it would've make more sense to provide a backwards compatibility layer with Grafana Agent Operator instead, and reuse the respective CRD's that had been fairly widespread.
Also it would've been really nice if it was possible to use Vector as an agent for Grafana Faro,
I think it would've make more sense to provide a backwards compatibility layer with Grafana Agent Operator instead, and reuse the respective CRD's that had been fairly widespread.
There's probably some amount of re-use that can be done, but a quick look at those CRD's it may be difficult to translate some things. Definitely worth consideration.
Also it would've been really nice if it was possible to use Vector as an agent for Grafana Faro,
Feel free to open a feature request for this!
Definitely worth consideration.
@spencergilbert Yes, backwards compat, with better perf, would make Vector into a drop-in replacement for grafana agent stack.
Added #17591
We can add support for managing Vector configuration via Custom Resouce Definitions when running in the Kubernetes environment.
Motivation
DaemonSet
instance among multiple independent cluster users, utilizing resources more efficiently.Context
fluentd
.How it would look like
Let there be a Vector instance is deployed in a Kubernetes cluster, in a namespace
vector
.Then in another namespace, custom resources are added as part of an app (let's say
billing
app) deployment:This would configure Vector to take logs with pod labels
app: billing
to go through a custom log aggregation flow, so that they arrive directly to the S3 bucket.Effectively, Vector would build the following config after picking up the custom resources above:
Where names are roughly at the form of
<crd>.dynamic-<namespace>-<unit-name>
, liketransforms.dynamic-billing-billing-app-json_parser
orsinks.dynamic-billing-billing-s3
.Refs: