Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ managed:
enabled: false
inputs:
# You can get the full commit sha from https://buf.build/redpandadata/core/docs
- module: buf.build/redpandadata/core:288047c1b16f4a4c95053d66e16815f7
- module: buf.build/redpandadata/core:ee867ae38d234429be446a794c27b345
paths:
- redpanda/core/admin/v2/shadow_link.proto
- redpanda/core/common/v1/acl.proto
Expand Down
4 changes: 4 additions & 0 deletions src/go/rpk/gen/protocomments/admin/v2/comments.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/go/rpk/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ require (
buf.build/gen/go/redpandadata/cloud/connectrpc/go v1.19.1-20260409133226-cd0bdc42a0f9.2
buf.build/gen/go/redpandadata/cloud/protocolbuffers/go v1.36.11-20260409133226-cd0bdc42a0f9.1
buf.build/gen/go/redpandadata/common/protocolbuffers/go v1.36.11-20260323171043-6e06f84ad823.1
buf.build/gen/go/redpandadata/core/protocolbuffers/go v1.36.11-20260623153049-288047c1b16f.1
buf.build/gen/go/redpandadata/core/protocolbuffers/go v1.36.11-20260706172830-ee867ae38d23.1
buf.build/gen/go/redpandadata/dataplane/connectrpc/go v1.19.1-20260409091301-5e03d1b04513.2
buf.build/gen/go/redpandadata/dataplane/protocolbuffers/go v1.36.11-20260409091301-5e03d1b04513.1
buf.build/gen/go/redpandadata/gatekeeper/connectrpc/go v1.19.1-20251022210437-a5dd600d04b6.2
Expand Down
4 changes: 2 additions & 2 deletions src/go/rpk/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ buf.build/gen/go/redpandadata/common/protocolbuffers/go v1.36.11-20260323171043-
buf.build/gen/go/redpandadata/common/protocolbuffers/go v1.36.11-20260323171043-6e06f84ad823.1/go.mod h1:3w7EzexwlL6PIFGbbeKZ0yHfUlAmI0aBVzF/QoFb8Cg=
buf.build/gen/go/redpandadata/core/connectrpc/go v1.19.2-20260608080241-5b0ab84ea082.1 h1:REoEEpW3VLzOMm1fWkVWCbu7pnHO+OyZdsKL7MT6Chc=
buf.build/gen/go/redpandadata/core/connectrpc/go v1.19.2-20260608080241-5b0ab84ea082.1/go.mod h1:+xnk83uu51cCNf3Hogv22YnoMkiTXeRMYjsuDMVElKk=
buf.build/gen/go/redpandadata/core/protocolbuffers/go v1.36.11-20260623153049-288047c1b16f.1 h1:TmJYP+PsyrF7jsKfL/PXJmllkbJaoibeeoEQugy0xmg=
buf.build/gen/go/redpandadata/core/protocolbuffers/go v1.36.11-20260623153049-288047c1b16f.1/go.mod h1:5sjUVquVwNxt3Q/EhE/UW0BBJ5sgPiaVTw8//wxRULI=
buf.build/gen/go/redpandadata/core/protocolbuffers/go v1.36.11-20260706172830-ee867ae38d23.1 h1:C9SUjDTkhuGUhCrLyTn8YsUmDru/SoSW2OFMGbGAVag=
buf.build/gen/go/redpandadata/core/protocolbuffers/go v1.36.11-20260706172830-ee867ae38d23.1/go.mod h1:5sjUVquVwNxt3Q/EhE/UW0BBJ5sgPiaVTw8//wxRULI=
buf.build/gen/go/redpandadata/dataplane/connectrpc/go v1.19.1-20260409091301-5e03d1b04513.2 h1:8t4xNuFJqh2mW4RPa6sVjL+Bm6ONZq7Gj3PsCPMNUFM=
buf.build/gen/go/redpandadata/dataplane/connectrpc/go v1.19.1-20260409091301-5e03d1b04513.2/go.mod h1:EN4XJHrOIY8SoHVk9NuZf9I4DtlmhSq6ixlNhbCR+L4=
buf.build/gen/go/redpandadata/dataplane/protocolbuffers/go v1.36.11-20260409091301-5e03d1b04513.1 h1:vbHgxorgH6giQxyTPtd+rHkke0E8w5VU1bQC5WjV6qY=
Expand Down
3 changes: 3 additions & 0 deletions src/go/rpk/pkg/cli/shadow/describe.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ type describeSchemaRegistrySyncOptions struct {
// metadata (not the password).
type describeShadowSchemaRegistryAPI struct {
SourceURL string `json:"source_url" yaml:"source_url"`
Paused bool `json:"paused" yaml:"paused"`
AuthOptions *describeAuthenticationConfig `json:"auth_options,omitempty" yaml:"auth_options,omitempty"`
TLSSettings *TLSSettings `json:"tls_settings,omitempty" yaml:"tls_settings,omitempty"`
TailInterval string `json:"tail_interval" yaml:"tail_interval"`
Expand Down Expand Up @@ -593,6 +594,7 @@ func printSchemaRegistrySync(opts *adminv2.SchemaRegistrySyncOptions) {
if api == nil {
return
}
tw.Print("PAUSED", api.GetPaused())
tw.Print("SOURCE URL", api.GetSourceUrl())
tw.Print("TAIL INTERVAL", api.GetEffectiveTailInterval().AsDuration().String())
tw.Print("FULL SYNC INTERVAL", api.GetEffectiveFullSyncInterval().AsDuration().String())
Expand Down Expand Up @@ -925,6 +927,7 @@ func buildDescribeShadowSchemaRegistryAPI(api *adminv2.SchemaRegistrySyncOptions
}
d := &describeShadowSchemaRegistryAPI{
SourceURL: api.GetSourceUrl(),
Paused: api.GetPaused(),
TLSSettings: adminTLSToCfg(api.GetTlsSettings()),
TailInterval: api.GetEffectiveTailInterval().AsDuration().String(),
FullSyncInterval: api.GetEffectiveFullSyncInterval().AsDuration().String(),
Expand Down
2 changes: 2 additions & 0 deletions src/go/rpk/pkg/cli/shadow/mapper.go
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,7 @@ func mapShadowSchemaRegistryAPI(api *ShadowSchemaRegistryAPI) *adminv2.SchemaReg

pbAPI := &adminv2.SchemaRegistrySyncOptions_ShadowSchemaRegistryApi{
SourceUrl: api.SourceURL,
Paused: api.Paused,
MaxSourceRequestsPerSecond: api.MaxSourceRequestsPerSecond,
AuthOptions: mapSchemaRegistryAuthOptions(api.AuthOptions),
SourceFilter: mapSchemaRegistrySourceFilter(api.SourceFilter),
Expand Down Expand Up @@ -838,6 +839,7 @@ func adminShadowSchemaRegistryAPIToCfg(api *adminv2.SchemaRegistrySyncOptions_Sh

cfg := &ShadowSchemaRegistryAPI{
SourceURL: api.GetSourceUrl(),
Paused: api.GetPaused(),
MaxSourceRequestsPerSecond: api.GetMaxSourceRequestsPerSecond(),
AuthOptions: adminSchemaRegistryAuthToCfg(api.GetAuthOptions()),
SourceFilter: adminSchemaRegistrySourceFilterToCfg(api.GetSourceFilter()),
Expand Down
4 changes: 4 additions & 0 deletions src/go/rpk/pkg/cli/shadow/mapper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -593,6 +593,7 @@ func TestMapSchemaRegistrySyncOptions(t *testing.T) {
},
},
UnsupportedSchemaFeaturePolicy: UnsupportedSchemaFeaturePolicyRemove,
Paused: true,
},
},
want: &adminv2.SchemaRegistrySyncOptions{
Expand Down Expand Up @@ -632,6 +633,7 @@ func TestMapSchemaRegistrySyncOptions(t *testing.T) {
},
},
UnsupportedSchemaFeaturePolicy: adminv2.UnsupportedSchemaFeaturePolicy_UNSUPPORTED_SCHEMA_FEATURE_POLICY_REMOVE,
Paused: true,
},
},
},
Expand Down Expand Up @@ -1345,6 +1347,7 @@ func TestAdminSchemaRegistrySyncToCfg(t *testing.T) {
},
},
UnsupportedSchemaFeaturePolicy: adminv2.UnsupportedSchemaFeaturePolicy_UNSUPPORTED_SCHEMA_FEATURE_POLICY_REMOVE,
Paused: true,
},
},
},
Expand Down Expand Up @@ -1378,6 +1381,7 @@ func TestAdminSchemaRegistrySyncToCfg(t *testing.T) {
},
},
UnsupportedSchemaFeaturePolicy: UnsupportedSchemaFeaturePolicyRemove,
Paused: true,
},
},
},
Expand Down
5 changes: 5 additions & 0 deletions src/go/rpk/pkg/cli/shadow/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,11 @@ type ShadowSchemaRegistryTopic struct{}
type ShadowSchemaRegistryAPI struct {
// The source Schema Registry URL to use
SourceURL string `json:"source_url,omitempty" yaml:"source_url,omitempty"`
// Allows the user to pause the Schema Registry sync task. If paused, the
// task enters the 'paused' state and stops replicating schemas from the
// source, and the per-context client write protection on the contexts this
// link owns is lifted.
Paused bool `json:"paused,omitempty" yaml:"paused,omitempty"`
// Authentication settings for requests to the source Schema Registry.
// If unset, requests are sent without authentication
AuthOptions *SchemaRegistryAuthOptions `json:"auth_options,omitempty" yaml:"auth_options,omitempty"`
Expand Down
4 changes: 4 additions & 0 deletions src/go/rpk/pkg/cli/shadow/types_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,7 @@ client_options:
schema_registry_sync_options:
shadow_schema_registry_api:
source_url: "https://source-sr.example.com:8081"
paused: true
auth_options:
basic:
username: "sr-user"
Expand Down Expand Up @@ -250,6 +251,7 @@ schema_registry_sync_options:
SchemaRegistrySyncOptions: &SchemaRegistrySyncOptions{
ShadowSchemaRegistryAPI: &ShadowSchemaRegistryAPI{
SourceURL: "https://source-sr.example.com:8081",
Paused: true,
AuthOptions: &SchemaRegistryAuthOptions{
Basic: &HTTPBasicAuthOptions{
Username: "sr-user",
Expand Down Expand Up @@ -488,6 +490,7 @@ func TestShadowLinkConfigUnmarshalJSON(t *testing.T) {
"schema_registry_sync_options": {
"shadow_schema_registry_api": {
"source_url": "https://source-sr.example.com:8081",
"paused": true,
"auth_options": {
"basic": {
"username": "sr-user",
Expand Down Expand Up @@ -516,6 +519,7 @@ func TestShadowLinkConfigUnmarshalJSON(t *testing.T) {
SchemaRegistrySyncOptions: &SchemaRegistrySyncOptions{
ShadowSchemaRegistryAPI: &ShadowSchemaRegistryAPI{
SourceURL: "https://source-sr.example.com:8081",
Paused: true,
AuthOptions: &SchemaRegistryAuthOptions{
Basic: &HTTPBasicAuthOptions{
Username: "sr-user",
Expand Down
Loading