Skip to content

Commit c3225d1

Browse files
Promote KV commands out of early access (#505)
Promote Key Value commands out of early access! GROW-2581 GitOrigin-RevId: b2bb0cfd5221fc6cfe6e64c00b43becb8475d801
1 parent 1bbdc9a commit c3225d1

17 files changed

Lines changed: 51 additions & 52 deletions

cmd/kv.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ func newKVCmd(children ...*cobra.Command) *cobra.Command {
77
Use: "keyvalues",
88
Aliases: []string{"kv", "keyvalue"},
99
Short: "Manage Render Key Value instances (alias: kv)",
10+
GroupID: GroupCore.ID,
1011
}
1112
cmd.AddCommand(children...)
1213
return cmd

cmd/kv_test.go

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ func seedKVInEnv(server *renderapi.Server, name, envID string) *client.KeyValueD
4242
return kv
4343
}
4444

45-
// executeKVCommand runs an `ea kv` command with the default active workspace
45+
// executeKVCommand runs a `kv` command with the default active workspace
4646
// seeded in the test config. Use this for ordinary KV command tests.
4747
func executeKVCommand(t *testing.T, server *renderapi.Server, extraArgs ...string) (CommandResult, error) {
4848
t.Helper()
@@ -52,7 +52,7 @@ func executeKVCommand(t *testing.T, server *renderapi.Server, extraArgs ...strin
5252
}, extraArgs...)
5353
}
5454

