-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature: Build schema on upstream version 3.9.0-rc5 (#213)
This bumps schema to 3.9.0-rc5. The intention is that we can release this as some pre-release, most likely an alpha, pending the upstream final version. This PR adds an `@xfail` to the compatibility test of `UpdateRaftVoterResponse`. This model is hitting #215 which already exists prior to schema vertsion 3.9.0. That bug should be addressed separately.
- Loading branch information
1 parent
a4a78b1
commit c73175a
Showing
159 changed files
with
6,747 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
from .request import AddRaftVoterRequest | ||
from .response import AddRaftVoterResponse | ||
|
||
__all__ = ( | ||
"AddRaftVoterRequest", | ||
"AddRaftVoterResponse", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
""" | ||
Generated from ``clients/src/main/resources/common/message/AddRaftVoterRequest.json``. | ||
""" | ||
|
||
import uuid | ||
|
||
from dataclasses import dataclass | ||
from dataclasses import field | ||
from typing import ClassVar | ||
|
||
from kio.schema.request_header.v2.header import RequestHeader | ||
from kio.static.constants import EntityType | ||
from kio.static.primitive import i16 | ||
from kio.static.primitive import i32 | ||
from kio.static.primitive import i32Timedelta | ||
from kio.static.primitive import u16 | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class Listener: | ||
__type__: ClassVar = EntityType.nested | ||
__version__: ClassVar[i16] = i16(0) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(80) | ||
__header_schema__: ClassVar[type[RequestHeader]] = RequestHeader | ||
name: str = field(metadata={"kafka_type": "string"}) | ||
"""The name of the endpoint""" | ||
host: str = field(metadata={"kafka_type": "string"}) | ||
"""The hostname""" | ||
port: u16 = field(metadata={"kafka_type": "uint16"}) | ||
"""The port""" | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class AddRaftVoterRequest: | ||
__type__: ClassVar = EntityType.request | ||
__version__: ClassVar[i16] = i16(0) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(80) | ||
__header_schema__: ClassVar[type[RequestHeader]] = RequestHeader | ||
cluster_id: str | None = field(metadata={"kafka_type": "string"}) | ||
timeout: i32Timedelta = field(metadata={"kafka_type": "timedelta_i32"}) | ||
voter_id: i32 = field(metadata={"kafka_type": "int32"}) | ||
"""The replica id of the voter getting added to the topic partition""" | ||
voter_directory_id: uuid.UUID | None = field(metadata={"kafka_type": "uuid"}) | ||
"""The directory id of the voter getting added to the topic partition""" | ||
listeners: tuple[Listener, ...] | ||
"""The endpoints that can be used to communicate with the voter""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
""" | ||
Generated from ``clients/src/main/resources/common/message/AddRaftVoterResponse.json``. | ||
""" | ||
|
||
from dataclasses import dataclass | ||
from dataclasses import field | ||
from typing import ClassVar | ||
|
||
from kio.schema.errors import ErrorCode | ||
from kio.schema.response_header.v1.header import ResponseHeader | ||
from kio.static.constants import EntityType | ||
from kio.static.primitive import i16 | ||
from kio.static.primitive import i32Timedelta | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class AddRaftVoterResponse: | ||
__type__: ClassVar = EntityType.response | ||
__version__: ClassVar[i16] = i16(0) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(80) | ||
__header_schema__: ClassVar[type[ResponseHeader]] = ResponseHeader | ||
throttle_time: i32Timedelta = field(metadata={"kafka_type": "timedelta_i32"}) | ||
"""The duration in milliseconds for which the request was throttled due to a quota violation, or zero if the request did not violate any quota.""" | ||
error_code: ErrorCode = field(metadata={"kafka_type": "error_code"}) | ||
"""The error code, or 0 if there was no error""" | ||
error_message: str | None = field(metadata={"kafka_type": "string"}) | ||
"""The error message, or null if there was no error.""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
from .request import ApiVersionsRequest | ||
from .response import ApiVersionsResponse | ||
|
||
__all__ = ( | ||
"ApiVersionsRequest", | ||
"ApiVersionsResponse", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
""" | ||
Generated from ``clients/src/main/resources/common/message/ApiVersionsRequest.json``. | ||
""" | ||
|
||
from dataclasses import dataclass | ||
from dataclasses import field | ||
from typing import ClassVar | ||
|
||
from kio.schema.request_header.v2.header import RequestHeader | ||
from kio.static.constants import EntityType | ||
from kio.static.primitive import i16 | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class ApiVersionsRequest: | ||
__type__: ClassVar = EntityType.request | ||
__version__: ClassVar[i16] = i16(4) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(18) | ||
__header_schema__: ClassVar[type[RequestHeader]] = RequestHeader | ||
client_software_name: str = field(metadata={"kafka_type": "string"}) | ||
"""The name of the client.""" | ||
client_software_version: str = field(metadata={"kafka_type": "string"}) | ||
"""The version of the client.""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
""" | ||
Generated from ``clients/src/main/resources/common/message/ApiVersionsResponse.json``. | ||
""" | ||
|
||
from dataclasses import dataclass | ||
from dataclasses import field | ||
from typing import ClassVar | ||
|
||
from kio.schema.errors import ErrorCode | ||
from kio.schema.response_header.v0.header import ResponseHeader | ||
from kio.static.constants import EntityType | ||
from kio.static.primitive import i16 | ||
from kio.static.primitive import i32Timedelta | ||
from kio.static.primitive import i64 | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class ApiVersion: | ||
__type__: ClassVar = EntityType.nested | ||
__version__: ClassVar[i16] = i16(4) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(18) | ||
__header_schema__: ClassVar[type[ResponseHeader]] = ResponseHeader | ||
api_key: i16 = field(metadata={"kafka_type": "int16"}) | ||
"""The API index.""" | ||
min_version: i16 = field(metadata={"kafka_type": "int16"}) | ||
"""The minimum supported version, inclusive.""" | ||
max_version: i16 = field(metadata={"kafka_type": "int16"}) | ||
"""The maximum supported version, inclusive.""" | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class SupportedFeatureKey: | ||
__type__: ClassVar = EntityType.nested | ||
__version__: ClassVar[i16] = i16(4) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(18) | ||
__header_schema__: ClassVar[type[ResponseHeader]] = ResponseHeader | ||
name: str = field(metadata={"kafka_type": "string"}) | ||
"""The name of the feature.""" | ||
min_version: i16 = field(metadata={"kafka_type": "int16"}) | ||
"""The minimum supported version for the feature.""" | ||
max_version: i16 = field(metadata={"kafka_type": "int16"}) | ||
"""The maximum supported version for the feature.""" | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class FinalizedFeatureKey: | ||
__type__: ClassVar = EntityType.nested | ||
__version__: ClassVar[i16] = i16(4) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(18) | ||
__header_schema__: ClassVar[type[ResponseHeader]] = ResponseHeader | ||
name: str = field(metadata={"kafka_type": "string"}) | ||
"""The name of the feature.""" | ||
max_version_level: i16 = field(metadata={"kafka_type": "int16"}) | ||
"""The cluster-wide finalized max version level for the feature.""" | ||
min_version_level: i16 = field(metadata={"kafka_type": "int16"}) | ||
"""The cluster-wide finalized min version level for the feature.""" | ||
|
||
|
||
@dataclass(frozen=True, slots=True, kw_only=True) | ||
class ApiVersionsResponse: | ||
__type__: ClassVar = EntityType.response | ||
__version__: ClassVar[i16] = i16(4) | ||
__flexible__: ClassVar[bool] = True | ||
__api_key__: ClassVar[i16] = i16(18) | ||
__header_schema__: ClassVar[type[ResponseHeader]] = ResponseHeader | ||
error_code: ErrorCode = field(metadata={"kafka_type": "error_code"}) | ||
"""The top-level error code.""" | ||
api_keys: tuple[ApiVersion, ...] | ||
"""The APIs supported by the broker.""" | ||
throttle_time: i32Timedelta = field(metadata={"kafka_type": "timedelta_i32"}) | ||
"""The duration in milliseconds for which the request was throttled due to a quota violation, or zero if the request did not violate any quota.""" | ||
supported_features: tuple[SupportedFeatureKey, ...] = field( | ||
metadata={"tag": 0}, default=() | ||
) | ||
"""Features supported by the broker. Note: in v0-v3, features with MinSupportedVersion = 0 are omitted.""" | ||
finalized_features_epoch: i64 = field( | ||
metadata={"kafka_type": "int64", "tag": 1}, default=i64(-1) | ||
) | ||
"""The monotonically increasing epoch for the finalized features information. Valid values are >= 0. A value of -1 is special and represents unknown epoch.""" | ||
finalized_features: tuple[FinalizedFeatureKey, ...] = field( | ||
metadata={"tag": 2}, default=() | ||
) | ||
"""List of cluster-wide finalized features. The information is valid only if FinalizedFeaturesEpoch >= 0.""" | ||
zk_migration_ready: bool = field( | ||
metadata={"kafka_type": "bool", "tag": 3}, default=False | ||
) | ||
"""Set by a KRaft controller if the required configurations for ZK migration are present""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
from .request import BeginQuorumEpochRequest | ||
from .response import BeginQuorumEpochResponse | ||
|
||
__all__ = ( | ||
"BeginQuorumEpochRequest", | ||
"BeginQuorumEpochResponse", | ||
) |
Oops, something went wrong.