Package pulp :: Package server :: Package event :: Package handler :: Module product :: Class ProductEvent
[hide private]
[frames] | no frames]

Class ProductEvent

source code

??-287 --+
         |
        ProductEvent

The product event handler.

Instance Methods [hide private]
 
__init__(self) source code
 
create(self, *args, **kwargs)
Raise events when a product is created.
source code
 
update(self, *args, **kwargs)
Raise events when a product is updated.
source code
 
delete(self, *args, **kwargs)
Raise events when a product is deleted.
source code
 
created(self, event)
The inbound event handler for product.created AMQP events.
source code
 
updated(self, event)
The inbound event handler for product.updated AMQP events.
source code
 
deleted(self, event)
The inbound event handler for product.deleted AMQP events.
source code
Instance Variables [hide private]
productApi rapi
The product API object.
Method Details [hide private]

create(self, *args, **kwargs)

source code 

Raise events when a product is created. Called when productApi.create() is called.

Parameters:
  • args (list) - The arguments passed to productApi.create()
  • kwargs (list) - The keyword arguments passed to productApi.create()
Decorators:
  • @outbound(action= 'created')

update(self, *args, **kwargs)

source code 

Raise events when a product is updated. Called when productApi.update() is called.

Parameters:
  • args (list) - The arguments passed to productApi.update()
  • kwargs (list) - The keyword arguments passed to productApi.update()
Decorators:
  • @outbound(action= 'updated')

delete(self, *args, **kwargs)

source code 

Raise events when a product is deleted. Called when productApi.delete() is called.

Parameters:
  • args (list) - The arguments passed to productApi.delete()
  • kwargs (list) - The keyword arguments passed to productApi.delete()
Decorators:
  • @outbound(action= 'deleted')

created(self, event)

source code 

The inbound event handler for product.created AMQP events. Called when an AMQP event is received notifying that a product has been created. When received, the API is used to create the specified product in pulp.

Parameters:
  • event (dict.) - The event payload.
Decorators:
  • @inbound(action= 'created')

updated(self, event)

source code 

The inbound event handler for product.updated AMQP events. Called when an AMQP event is received notifying that a product has been created. When received, the API is used to update the specified product in pulp.

Parameters:
  • event (dict.) - The event payload.
Decorators:
  • @inbound(action= 'updated')

deleted(self, event)

source code 

The inbound event handler for product.deleted AMQP events. Called when an AMQP event is received notifying that a product has been deleted. When received, the API is used to delete the specified product in pulp.

Parameters:
  • event (dict.) - The event payload.
Decorators:
  • @inbound(action= 'deleted')