Skip to content

Commit 98e5b11

Browse files
authored
feat(mnq): enable v1beta1 per default and rename alpha (#3440)
1 parent 00bcf7c commit 98e5b11

File tree

36 files changed

+851
-197
lines changed

36 files changed

+851
-197
lines changed

cmd/scw/testdata/test-all-usage-mnq-credential-usage.golden

-24
This file was deleted.

cmd/scw/testdata/test-all-usage-mnq-namespace-list-usage.golden

-21
This file was deleted.

cmd/scw/testdata/test-all-usage-mnq-namespace-usage.golden

-24
This file was deleted.

cmd/scw/testdata/test-all-usage-mnq-namespace-create-usage.golden cmd/scw/testdata/test-all-usage-mnq-nats-create-account-usage.golden

+4-5
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
11
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
22
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3-
Create a Messaging and Queuing namespace, set to the desired protocol.
3+
Create a NATS account associated with a Project.
44

55
USAGE:
6-
scw mnq namespace create [arg=value ...]
6+
scw mnq nats create-account [arg=value ...]
77

88
ARGS:
9-
[name=<generated>] Namespace name
10-
protocol Namespace protocol. You must specify a valid protocol (and not `unknown`) to avoid an error. (unknown | nats | sqs_sns)
9+
[name=<generated>] NATS account name
1110
[project-id] Project ID to use. If none is passed the default project ID will be used
1211
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
1312

1413
FLAGS:
15-
-h, --help help for create
14+
-h, --help help for create-account
1615

1716
GLOBAL FLAGS:
1817
-c, --config string The path to the config file
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
Create a set of credentials for a NATS account, specified by its NATS account ID.
4+
5+
USAGE:
6+
scw mnq nats create-credentials [arg=value ...]
7+
8+
ARGS:
9+
nats-account-id NATS account containing the credentials
10+
[name=<generated>] Name of the credentials
11+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
12+
13+
FLAGS:
14+
-h, --help help for create-credentials
15+
16+
GLOBAL FLAGS:
17+
-c, --config string The path to the config file
18+
-D, --debug Enable debug mode
19+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
20+
-p, --profile string The config profile to use
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
Delete a NATS account, specified by its NATS account ID. Note that deleting a NATS account is irreversible, and any credentials, streams, consumer and stored messages belonging to this NATS account will also be deleted.
4+
5+
USAGE:
6+
scw mnq nats delete-account <nats-account-id ...> [arg=value ...]
7+
8+
ARGS:
9+
nats-account-id ID of the NATS account to delete
10+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
11+
12+
FLAGS:
13+
-h, --help help for delete-account
14+
15+
GLOBAL FLAGS:
16+
-c, --config string The path to the config file
17+
-D, --debug Enable debug mode
18+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
19+
-p, --profile string The config profile to use
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
Delete a set of credentials, specified by their credentials ID. Deleting credentials is irreversible and cannot be undone. The credentials can no longer be used to access the NATS account, and active connections using this credentials will be closed.
4+
5+
USAGE:
6+
scw mnq nats delete-credentials <nats-credentials-id ...> [arg=value ...]
7+
8+
ARGS:
9+
nats-credentials-id ID of the credentials to delete
10+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
11+
12+
FLAGS:
13+
-h, --help help for delete-credentials
14+
15+
GLOBAL FLAGS:
16+
-c, --config string The path to the config file
17+
-D, --debug Enable debug mode
18+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
19+
-p, --profile string The config profile to use

cmd/scw/testdata/test-all-usage-mnq-namespace-get-usage.golden cmd/scw/testdata/test-all-usage-mnq-nats-get-account-usage.golden

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
22
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3-
Retrieve information about an existing Messaging and Queuing namespace, identified by its namespace ID. Its full details, including name, endpoint and protocol, are returned in the response.
3+
Retrieve information about an existing NATS account identified by its NATS account ID. Its full details, including name and endpoint, are returned in the response.
44

55
USAGE:
6-
scw mnq namespace get <namespace-id ...> [arg=value ...]
6+
scw mnq nats get-account <nats-account-id ...> [arg=value ...]
77

88
ARGS:
9-
namespace-id ID of the Namespace to get
9+
nats-account-id ID of the NATS account to get
1010
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
1111

1212
FLAGS:
13-
-h, --help help for get
13+
-h, --help help for get-account
1414

1515
GLOBAL FLAGS:
1616
-c, --config string The path to the config file
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
Retrieve an existing set of credentials, identified by the `nats_credentials_id`. The credentials themselves are NOT returned, only their metadata (NATS account ID, credentials name, etc), are returned in the response.
4+
5+
USAGE:
6+
scw mnq nats get-credentials <nats-credentials-id ...> [arg=value ...]
7+
8+
ARGS:
9+
nats-credentials-id ID of the credentials to get
10+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
11+
12+
FLAGS:
13+
-h, --help help for get-credentials
14+
15+
GLOBAL FLAGS:
16+
-c, --config string The path to the config file
17+
-D, --debug Enable debug mode
18+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
19+
-p, --profile string The config profile to use
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
List all NATS accounts in the specified region, for a Scaleway Organization or Project. By default, the NATS accounts returned in the list are ordered by creation date in ascending order, though this can be modified via the `order_by` field.
4+
5+
USAGE:
6+
scw mnq nats list-accounts [arg=value ...]
7+
8+
ARGS:
9+
[project-id] Include only NATS accounts in this Project
10+
[order-by] Order in which to return results (created_at_asc | created_at_desc | updated_at_asc | updated_at_desc | name_asc | name_desc)
11+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | all)
12+
13+
FLAGS:
14+
-h, --help help for list-accounts
15+
16+
GLOBAL FLAGS:
17+
-c, --config string The path to the config file
18+
-D, --debug Enable debug mode
19+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
20+
-p, --profile string The config profile to use
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
List existing credentials in the specified NATS account. The response contains only the metadata for the credentials, not the credentials themselves, which are only returned after a **Create Credentials** call.
4+
5+
USAGE:
6+
scw mnq nats list-credentials [arg=value ...]
7+
8+
ARGS:
9+
nats-account-id Include only credentials for this NATS account
10+
[order-by] Order in which to return results (created_at_asc | created_at_desc | updated_at_asc | updated_at_desc | name_asc | name_desc)
11+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | all)
12+
13+
FLAGS:
14+
-h, --help help for list-credentials
15+
16+
GLOBAL FLAGS:
17+
-c, --config string The path to the config file
18+
-D, --debug Enable debug mode
19+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
20+
-p, --profile string The config profile to use

