此内容没有您所选择的语言版本。
Chapter 7. Service Registry Operator configuration reference
This chapter provides detailed information on the custom resource used to configure the Service Registry Operator to deploy Service Registry:
7.1. Service Registry Custom Resource
The Service Registry Operator defines an ApicurioRegistry
custom resource (CR) that represents a single deployment of Service Registry on OpenShift.
These resource objects are created and maintained by users to instruct the Service Registry Operator how to deploy and configure Service Registry.
Example ApicurioRegistry CR
The following command displays the ApicurioRegistry
resource:
oc get apicurioregistry oc edit apicurioregistry example-apicurioregistry
apiVersion: registry.apicur.io/v1 kind: ApicurioRegistry metadata: name: example-apicurioregistry namespace: demo-kafka # ... spec: configuration: persistence: kafkasql kafkasql: bootstrapServers: 'my-cluster-kafka-bootstrap.demo-kafka.svc:9092' deployment: host: >- example-apicurioregistry.demo-kafka.example.com status: conditions: - lastTransitionTime: "2021-05-03T10:47:11Z" message: "" reason: Reconciled status: "True" type: Ready info: host: example-apicurioregistry.demo-kafka.example.com managedResources: - kind: Deployment name: example-apicurioregistry-deployment namespace: demo-kafka - kind: Service name: example-apicurioregistry-service namespace: demo-kafka - kind: Ingress name: example-apicurioregistry-ingress namespace: demo-kafka
By default, the Service Registry Operator only watches its own project namespace. Therefore you must create the ApicurioRegistry
CR in the same namespace, if you are deploying the operator manually. You can modify this behavior by updating WATCH_NAMESPACE
environment variable in the Operator Deployment
resource.
Additional resources
7.2. Service Registry CR spec
The spec
is the part of the ApicurioRegistry
CR that is used to provide the desired state or configuration for the Operator to achieve.
ApicurioRegistry CR spec contents
The following example block contains the full tree of possible spec
configuration options. Some fields may not be required or should not be defined at the same time.
spec: configuration: persistence: <string> sql: dataSource: url: <string> userName: <string> password: <string> kafkasql: bootstrapServers: <string> security: tls: truststoreSecretName: <string> keystoreSecretName: <string> scram: mechanism: <string> truststoreSecretName: <string> user: <string> passwordSecretName: <string> ui: readOnly: <string> logLevel: <string> security: keycloak: url: <string> realm: <string> apiClientId: <string> uiClientId: <string> deployment: replicas: <int32> host: <string> affinity: <k8s.io/api/core/v1 Affinity struct> tolerations: <k8s.io/api/core/v1 []Toleration slice>
The following table describes each configuration option:
Configuration option | type | Default value | Description |
---|---|---|---|
| - | - | Section for configuration of Service Registry application |
| string | required |
Storage backend. One of |
| - | - | SQL storage backend configuration |
| - | - | Database connection configuration for SQL storage backend |
| string | required | Database connection URL string |
| string | required | Database connection user |
| string | empty | Database connection password |
| - | - | Kafka storage backend configuration |
| string | required | Kafka bootstrap server URL, for Streams storage backend |
| - | - | Section to configure TLS authentication for Kafka storage backend |
| string | required | Name of a secret containing TLS truststore for Kafka |
| string | required | Name of a secret containing user TLS keystore |
| string | required | Name of a secret containing TLS truststore for Kafka |
| string | required | SCRAM user name |
| string | required | Name of a secret containing SCRAM user password |
| string |
| SASL mechanism |
| - | - | Service Registry web console settings |
| string |
| Set Service Registry web console to read-only mode |
| string |
|
Service Registry log level. One of |
| - | - | Service Registry web console and REST API security settings |
| - | - | Web console and REST API security configuration using Keycloak |
| string | required |
Keycloak URL, must end with |
| string | required | Keycloak realm |
| string |
| Keycloak client for REST API |
| string |
| Keycloak client for web console |
| - | - | Section for Service Registry deployment settings |
| positive integer |
| Number of Service Registry pods to deploy |
| string | auto-generated | Host/URL where the Service Registry console and API are available. If possible, Service Registry Operator attempts to determine the correct value based on the settings of your cluster router. The value is auto-generated only once, so user can override it afterwards. |
| k8s.io/api/core/v1 Affinity struct | empty | Service Registry deployment affinity configuration |
| k8s.io/api/core/v1 []Toleration slice | empty | Service Registry deployment tolerations configuration |
If an option is marked as required, it might be conditional on other configuration options being enabled. Empty values might be accepted, but the Operator does not perform the specified action.
7.3. Service Registry CR status
The status
is the section of the CR managed by the Service Registry Operator that contains a description of the current deployment and application state.
ApicurioRegistry CR status contents
The status
section contains the following fields:
status: info: host: <string> conditions: <list of:> - type: <string> status: <string, one of: True, False, Unknown> reason: <string> message: <string> lastTransitionTime: <string, RFC-3339 timestamp> managedResources: <list of:> - kind: <string> namespace: <string> name: <string>
Status field | Type | Description |
---|---|---|
| - | Section with information about the deployed Service Registry. |
| string | URL where the Service Registry UI and REST API are accessible. |
| - | List of conditions that report the status of the Service Registry, or the Operator with respect to that deployment. |
| string | Type of the condition. |
| string |
Status of the condition, one of |
| string | A programmatic identifier indicating the reason for the condition’s last transition. |
| string | A human readable message indicating details about the transition. |
| string | The last time the condition transitioned from one status to another. |
| - | List of OpenShift resources managed by Service Registry Operator |
| string | Resource kind. |
| string | Resource namespace. |
| string | Resource name. |
7.4. Service Registry managed resources
The resources managed by the Service Registry Operator when deploying Service Registry are as follows:
-
Deployment
-
Service
-
Ingress
(andRoute
) -
PodDisruptionBudget
7.5. Service Registry Operator labels
Resources managed by the Service Registry Operator are usually labeled as follows:
Label | Description |
---|---|
|
Name of the Service Registry deployment that the resource belongs to, based on the name of the specified |
|
Type of the deployment: |
|
Name of the deployment: same value as |
| Version of the Service Registry or the Service Registry Operator |
| A set of recommended Kubernetes labels for application deployments. |
| Metering labels for Red Hat products. |
Additional resources