Add detail about the protocol deprecation

Make sure it's clear that the deprecated fields serve no purpose, and
should be ignored.
This commit is contained in:
James Bardin 2021-09-29 16:45:29 -04:00
parent 9847eaa9cf
commit fe671206cc
2 changed files with 6 additions and 0 deletions

View File

@ -128,6 +128,9 @@ message Schema {
repeated Attribute attributes = 1; repeated Attribute attributes = 1;
NestingMode nesting = 3; NestingMode nesting = 3;
// MinItems and MaxItems were never used in the protocol, and have no
// effect on validation.
int64 min_items = 4 [deprecated = true]; int64 min_items = 4 [deprecated = true];
int64 max_items = 5 [deprecated = true]; int64 max_items = 5 [deprecated = true];
} }

View File

@ -1480,6 +1480,9 @@ type Schema_Object struct {
Attributes []*Schema_Attribute `protobuf:"bytes,1,rep,name=attributes,proto3" json:"attributes,omitempty"` Attributes []*Schema_Attribute `protobuf:"bytes,1,rep,name=attributes,proto3" json:"attributes,omitempty"`
Nesting Schema_Object_NestingMode `protobuf:"varint,3,opt,name=nesting,proto3,enum=tfplugin6.Schema_Object_NestingMode" json:"nesting,omitempty"` Nesting Schema_Object_NestingMode `protobuf:"varint,3,opt,name=nesting,proto3,enum=tfplugin6.Schema_Object_NestingMode" json:"nesting,omitempty"`
// MinItems and MaxItems were never used in the protocol, and have no
// effect on validation.
//
// Deprecated: Do not use. // Deprecated: Do not use.
MinItems int64 `protobuf:"varint,4,opt,name=min_items,json=minItems,proto3" json:"min_items,omitempty"` MinItems int64 `protobuf:"varint,4,opt,name=min_items,json=minItems,proto3" json:"min_items,omitempty"`
// Deprecated: Do not use. // Deprecated: Do not use.