55-
// executeKVCommandWithoutActiveWorkspace runs an `ea kv` command without
55+
// executeKVCommandWithoutActiveWorkspace runs a `kv` command without
5656
// seeding the active workspace config. Prefer executeKVCommand unless the test
5757
// specifically covers missing-workspace behavior or workspace derivation.
5858
func executeKVCommandWithoutActiveWorkspace(t *testing.T, server *renderapi.Server, extraArgs ...string) (CommandResult, error) {
@@ -87,15 +87,13 @@ func executeKVCommandWithConfig(t *testing.T, server *renderapi.Server, cfg *con
8787
}
8888

8989
root := newRootCmd()
90-
ea := newEarlyAccessCmd()
91-
root.AddCommand(ea)
92-
setupKVCommands(ea, deps)
90+
setupKVCommands(root, deps)
9391
setupRootCmdPersistentRun(root, deps)
9492

9593
var stdout, stderr bytes.Buffer
9694
root.SetOut(&stdout)
9795
root.SetErr(&stderr)
98-
root.SetArgs(append([]string{"ea", "kv"}, extraArgs...))
96+
root.SetArgs(append([]string{"kv"}, extraArgs...))
9997

10098
execErr := root.Execute()
10199
return CommandResult{Stdout: stdout.String(), Stderr: stderr.String()}, execErr

cmd/kvcreate.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,19 @@ In non-interactive mode (--output text/json/yaml), flags use defaults if not sup
2626
Use --confirm to skip all prompts (including final confirmation) and create immediately.
2727
Output will be human-readable; use --output json/yaml/text for machine-readable output.`,
2828
Example: ` # Interactive wizard (guided prompts for each option)
29-
render ea kv create
29+
render kv create
3030
3131
# Specify all options; wizard still asks for confirmation before creating
32-
render ea kv create --name my-cache --plan starter --region oregon
32+
render kv create --name my-cache --plan starter --region oregon
3333
3434
# Skip all prompts and create immediately (no confirmation)
35-
render ea kv create --name my-cache --plan free --confirm
35+
render kv create --name my-cache --plan free --confirm
3636
3737
# Machine-readable output (non-interactive, no prompts)
38-
render ea kv create --name my-cache --plan starter --output json
38+
render kv create --name my-cache --plan starter --output json
3939
4040
# With IP allow-listing (repeat the flag for multiple entries)
41-
render ea kv create --name my-cache \
41+
render kv create --name my-cache \
4242
--ip-allow-list "cidr=203.0.113.5/32,description=office" \
4343
--ip-allow-list "cidr=10.0.0.0/8,description=internal"`,
4444
}

cmd/kvcreate_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import (
1313
"github.com/stretchr/testify/require"
1414
)
1515

16-
// executeKVCreate runs `render ea kv create <extraArgs>` against the fake server.
16+
// executeKVCreate runs `render kv create <extraArgs>` against the fake server.
1717
// It seeds and selects a default workspace before running the create command.
1818
// Pass --workspace explicitly in extraArgs for tests that exercise the workspace flag.
1919
func executeKVCreate(t *testing.T, server *renderapi.Server, extraArgs ...string) (CommandResult, error) {

cmd/kvdelete.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,19 +29,19 @@ Name lookup is scoped to your active workspace. If a name isn't found, switch
2929
workspaces with 'render workspace set <name|ID>' and try again, or pass the
3030
Key Value ID instead (which works across workspaces).`,
3131
Example: ` # Preview deletion (no changes made)
32-
render ea kv delete red-abc123def456ghi789jkl0
32+
render kv delete red-abc123def456ghi789jkl0
3333
3434
# Delete by ID
35-
render ea kv delete red-abc123def456ghi789jkl0 --confirm
35+
render kv delete red-abc123def456ghi789jkl0 --confirm
3636
3737
# Delete by name
38-
render ea kv delete my-cache --confirm
38+
render kv delete my-cache --confirm
3939
4040
# Disambiguate a name that exists in multiple environments
41-
render ea kv delete my-cache --environment production --confirm
41+
render kv delete my-cache --environment production --confirm
4242
4343
# JSON output
44-
render ea kv delete red-abc123def456ghi789jkl0 --confirm --output json`,
44+
render kv delete red-abc123def456ghi789jkl0 --confirm --output json`,
4545
}
4646

4747
cmd.Flags().String("environment", "",

cmd/kvdelete_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import (
1111
"github.com/stretchr/testify/require"
1212
)
1313

14-
// executeKVDelete runs `render ea kv delete <args>` against the fake server.
14+
// executeKVDelete runs `render kv delete <args>` against the fake server.
1515
// Seeds and selects an active workspace before running the command.
1616
func executeKVDelete(t *testing.T, server *renderapi.Server, extraArgs ...string) (CommandResult, error) {
1717
t.Helper()

cmd/kvget.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,22 +27,22 @@ Name lookup is scoped to your active workspace. If a name isn't found, switch
2727
workspaces with 'render workspace set <name|ID>' and try again, or pass the
2828
Key Value ID instead (which works across workspaces).`,
2929
Example: ` # Get by ID
30-
render ea kv get red-abc123def456ghi789jkl0
30+
render kv get red-abc123def456ghi789jkl0
3131
3232
# Get by name
33-
render ea kv get my-cache
33+
render kv get my-cache
3434
3535
# Include connection strings (contains credentials)
36-
render ea kv get my-cache --include-sensitive-connection-info
36+
render kv get my-cache --include-sensitive-connection-info
3737
3838
# Disambiguate by project
39-
render ea kv get my-cache --project my-project
39+
render kv get my-cache --project my-project
4040
4141
# Disambiguate a name that exists in multiple environments
42-
render ea kv get my-cache --environment production
42+
render kv get my-cache --environment production
4343
4444
# JSON output
45-
render ea kv get red-abc123def456ghi789jkl0 --output json`,
45+
render kv get red-abc123def456ghi789jkl0 --output json`,
4646
}
4747

4848
cmd.Flags().String("project", "",

cmd/kvget_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import (
1313
"github.com/stretchr/testify/require"
1414
)
1515

16-
// executeKVGet runs `render ea kv get <args>` against the fake server.
16+
// executeKVGet runs `render kv get <args>` against the fake server.
1717
// Seeds and selects an active workspace before running the command.
1818
func executeKVGet(t *testing.T, server *renderapi.Server, extraArgs ...string) (CommandResult, error) {
1919
t.Helper()

cmd/kvlist.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,19 @@ Use --project to narrow results to a single project, --environment to narrow
2626
to a single environment, or both — when both are supplied, the environment is
2727
resolved within that project.`,
2828
Example: ` # List all Key Value instances in the active workspace
29-
render ea kv list
29+
render kv list
3030
3131
# List all Key Value instances in a project
32-
render ea kv list --project my-project
32+
render kv list --project my-project
3333
3434
# Filter by environment name
35-
render ea kv list --environment production
35+
render kv list --environment production
3636
3737
# Disambiguate an environment name by project
38-
render ea kv list --project my-project --environment production
38+
render kv list --project my-project --environment production
3939
4040
# JSON output
41-
render ea kv list --output json`,
41+
render kv list --output json`,
4242
}
4343

4444
cmd.Flags().String("project", "",

cmd/kvlist_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99
"github.com/stretchr/testify/require"
1010
)
1111

12-
// executeKVList runs `render ea kv list <args>` against the fake server.
12+
// executeKVList runs `render kv list <args>` against the fake server.
1313
// Seeds and selects an active workspace before running the command.
1414
func executeKVList(t *testing.T, server *renderapi.Server, extraArgs ...string) (CommandResult, error) {
1515
t.Helper()

0 commit comments

Comments
 (0)