From 01293049fde028ae214c206ea763cc622945cbca Mon Sep 17 00:00:00 2001 From: yaron2 Date: Wed, 16 Dec 2020 09:29:45 -0800 Subject: [PATCH] add component schema --- .../content/en/concepts/components-concept.md | 1 - .../operations/components/component-schema.md | 33 +++++++++++++++++++ .../operations/components/component-scopes.md | 2 +- 3 files changed, 34 insertions(+), 2 deletions(-) create mode 100644 daprdocs/content/en/operations/components/component-schema.md diff --git a/daprdocs/content/en/concepts/components-concept.md b/daprdocs/content/en/concepts/components-concept.md index db1a2c0ba..10eb40b86 100644 --- a/daprdocs/content/en/concepts/components-concept.md +++ b/daprdocs/content/en/concepts/components-concept.md @@ -20,7 +20,6 @@ Dapr uses a modular design where functionality is delivered as a component. Each * [Service discovery name resolution](https://github.com/dapr/components-contrib/tree/master/nameresolution) * [Secret stores](https://github.com/dapr/components-contrib/tree/master/secretstores) * [State](https://github.com/dapr/components-contrib/tree/master/state) -* [Tracing exporters](https://github.com/dapr/components-contrib/tree/master/exporters) ### Service invocation and service discovery components Service discovery components are used with the [service invocation]({{}}) building block to integrate with the hosting environment to provide service-to-service discovery. For example, the Kubernetes service discovery component integrates with the Kubernetes DNS service and self hosted uses mDNS. diff --git a/daprdocs/content/en/operations/components/component-schema.md b/daprdocs/content/en/operations/components/component-schema.md new file mode 100644 index 000000000..366bb26e5 --- /dev/null +++ b/daprdocs/content/en/operations/components/component-schema.md @@ -0,0 +1,33 @@ +--- +type: docs +title: "Component schema" +linkTitle: "Component schema" +weight: 100 +description: "The basic schema for a Dapr component" +--- + +```yaml +apiVersion: dapr.io/v1alpha1 +kind: Component +metadata: + name: # Required. Example: prod-statestore. + namespace: # Optional. Example: app-ns +spec: + type: # Required. Example: state.redis + version: v1 # Required + initTimeout: # Optional. Default: 30s + ignoreErrors: # Optional. Default: false + metadata: # Required. + - name: + value: +``` + +| Field | Details | +| ------------- | ------------- | +| metadata.name | The name of the component | +| metadata.namespace | The namespace for the component | +| metadata | A key/value pair of component specific configuration | +| spec.type | The type of the component | +| spec.version | The version of the component | +| spec.initTimeout | The timeout duration for the initialization of the component. durations examples: 10s, 10m, 1h | +| spec.ignoreErrors | Tells the Dapr sidecar to continue initialization of the component fails to load | \ No newline at end of file diff --git a/daprdocs/content/en/operations/components/component-scopes.md b/daprdocs/content/en/operations/components/component-scopes.md index e1112ae3d..e55eeb114 100644 --- a/daprdocs/content/en/operations/components/component-scopes.md +++ b/daprdocs/content/en/operations/components/component-scopes.md @@ -2,7 +2,7 @@ type: docs title: "How-To: Scope components to one or more applications" linkTitle: "How-To: Set component scopes" -weight: 100 +weight: 200 description: "Limit component access to particular Dapr instances" ---