cmd/scw/testdata/test-all-usage-mnq-namespace-update-usage.golden cmd/scw/testdata/test-all-usage-mnq-nats-update-account-usage.golden

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
22
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3-
Update the name of a Messaging and Queuing namespace, specified by its namespace ID.
3+
Update the name of a NATS account, specified by its NATS account ID.
44

55
USAGE:
6-
scw mnq namespace update <namespace-id ...> [arg=value ...]
6+
scw mnq nats update-account <nats-account-id ...> [arg=value ...]
77

88
ARGS:
9-
namespace-id ID of the Namespace to update
10-
[name] Namespace name
9+
nats-account-id ID of the NATS account to update
10+
[name] NATS account name
1111
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
1212

1313
FLAGS:
14-
-h, --help help for update
14+
-h, --help help for update-account
1515

1616
GLOBAL FLAGS:
1717
-c, --config string The path to the config file
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
MnQ NATS commands.
4+
5+
USAGE:
6+
scw mnq nats <command>
7+
8+
AVAILABLE COMMANDS:
9+
create-account Create a NATS account
10+
create-credentials Create NATS credentials
11+
delete-account Delete a NATS account
12+
delete-credentials Delete NATS credentials
13+
get-account Get a NATS account
14+
get-credentials Get NATS credentials
15+
list-accounts List NATS accounts
16+
list-credentials List NATS credentials
17+
update-account Update the name of a NATS account
18+
19+
FLAGS:
20+
-h, --help help for nats
21+
22+
GLOBAL FLAGS:
23+
-c, --config string The path to the config file
24+
-D, --debug Enable debug mode
25+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
26+
-p, --profile string The config profile to use
27+
28+
Use "scw mnq nats [command] --help" for more information about a command.

