Skip to content

Commit

Permalink
Fix singlestore ops api
Browse files Browse the repository at this point in the history
Signed-off-by: Neaj Morshad <[email protected]>
  • Loading branch information
Neaj-Morshad-101 committed Oct 31, 2024
1 parent b4dde67 commit 65d104c
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 13 deletions.
8 changes: 4 additions & 4 deletions docs/guides/singlestore/concepts/opsrequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ metadata:
name: sdbops-reconfigure-config
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: sdb-sample
configuration:
Expand All @@ -149,7 +149,7 @@ metadata:
name: sdbops-reconfigure-config
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: sdb-standalone
configuration:
Expand All @@ -166,7 +166,7 @@ metadata:
name: sdbops-reconfigure-config
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: sdb-sample
configuration:
Expand All @@ -185,7 +185,7 @@ metadata:
name: sdbops-reconfigure-config
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: sdb-standalone
configuration:
Expand Down
13 changes: 6 additions & 7 deletions docs/guides/singlestore/reconfigure/reconfigure-steps/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ metadata:
name: sdbops-reconfigure-config
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: custom-sdb
configuration:
Expand All @@ -231,7 +231,7 @@ spec:
Here,
- `spec.databaseRef.name` specifies that we are reconfiguring `custom-sdb` database.
- `spec.type` specifies that we are performing `Configuration` on our database.
- `spec.type` specifies that we are performing `Reconfigure` on our database.
- `spec.configuration.aggregator.applyConfig` is a map where key supports 1 values, namely `sdb-apply.cnf` for aggregator nodes. You can also specifies `spec.configuration.leaf.applyConfig` which is a map where key supports 1 values, namely `sdb-apply.cnf` for leaf nodes.

Let's create the `SinglestoreOpsRequest` CR we have shown above,
Expand All @@ -250,8 +250,7 @@ Let's wait for `SinglestoreOpsRequest` to be `Successful`. Run the following co
```bash
$ kubectl get singlestoreopsrequest --all-namespaces
NAMESPACE NAME TYPE STATUS AGE
demo sdbops-reconfigure-config Configuration Successful 10m
demo sdbops-reconfigure-config Reconfigure Successful 10m
```

We can see from the above output that the `SinglestoreOpsRequest` has succeeded. If we describe the `SinglestoreOpsRequest` we will get an overview of the steps that were followed to reconfigure the database.
Expand All @@ -277,7 +276,7 @@ Spec:
sdb-apply.cnf: max_connections = 550
Database Ref:
Name: custom-sdb
Type: Configuration
Type: Reconfigure
Status:
Conditions:
Last Transition Time: 2024-10-04T10:18:22Z
Expand Down Expand Up @@ -396,7 +395,7 @@ metadata:
name: sdbops-reconfigure-remove
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: custom-sdb
configuration:
Expand Down Expand Up @@ -426,7 +425,7 @@ Let's wait for `SingleStoreOpsRequest` to be `Successful`. Run the following co
```bash
$ kubectl get singlestoreopsrequest -n demo
NAME TYPE STATUS AGE
sdbops-reconfigure-remove Configuration Successful 5m31s
sdbops-reconfigure-remove Reconfigure Successful 5m31s
```

Now let's connect to a singlestore instance and run a singlestore internal command to check the new configuration we have provided.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: sdbops-reconfigure-config
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: custom-sdb
configuration:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: sdbops-reconfigure-config
namespace: demo
spec:
type: Configuration
type: Reconfigure
databaseRef:
name: custom-sdb
configuration:
Expand Down

0 comments on commit 65d104c

Please sign in to comment.