Skip to content

Generator: Update SDK /services/loadbalancer #1271

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
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
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,14 @@
import re
from typing import Any, ClassVar, Dict, List, Optional, Set

from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
from pydantic import (
BaseModel,
ConfigDict,
Field,
StrictBool,
StrictStr,
field_validator,
)
from typing_extensions import Annotated, Self

from stackit.loadbalancer.models.listener import Listener
Expand All @@ -34,6 +41,11 @@ class CreateLoadBalancerPayload(BaseModel):
CreateLoadBalancerPayload
"""

disable_target_security_group_assignment: Optional[StrictBool] = Field(
default=None,
description="Disable target security group assignemt to allow targets outside of the given network. Connectivity to targets need to be ensured by the customer, including routing and Security Groups (targetSecurityGroup can be assigned). Not changeable after creation.",
alias="disableTargetSecurityGroupAssignment",
)
errors: Optional[List[LoadBalancerError]] = Field(
default=None, description="Reports all errors a load balancer has."
)
Expand Down Expand Up @@ -73,14 +85,15 @@ class CreateLoadBalancerPayload(BaseModel):
)
target_security_group: Optional[SecurityGroup] = Field(
default=None,
description="Security Group permitting network traffic from the LoadBalancer to the targets.",
description="Security Group permitting network traffic from the LoadBalancer to the targets. Useful when disableTargetSecurityGroupAssignment=true to manually assign target security groups to targets.",
alias="targetSecurityGroup",
)
version: Optional[StrictStr] = Field(
default=None,
description="Load balancer resource version. Must be empty or unset for creating load balancers, non-empty for updating load balancers. Semantics: While retrieving load balancers, this is the current version of this load balancer resource that changes during updates of the load balancers. On updates this field specified the load balancer version you calculated your update for instead of the future version to enable concurrency safe updates. Update calls will then report the new version in their result as you would see with a load balancer retrieval call later. There exist no total order of the version, so you can only compare it for equality, but not for less/greater than another version. Since the creation of load balancer is always intended to create the first version of it, there should be no existing version. That's why this field must by empty of not present in that case.",
)
__properties: ClassVar[List[str]] = [
"disableTargetSecurityGroupAssignment",
"errors",
"externalAddress",
"listeners",
Expand Down Expand Up @@ -217,6 +230,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:

_obj = cls.model_validate(
{
"disableTargetSecurityGroupAssignment": obj.get("disableTargetSecurityGroupAssignment"),
"errors": (
[LoadBalancerError.from_dict(_item) for _item in obj["errors"]]
if obj.get("errors") is not None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,14 @@
import re
from typing import Any, ClassVar, Dict, List, Optional, Set

from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
from pydantic import (
BaseModel,
ConfigDict,
Field,
StrictBool,
StrictStr,
field_validator,
)
from typing_extensions import Annotated, Self

from stackit.loadbalancer.models.listener import Listener
Expand All @@ -34,6 +41,11 @@ class LoadBalancer(BaseModel):
LoadBalancer
"""

disable_target_security_group_assignment: Optional[StrictBool] = Field(
default=None,
description="Disable target security group assignemt to allow targets outside of the given network. Connectivity to targets need to be ensured by the customer, including routing and Security Groups (targetSecurityGroup can be assigned). Not changeable after creation.",
alias="disableTargetSecurityGroupAssignment",
)
errors: Optional[List[LoadBalancerError]] = Field(
default=None, description="Reports all errors a load balancer has."
)
Expand Down Expand Up @@ -73,14 +85,15 @@ class LoadBalancer(BaseModel):
)
target_security_group: Optional[SecurityGroup] = Field(
default=None,
description="Security Group permitting network traffic from the LoadBalancer to the targets.",
description="Security Group permitting network traffic from the LoadBalancer to the targets. Useful when disableTargetSecurityGroupAssignment=true to manually assign target security groups to targets.",
alias="targetSecurityGroup",
)
version: Optional[StrictStr] = Field(
default=None,
description="Load balancer resource version. Must be empty or unset for creating load balancers, non-empty for updating load balancers. Semantics: While retrieving load balancers, this is the current version of this load balancer resource that changes during updates of the load balancers. On updates this field specified the load balancer version you calculated your update for instead of the future version to enable concurrency safe updates. Update calls will then report the new version in their result as you would see with a load balancer retrieval call later. There exist no total order of the version, so you can only compare it for equality, but not for less/greater than another version. Since the creation of load balancer is always intended to create the first version of it, there should be no existing version. That's why this field must by empty of not present in that case.",
)
__properties: ClassVar[List[str]] = [
"disableTargetSecurityGroupAssignment",
"errors",
"externalAddress",
"listeners",
Expand Down Expand Up @@ -217,6 +230,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:

_obj = cls.model_validate(
{
"disableTargetSecurityGroupAssignment": obj.get("disableTargetSecurityGroupAssignment"),
"errors": (
[LoadBalancerError.from_dict(_item) for _item in obj["errors"]]
if obj.get("errors") is not None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,14 @@
import re
from typing import Any, ClassVar, Dict, List, Optional, Set

from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
from pydantic import (
BaseModel,
ConfigDict,
Field,
StrictBool,
StrictStr,
field_validator,
)
from typing_extensions import Annotated, Self

from stackit.loadbalancer.models.listener import Listener
Expand All @@ -34,6 +41,11 @@ class UpdateLoadBalancerPayload(BaseModel):
UpdateLoadBalancerPayload
"""

disable_target_security_group_assignment: Optional[StrictBool] = Field(
default=None,
description="Disable target security group assignemt to allow targets outside of the given network. Connectivity to targets need to be ensured by the customer, including routing and Security Groups (targetSecurityGroup can be assigned). Not changeable after creation.",
alias="disableTargetSecurityGroupAssignment",
)
errors: Optional[List[LoadBalancerError]] = Field(
default=None, description="Reports all errors a load balancer has."
)
Expand Down Expand Up @@ -73,14 +85,15 @@ class UpdateLoadBalancerPayload(BaseModel):
)
target_security_group: Optional[SecurityGroup] = Field(
default=None,
description="Security Group permitting network traffic from the LoadBalancer to the targets.",
description="Security Group permitting network traffic from the LoadBalancer to the targets. Useful when disableTargetSecurityGroupAssignment=true to manually assign target security groups to targets.",
alias="targetSecurityGroup",
)
version: Optional[StrictStr] = Field(
default=None,
description="Load balancer resource version. Must be empty or unset for creating load balancers, non-empty for updating load balancers. Semantics: While retrieving load balancers, this is the current version of this load balancer resource that changes during updates of the load balancers. On updates this field specified the load balancer version you calculated your update for instead of the future version to enable concurrency safe updates. Update calls will then report the new version in their result as you would see with a load balancer retrieval call later. There exist no total order of the version, so you can only compare it for equality, but not for less/greater than another version. Since the creation of load balancer is always intended to create the first version of it, there should be no existing version. That's why this field must by empty of not present in that case.",
)
__properties: ClassVar[List[str]] = [
"disableTargetSecurityGroupAssignment",
"errors",
"externalAddress",
"listeners",
Expand Down Expand Up @@ -217,6 +230,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:

_obj = cls.model_validate(
{
"disableTargetSecurityGroupAssignment": obj.get("disableTargetSecurityGroupAssignment"),
"errors": (
[LoadBalancerError.from_dict(_item) for _item in obj["errors"]]
if obj.get("errors") is not None
Expand Down
Loading