Skip to content

Commit

Permalink
[AutoPR servicefabric/data-plane] Swagger specification for Service F…
Browse files Browse the repository at this point in the history
…abric runtime version 6.4 (#3898)

* Generated from 6415c5920fc51ac978815e71c12089643a219c49

Swagger specification for Service Fabric runtime version 6.4

* Generated from c69b3d22ae7f74ae4932d3fdce146ff567441664

fix typos specificed -> specified, sucessful -> successful, resturns -> returns, commited -> committed, Double word "maximum", Double word "with"

* Generated from 494e01db96f17beb1d349ab74358274971b26d08

remove invalid character
  • Loading branch information
AutorestCI authored Dec 5, 2018
1 parent 7d59a31 commit 3335ed7
Show file tree
Hide file tree
Showing 294 changed files with 8,060 additions and 2,761 deletions.
481 changes: 306 additions & 175 deletions azure-servicefabric/azure/servicefabric/models/__init__.py

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .auto_scaling_mechanism import AutoScalingMechanism


class AddRemoveReplicaScalingMechanism(AutoScalingMechanism):
"""Describes the horizontal auto scaling mechanism that adds or removes
replicas (containers or container groups).
All required parameters must be populated in order to send to Azure.
:param kind: Required. Constant filled by server.
:type kind: str
:param min_count: Required. Minimum number of containers (scale down won't
be performed below this number).
:type min_count: int
:param max_count: Required. Maximum number of containers (scale up won't
be performed above this number).
:type max_count: int
:param scale_increment: Required. Each time auto scaling is performed,
this number of containers will be added or removed.
:type scale_increment: int
"""

_validation = {
'kind': {'required': True},
'min_count': {'required': True},
'max_count': {'required': True},
'scale_increment': {'required': True},
}

_attribute_map = {
'kind': {'key': 'kind', 'type': 'str'},
'min_count': {'key': 'minCount', 'type': 'int'},
'max_count': {'key': 'maxCount', 'type': 'int'},
'scale_increment': {'key': 'scaleIncrement', 'type': 'int'},
}

def __init__(self, **kwargs):
super(AddRemoveReplicaScalingMechanism, self).__init__(**kwargs)
self.min_count = kwargs.get('min_count', None)
self.max_count = kwargs.get('max_count', None)
self.scale_increment = kwargs.get('scale_increment', None)
self.kind = 'AddRemoveReplica'
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .auto_scaling_mechanism_py3 import AutoScalingMechanism


class AddRemoveReplicaScalingMechanism(AutoScalingMechanism):
"""Describes the horizontal auto scaling mechanism that adds or removes
replicas (containers or container groups).
All required parameters must be populated in order to send to Azure.
:param kind: Required. Constant filled by server.
:type kind: str
:param min_count: Required. Minimum number of containers (scale down won't
be performed below this number).
:type min_count: int
:param max_count: Required. Maximum number of containers (scale up won't
be performed above this number).
:type max_count: int
:param scale_increment: Required. Each time auto scaling is performed,
this number of containers will be added or removed.
:type scale_increment: int
"""

_validation = {
'kind': {'required': True},
'min_count': {'required': True},
'max_count': {'required': True},
'scale_increment': {'required': True},
}

_attribute_map = {
'kind': {'key': 'kind', 'type': 'str'},
'min_count': {'key': 'minCount', 'type': 'int'},
'max_count': {'key': 'maxCount', 'type': 'int'},
'scale_increment': {'key': 'scaleIncrement', 'type': 'int'},
}

def __init__(self, *, min_count: int, max_count: int, scale_increment: int, **kwargs) -> None:
super(AddRemoveReplicaScalingMechanism, self).__init__(**kwargs)
self.min_count = min_count
self.max_count = max_count
self.scale_increment = scale_increment
self.kind = 'AddRemoveReplica'
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,16 @@
from .application_event import ApplicationEvent


class ContainerDeactivatedEvent(ApplicationEvent):
"""Container Deactivated event.
class ApplicationContainerInstanceExitedEvent(ApplicationEvent):
"""Container Exited event.
All required parameters must be populated in order to send to Azure.
:param event_instance_id: Required. The identifier for the FabricEvent
instance.
:type event_instance_id: str
:param category: The category of event.
:type category: str
:param time_stamp: Required. The time event was logged.
:type time_stamp: datetime
:param has_correlated_events: Shows there is existing related events
Expand Down Expand Up @@ -84,6 +86,7 @@ class ContainerDeactivatedEvent(ApplicationEvent):

_attribute_map = {
'event_instance_id': {'key': 'EventInstanceId', 'type': 'str'},
'category': {'key': 'Category', 'type': 'str'},
'time_stamp': {'key': 'TimeStamp', 'type': 'iso-8601'},
'has_correlated_events': {'key': 'HasCorrelatedEvents', 'type': 'bool'},
'kind': {'key': 'Kind', 'type': 'str'},
Expand All @@ -103,7 +106,7 @@ class ContainerDeactivatedEvent(ApplicationEvent):
}

def __init__(self, **kwargs):
super(ContainerDeactivatedEvent, self).__init__(**kwargs)
super(ApplicationContainerInstanceExitedEvent, self).__init__(**kwargs)
self.service_name = kwargs.get('service_name', None)
self.service_package_name = kwargs.get('service_package_name', None)
self.service_package_activation_id = kwargs.get('service_package_activation_id', None)
Expand All @@ -116,4 +119,4 @@ def __init__(self, **kwargs):
self.exit_code = kwargs.get('exit_code', None)
self.unexpected_termination = kwargs.get('unexpected_termination', None)
self.start_time = kwargs.get('start_time', None)
self.kind = 'ContainerDeactivated'
self.kind = 'ApplicationContainerInstanceExited'
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,16 @@
from .application_event_py3 import ApplicationEvent


class ContainerDeactivatedEvent(ApplicationEvent):
"""Container Deactivated event.
class ApplicationContainerInstanceExitedEvent(ApplicationEvent):
"""Container Exited event.
All required parameters must be populated in order to send to Azure.
:param event_instance_id: Required. The identifier for the FabricEvent
instance.
:type event_instance_id: str
:param category: The category of event.
:type category: str
:param time_stamp: Required. The time event was logged.
:type time_stamp: datetime
:param has_correlated_events: Shows there is existing related events
Expand Down Expand Up @@ -84,6 +86,7 @@ class ContainerDeactivatedEvent(ApplicationEvent):

_attribute_map = {
'event_instance_id': {'key': 'EventInstanceId', 'type': 'str'},
'category': {'key': 'Category', 'type': 'str'},
'time_stamp': {'key': 'TimeStamp', 'type': 'iso-8601'},
'has_correlated_events': {'key': 'HasCorrelatedEvents', 'type': 'bool'},
'kind': {'key': 'Kind', 'type': 'str'},
Expand All @@ -102,8 +105,8 @@ class ContainerDeactivatedEvent(ApplicationEvent):
'start_time': {'key': 'StartTime', 'type': 'iso-8601'},
}

def __init__(self, *, event_instance_id: str, time_stamp, application_id: str, service_name: str, service_package_name: str, service_package_activation_id: str, is_exclusive: bool, code_package_name: str, entry_point_type: str, image_name: str, container_name: str, host_id: str, exit_code: int, unexpected_termination: bool, start_time, has_correlated_events: bool=None, **kwargs) -> None:
super(ContainerDeactivatedEvent, self).__init__(event_instance_id=event_instance_id, time_stamp=time_stamp, has_correlated_events=has_correlated_events, application_id=application_id, **kwargs)
def __init__(self, *, event_instance_id: str, time_stamp, application_id: str, service_name: str, service_package_name: str, service_package_activation_id: str, is_exclusive: bool, code_package_name: str, entry_point_type: str, image_name: str, container_name: str, host_id: str, exit_code: int, unexpected_termination: bool, start_time, category: str=None, has_correlated_events: bool=None, **kwargs) -> None:
super(ApplicationContainerInstanceExitedEvent, self).__init__(event_instance_id=event_instance_id, category=category, time_stamp=time_stamp, has_correlated_events=has_correlated_events, application_id=application_id, **kwargs)
self.service_name = service_name
self.service_package_name = service_package_name
self.service_package_activation_id = service_package_activation_id
Expand All @@ -116,4 +119,4 @@ def __init__(self, *, event_instance_id: str, time_stamp, application_id: str, s
self.exit_code = exit_code
self.unexpected_termination = unexpected_termination
self.start_time = start_time
self.kind = 'ContainerDeactivated'
self.kind = 'ApplicationContainerInstanceExited'
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class ApplicationCreatedEvent(ApplicationEvent):
:param event_instance_id: Required. The identifier for the FabricEvent
instance.
:type event_instance_id: str
:param category: The category of event.
:type category: str
:param time_stamp: Required. The time event was logged.
:type time_stamp: datetime
:param has_correlated_events: Shows there is existing related events
Expand Down Expand Up @@ -55,6 +57,7 @@ class ApplicationCreatedEvent(ApplicationEvent):

_attribute_map = {
'event_instance_id': {'key': 'EventInstanceId', 'type': 'str'},
'category': {'key': 'Category', 'type': 'str'},
'time_stamp': {'key': 'TimeStamp', 'type': 'iso-8601'},
'has_correlated_events': {'key': 'HasCorrelatedEvents', 'type': 'bool'},
'kind': {'key': 'Kind', 'type': 'str'},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class ApplicationCreatedEvent(ApplicationEvent):
:param event_instance_id: Required. The identifier for the FabricEvent
instance.
:type event_instance_id: str
:param category: The category of event.
:type category: str
:param time_stamp: Required. The time event was logged.
:type time_stamp: datetime
:param has_correlated_events: Shows there is existing related events
Expand Down Expand Up @@ -55,6 +57,7 @@ class ApplicationCreatedEvent(ApplicationEvent):

_attribute_map = {
'event_instance_id': {'key': 'EventInstanceId', 'type': 'str'},
'category': {'key': 'Category', 'type': 'str'},
'time_stamp': {'key': 'TimeStamp', 'type': 'iso-8601'},
'has_correlated_events': {'key': 'HasCorrelatedEvents', 'type': 'bool'},
'kind': {'key': 'Kind', 'type': 'str'},
Expand All @@ -64,8 +67,8 @@ class ApplicationCreatedEvent(ApplicationEvent):
'application_definition_kind': {'key': 'ApplicationDefinitionKind', 'type': 'str'},
}

def __init__(self, *, event_instance_id: str, time_stamp, application_id: str, application_type_name: str, application_type_version: str, application_definition_kind: str, has_correlated_events: bool=None, **kwargs) -> None:
super(ApplicationCreatedEvent, self).__init__(event_instance_id=event_instance_id, time_stamp=time_stamp, has_correlated_events=has_correlated_events, application_id=application_id, **kwargs)
def __init__(self, *, event_instance_id: str, time_stamp, application_id: str, application_type_name: str, application_type_version: str, application_definition_kind: str, category: str=None, has_correlated_events: bool=None, **kwargs) -> None:
super(ApplicationCreatedEvent, self).__init__(event_instance_id=event_instance_id, category=category, time_stamp=time_stamp, has_correlated_events=has_correlated_events, application_id=application_id, **kwargs)
self.application_type_name = application_type_name
self.application_type_version = application_type_version
self.application_definition_kind = application_definition_kind
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class ApplicationDeletedEvent(ApplicationEvent):
:param event_instance_id: Required. The identifier for the FabricEvent
instance.
:type event_instance_id: str
:param category: The category of event.
:type category: str
:param time_stamp: Required. The time event was logged.
:type time_stamp: datetime
:param has_correlated_events: Shows there is existing related events
Expand Down Expand Up @@ -52,6 +54,7 @@ class ApplicationDeletedEvent(ApplicationEvent):

_attribute_map = {
'event_instance_id': {'key': 'EventInstanceId', 'type': 'str'},
'category': {'key': 'Category', 'type': 'str'},
'time_stamp': {'key': 'TimeStamp', 'type': 'iso-8601'},
'has_correlated_events': {'key': 'HasCorrelatedEvents', 'type': 'bool'},
'kind': {'key': 'Kind', 'type': 'str'},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class ApplicationDeletedEvent(ApplicationEvent):
:param event_instance_id: Required. The identifier for the FabricEvent
instance.
:type event_instance_id: str
:param category: The category of event.
:type category: str
:param time_stamp: Required. The time event was logged.
:type time_stamp: datetime
:param has_correlated_events: Shows there is existing related events
Expand Down Expand Up @@ -52,6 +54,7 @@ class ApplicationDeletedEvent(ApplicationEvent):

_attribute_map = {
'event_instance_id': {'key': 'EventInstanceId', 'type': 'str'},
'category': {'key': 'Category', 'type': 'str'},
'time_stamp': {'key': 'TimeStamp', 'type': 'iso-8601'},
'has_correlated_events': {'key': 'HasCorrelatedEvents', 'type': 'bool'},
'kind': {'key': 'Kind', 'type': 'str'},
Expand All @@ -60,8 +63,8 @@ class ApplicationDeletedEvent(ApplicationEvent):
'application_type_version': {'key': 'ApplicationTypeVersion', 'type': 'str'},
}

def __init__(self, *, event_instance_id: str, time_stamp, application_id: str, application_type_name: str, application_type_version: str, has_correlated_events: bool=None, **kwargs) -> None:
super(ApplicationDeletedEvent, self).__init__(event_instance_id=event_instance_id, time_stamp=time_stamp, has_correlated_events=has_correlated_events, application_id=application_id, **kwargs)
def __init__(self, *, event_instance_id: str, time_stamp, application_id: str, application_type_name: str, application_type_version: str, category: str=None, has_correlated_events: bool=None, **kwargs) -> None:
super(ApplicationDeletedEvent, self).__init__(event_instance_id=event_instance_id, category=category, time_stamp=time_stamp, has_correlated_events=has_correlated_events, application_id=application_id, **kwargs)
self.application_type_name = application_type_name
self.application_type_version = application_type_version
self.kind = 'ApplicationDeleted'
25 changes: 14 additions & 11 deletions azure-servicefabric/azure/servicefabric/models/application_event.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,24 @@ class ApplicationEvent(FabricEvent):
You probably want to use the sub-classes and not this class directly. Known
sub-classes are: ApplicationCreatedEvent, ApplicationDeletedEvent,
ApplicationHealthReportCreatedEvent, ApplicationHealthReportExpiredEvent,
ApplicationUpgradeCompleteEvent, ApplicationUpgradeDomainCompleteEvent,
ApplicationUpgradeRollbackCompleteEvent,
ApplicationUpgradeRollbackStartEvent, ApplicationUpgradeStartEvent,
DeployedApplicationHealthReportCreatedEvent,
DeployedApplicationHealthReportExpiredEvent, ProcessDeactivatedEvent,
ContainerDeactivatedEvent, DeployedServiceHealthReportCreatedEvent,
DeployedServiceHealthReportExpiredEvent,
ChaosRestartCodePackageFaultScheduledEvent,
ChaosRestartCodePackageFaultCompletedEvent
ApplicationNewHealthReportEvent, ApplicationHealthReportExpiredEvent,
ApplicationUpgradeCompletedEvent, ApplicationUpgradeDomainCompletedEvent,
ApplicationUpgradeRollbackCompletedEvent,
ApplicationUpgradeRollbackStartedEvent, ApplicationUpgradeStartedEvent,
DeployedApplicationNewHealthReportEvent,
DeployedApplicationHealthReportExpiredEvent, ApplicationProcessExitedEvent,
ApplicationContainerInstanceExitedEvent,
DeployedServicePackageNewHealthReportEvent,
DeployedServicePackageHealthReportExpiredEvent,
ChaosCodePackageRestartScheduledEvent
All required parameters must be populated in order to send to Azure.
:param event_instance_id: Required. The identifier for the FabricEvent
instance.
:type event_instance_id: str
:param category: The category of event.
:type category: str
:param time_stamp: Required. The time event was logged.
:type time_stamp: datetime
:param has_correlated_events: Shows there is existing related events
Expand All @@ -59,14 +61,15 @@ class ApplicationEvent(FabricEvent):

_attribute_map = {
'event_instance_id': {'key': 'EventInstanceId', 'type': 'str'},
'category': {'key': 'Category', 'type': 'str'},
'time_stamp': {'key': 'TimeStamp', 'type': 'iso-8601'},
'has_correlated_events': {'key': 'HasCorrelatedEvents', 'type': 'bool'},
'kind': {'key': 'Kind', 'type': 'str'},
'application_id': {'key': 'ApplicationId', 'type': 'str'},
}

_subtype_map = {
'kind': {'ApplicationCreated': 'ApplicationCreatedEvent', 'ApplicationDeleted': 'ApplicationDeletedEvent', 'ApplicationHealthReportCreated': 'ApplicationHealthReportCreatedEvent', 'ApplicationHealthReportExpired': 'ApplicationHealthReportExpiredEvent', 'ApplicationUpgradeComplete': 'ApplicationUpgradeCompleteEvent', 'ApplicationUpgradeDomainComplete': 'ApplicationUpgradeDomainCompleteEvent', 'ApplicationUpgradeRollbackComplete': 'ApplicationUpgradeRollbackCompleteEvent', 'ApplicationUpgradeRollbackStart': 'ApplicationUpgradeRollbackStartEvent', 'ApplicationUpgradeStart': 'ApplicationUpgradeStartEvent', 'DeployedApplicationHealthReportCreated': 'DeployedApplicationHealthReportCreatedEvent', 'DeployedApplicationHealthReportExpired': 'DeployedApplicationHealthReportExpiredEvent', 'ProcessDeactivated': 'ProcessDeactivatedEvent', 'ContainerDeactivated': 'ContainerDeactivatedEvent', 'DeployedServiceHealthReportCreated': 'DeployedServiceHealthReportCreatedEvent', 'DeployedServiceHealthReportExpired': 'DeployedServiceHealthReportExpiredEvent', 'ChaosRestartCodePackageFaultScheduled': 'ChaosRestartCodePackageFaultScheduledEvent', 'ChaosRestartCodePackageFaultCompleted': 'ChaosRestartCodePackageFaultCompletedEvent'}
'kind': {'ApplicationCreated': 'ApplicationCreatedEvent', 'ApplicationDeleted': 'ApplicationDeletedEvent', 'ApplicationNewHealthReport': 'ApplicationNewHealthReportEvent', 'ApplicationHealthReportExpired': 'ApplicationHealthReportExpiredEvent', 'ApplicationUpgradeCompleted': 'ApplicationUpgradeCompletedEvent', 'ApplicationUpgradeDomainCompleted': 'ApplicationUpgradeDomainCompletedEvent', 'ApplicationUpgradeRollbackCompleted': 'ApplicationUpgradeRollbackCompletedEvent', 'ApplicationUpgradeRollbackStarted': 'ApplicationUpgradeRollbackStartedEvent', 'ApplicationUpgradeStarted': 'ApplicationUpgradeStartedEvent', 'DeployedApplicationNewHealthReport': 'DeployedApplicationNewHealthReportEvent', 'DeployedApplicationHealthReportExpired': 'DeployedApplicationHealthReportExpiredEvent', 'ApplicationProcessExited': 'ApplicationProcessExitedEvent', 'ApplicationContainerInstanceExited': 'ApplicationContainerInstanceExitedEvent', 'DeployedServicePackageNewHealthReport': 'DeployedServicePackageNewHealthReportEvent', 'DeployedServicePackageHealthReportExpired': 'DeployedServicePackageHealthReportExpiredEvent', 'ChaosCodePackageRestartScheduled': 'ChaosCodePackageRestartScheduledEvent'}
}

def __init__(self, **kwargs):
Expand Down
Loading

0 comments on commit 3335ed7

Please sign in to comment.