cmd/scw/testdata/test-all-usage-mnq-credential-delete-usage.golden cmd/scw/testdata/test-all-usage-mnq-sns-activate-usage.golden

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
22
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3-
Delete a set of credentials, specified by their credential ID. Deleting credentials is irreversible and cannot be undone. The credentials can no longer be used to access the namespace.
3+
Activate SNS for the specified Project ID. SNS must be activated before any usage. Activating SNS does not trigger any billing, and you can deactivate at any time.
44

55
USAGE:
6-
scw mnq credential delete <credential-id ...> [arg=value ...]
6+
scw mnq sns activate [arg=value ...]
77

88
ARGS:
9-
credential-id ID of the credentials to delete
9+
[project-id] Project ID to use. If none is passed the default project ID will be used
1010
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
1111

1212
FLAGS:
13-
-h, --help help for delete
13+
-h, --help help for activate
1414

1515
GLOBAL FLAGS:
1616
-c, --config string The path to the config file
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
Create a set of credentials for SNS, specified by a Project ID. Credentials give the bearer access to topics, and the level of permissions can be defined granularly.
4+
5+
USAGE:
6+
scw mnq sns create-credentials [arg=value ...]
7+
8+
ARGS:
9+
[project-id] Project ID to use. If none is passed the default project ID will be used
10+
[name=<generated>] Name of the credentials
11+
[permissions.can-publish] Defines whether the credentials bearer can publish messages to the service (publish to SNS topics)
12+
[permissions.can-receive] Defines whether the credentials bearer can receive messages from the service (configure subscriptions)
13+
[permissions.can-manage] Defines whether the credentials bearer can manage the associated SNS topics or subscriptions
14+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
15+
16+
FLAGS:
17+
-h, --help help for create-credentials
18+
19+
GLOBAL FLAGS:
20+
-c, --config string The path to the config file
21+
-D, --debug Enable debug mode
22+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
23+
-p, --profile string The config profile to use

cmd/scw/testdata/test-all-usage-mnq-credential-get-usage.golden cmd/scw/testdata/test-all-usage-mnq-sns-deactivate-usage.golden

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
22
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3-
Retrieve an existing set of credentials, identified by the `credential_id`. The credentials themselves, as well as their metadata (protocol, namespace ID etc), are returned in the response.
3+
Deactivate SNS for the specified Project ID.You must delete all topics and credentials before this call or you need to set the force_delete parameter.
44

55
USAGE:
6-
scw mnq credential get <credential-id ...> [arg=value ...]
6+
scw mnq sns deactivate [arg=value ...]
77

88
ARGS:
9-
credential-id ID of the credentials to get
9+
[project-id] Project ID to use. If none is passed the default project ID will be used
1010
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
1111

1212
FLAGS:
13-
-h, --help help for get
13+
-h, --help help for deactivate
1414

1515
GLOBAL FLAGS:
1616
-c, --config string The path to the config file
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
Delete a set of SNS credentials, specified by their credentials ID. Deleting credentials is irreversible and cannot be undone. The credentials can then no longer be used to access SNS.
4+
5+
USAGE:
6+
scw mnq sns delete-credentials <sns-credentials-id ...> [arg=value ...]
7+
8+
ARGS:
9+
sns-credentials-id ID of the credentials to delete
10+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
11+
12+
FLAGS:
13+
-h, --help help for delete-credentials
14+
15+
GLOBAL FLAGS:
16+
-c, --config string The path to the config file
17+
-D, --debug Enable debug mode
18+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
19+
-p, --profile string The config profile to use
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
2+
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3+
Retrieve an existing set of credentials, identified by the `credentials_id`. The credentials themselves, as well as their metadata (name, project ID etc), are returned in the response.
4+
5+
USAGE:
6+
scw mnq sns get-credentials <sns-credentials-id ...> [arg=value ...]
7+
8+
ARGS:
9+
sns-credentials-id ID of the SNS credentials to get
10+
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)
11+
12+
FLAGS:
13+
-h, --help help for get-credentials
14+
15+
GLOBAL FLAGS:
16+
-c, --config string The path to the config file
17+
-D, --debug Enable debug mode
18+
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
19+
-p, --profile string The config profile to use

0 commit comments

Comments
 (0)