Skip to content

Commit

Permalink
Generated from e1fc2e1bdad54c396693d98c655354fc82f8f36b (#2885)
Browse files Browse the repository at this point in the history
1) Fix for linter error "Properties of a PATCH request body must not be default-valued. PATCH operation: 'EventSubscriptions_Update' Model Definition: 'EventSubscriptionUpdateParameters' Property: 'eventDeliverySchema'".
2) Updated the default value of EventDeliverySchema to the correct value used by the service.
  • Loading branch information
AutorestCI authored Jul 10, 2018
1 parent cc37a54 commit 70a3250
Show file tree
Hide file tree
Showing 15 changed files with 20 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .event_subscription_destination import EventSubscriptionDestination
from .event_subscription_destination_py3 import EventSubscriptionDestination


class EventHubEventSubscriptionDestination(EventSubscriptionDestination):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class EventSubscription(Resource):
:param event_delivery_schema: The event delivery schema for the event
subscription. Possible values include: 'EventGridSchema',
'InputEventSchema', 'CloudEventV01Schema'. Default value:
"EventGridSchema" .
"InputEventSchema" .
:type event_delivery_schema: str or
~azure.mgmt.eventgrid.models.EventDeliverySchema
:param retry_policy: The retry policy for events. This can be used to
Expand Down Expand Up @@ -83,6 +83,6 @@ def __init__(self, **kwargs):
self.destination = kwargs.get('destination', None)
self.filter = kwargs.get('filter', None)
self.labels = kwargs.get('labels', None)
self.event_delivery_schema = kwargs.get('event_delivery_schema', "EventGridSchema")
self.event_delivery_schema = kwargs.get('event_delivery_schema', "InputEventSchema")
self.retry_policy = kwargs.get('retry_policy', None)
self.dead_letter_destination = kwargs.get('dead_letter_destination', None)
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .resource import Resource
from .resource_py3 import Resource


class EventSubscription(Resource):
Expand Down Expand Up @@ -42,7 +42,7 @@ class EventSubscription(Resource):
:param event_delivery_schema: The event delivery schema for the event
subscription. Possible values include: 'EventGridSchema',
'InputEventSchema', 'CloudEventV01Schema'. Default value:
"EventGridSchema" .
"InputEventSchema" .
:type event_delivery_schema: str or
~azure.mgmt.eventgrid.models.EventDeliverySchema
:param retry_policy: The retry policy for events. This can be used to
Expand Down Expand Up @@ -76,7 +76,7 @@ class EventSubscription(Resource):
'dead_letter_destination': {'key': 'properties.deadLetterDestination', 'type': 'DeadLetterDestination'},
}

def __init__(self, *, destination=None, filter=None, labels=None, event_delivery_schema="EventGridSchema", retry_policy=None, dead_letter_destination=None, **kwargs) -> None:
def __init__(self, *, destination=None, filter=None, labels=None, event_delivery_schema="InputEventSchema", retry_policy=None, dead_letter_destination=None, **kwargs) -> None:
super(EventSubscription, self).__init__(**kwargs)
self.topic = None
self.provisioning_state = None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@ class EventSubscriptionUpdateParameters(Model):
:type labels: list[str]
:param event_delivery_schema: The event delivery schema for the event
subscription. Possible values include: 'EventGridSchema',
'InputEventSchema', 'CloudEventV01Schema'. Default value:
"EventGridSchema" .
'InputEventSchema', 'CloudEventV01Schema'
:type event_delivery_schema: str or
~azure.mgmt.eventgrid.models.EventDeliverySchema
:param retry_policy: The retry policy for events. This can be used to
Expand All @@ -52,6 +51,6 @@ def __init__(self, **kwargs):
self.destination = kwargs.get('destination', None)
self.filter = kwargs.get('filter', None)
self.labels = kwargs.get('labels', None)
self.event_delivery_schema = kwargs.get('event_delivery_schema', "EventGridSchema")
self.event_delivery_schema = kwargs.get('event_delivery_schema', None)
self.retry_policy = kwargs.get('retry_policy', None)
self.dead_letter_destination = kwargs.get('dead_letter_destination', None)
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@ class EventSubscriptionUpdateParameters(Model):
:type labels: list[str]
:param event_delivery_schema: The event delivery schema for the event
subscription. Possible values include: 'EventGridSchema',
'InputEventSchema', 'CloudEventV01Schema'. Default value:
"EventGridSchema" .
'InputEventSchema', 'CloudEventV01Schema'
:type event_delivery_schema: str or
~azure.mgmt.eventgrid.models.EventDeliverySchema
:param retry_policy: The retry policy for events. This can be used to
Expand All @@ -47,7 +46,7 @@ class EventSubscriptionUpdateParameters(Model):
'dead_letter_destination': {'key': 'deadLetterDestination', 'type': 'DeadLetterDestination'},
}

def __init__(self, *, destination=None, filter=None, labels=None, event_delivery_schema="EventGridSchema", retry_policy=None, dead_letter_destination=None, **kwargs) -> None:
def __init__(self, *, destination=None, filter=None, labels=None, event_delivery_schema=None, retry_policy=None, dead_letter_destination=None, **kwargs) -> None:
super(EventSubscriptionUpdateParameters, self).__init__(**kwargs)
self.destination = destination
self.filter = filter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .resource import Resource
from .resource_py3 import Resource


class EventType(Resource):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .event_subscription_destination import EventSubscriptionDestination
from .event_subscription_destination_py3 import EventSubscriptionDestination


class HybridConnectionEventSubscriptionDestination(EventSubscriptionDestination):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .input_schema_mapping import InputSchemaMapping
from .input_schema_mapping_py3 import InputSchemaMapping


class JsonInputSchemaMapping(InputSchemaMapping):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .dead_letter_destination import DeadLetterDestination
from .dead_letter_destination_py3 import DeadLetterDestination


class StorageBlobDeadLetterDestination(DeadLetterDestination):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .event_subscription_destination import EventSubscriptionDestination
from .event_subscription_destination_py3 import EventSubscriptionDestination


class StorageQueueEventSubscriptionDestination(EventSubscriptionDestination):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .tracked_resource import TrackedResource
from .tracked_resource_py3 import TrackedResource


class Topic(TrackedResource):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .resource import Resource
from .resource_py3 import Resource


class TopicTypeInfo(Resource):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .resource import Resource
from .resource_py3 import Resource


class TrackedResource(Resource):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------

from .event_subscription_destination import EventSubscriptionDestination
from .event_subscription_destination_py3 import EventSubscriptionDestination


class WebHookEventSubscriptionDestination(EventSubscriptionDestination):
Expand Down
2 changes: 1 addition & 1 deletion azure-mgmt-eventgrid/azure/mgmt/eventgrid/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
# regenerated.
# --------------------------------------------------------------------------

VERSION = "2.0.0rc1"
VERSION = "1.0.0"

0 comments on commit 70a3250

Please sign in to comment.