Skip to content

Configuration options need to be better explained #113

@polyzos

Description

@polyzos

From a user's perspective its not clear and its hard to understand how they can properly configure their functions/sources/connectors.

Consider the following example we have in the docs

apiVersion: compute.functionmesh.io/v1alpha1
kind: Function
metadata:
  name: java-function-sample
  namespace: default
spec:
  image: streamnative/example-function-image:latest # using function image here
  className: exclamation_function.ExclamationFunction
  forwardSourceMessageProperty: true
  maxPendingAsyncRequests: 1000
  replicas: 1
  maxReplicas: 5
  logTopic: persistent://public/default/logging-function-logs
  input:
    topics:
    - persistent://public/default/java-function-input-topic
    typeClassName: java.lang.String
  output:
    topic: persistent://public/default/java-function-output-topic
    typeClassName: java.lang.String
  pulsar:
    pulsarConfig: "test-pulsar"
  java:
    extraDependenciesDir: random-dir/
    jar: /pulsar/example-function.jar # the package location in image
    jarLocation: "" # leave empty since we will not download package from Pulsar Packages

and here is how we describe the configuration options:
https://functionmesh.io/docs/functions/function-crd/#function-configurations

Some examples:

  1. The configuration options start with an uppercase letter but the reality is they need to pass them with a lowercase start letter.
  2. We don't specify which are the default values and what their type is.. For example is it a string? an integer? a map? etc.
  3. We don't specify which configurations are optional and which are mandatory

Then consider the input/output section on the example above and see our docs here: https://functionmesh.io/docs/functions/function-crd/#input
For example the inputs section has typeClassName which is not described in the docs. Or for example in the output section we have the ProducerConf. The users get confused around -> what should i specify there? how to i specify it?

Here you can find some example i had created a few months back:
https://github.com/streamnative/streamnative-academy/blob/master/microservices-webinars/deployment/mesh.yaml#L196
as you can see here for example the user can add some ConfigMaps and secrets
In the docs: https://github.com/streamnative/streamnative-academy/blob/master/microservices-webinars/deployment/mesh.yaml#L196
we just mention the configuration names, we don't actually educate the user HOW we should specify them for deployment.

All these things cause a lot of confusion and its hard to start using function-mesh for realworld applications.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions