• No results found

The TypedSupplierAdmin Interface

In document Notification Service Specification (Page 171-174)

Remaining Bodydomain_name

SupplierAdmin 3 instance, which created a given TypedProxyPullConsumer

3.6.6 The TypedSupplierAdmin Interface

TheTypedSupplierAdmininterface defines the behavior supported by objects that create and manage lists of proxy consumer objects within a Notification Service typed event channel. Similar to its untyped counterpart, a Notification Service typed event channel can have any number ofTypedSupplierAdmininstances associated with it. Each such instance is responsible for creating and managing a list of proxy consumer objects that share a common set of QoS property settings, and a common set of filter objects. This feature enables clients to conveniently group proxy supplier objects within a channel into groupings that each support a set of consumers with a common set of QoS requirements and event subscriptions.

Note that theTypedSupplierAdmininterface inherits fromSupplierAdmin

interface defined in theCosNotifyChannelAdminmodule, and the

TypedSupplierAdmininterface defined in theCosTypedEventChannelAdmin

module. These inheritance relationships have several implications for a Notification Service styleTypedSupplierAdmininstance.

First, inheritance of theSupplierAdmininterface defined in the

CosNotifyChannelAdminmodule implies that in addition to being capable of creating and managing Notification Service style typed proxy consumer objects, a

TypedSupplierAdmininstance can also create and manage instances supporting any of the proxy consumer interfaces defined in theCosNotifyChannelAdminmodule. In addition, since theSupplierAdmininterface defined in the

CosNotifyChannelAdminmodule inherits from theSupplierAdmininterface defined in theCosEventChannelAdminmodule, aTypedSupplierAdmincan also create and manage OMG Event service style untyped proxy consumer objects.

Likewise, inheritance of theTypedSupplierAdmininterface defined in the

CosTypedEventChannelAdminmodule implies that an instance supporting the

CosTypedNotifyChannelAdmin’s version of TypedSupplierAdmincan create and manage OMG Event Service style typed proxy consumer objects as well. Thus, instances supporting theTypedSupplierAdmininterface defined in the

CosTypedNotifyChannelAdminmodule can potentially create and manage instances supporting any of the proxy consumer interfaces defined in the

CosEventChannelAdmin,CosNotifyChannelAdmin,

CosTypedEventChannelAdmin, and theCosTypedNotifyChannelAdmin(due to locally defined factory operations) modules. The implication of this is that a Notification Service style typed event channel can support OMG Event Service style untyped and typed suppliers, along with all variations of suppliers defined in the Notification Service as clients.

Note also that the inheritedCosNotifyChannelAdmin::SupplierAdmininterface provides an instance supporting the

CosTypedNotifyChannelAdmin::TypedSupplierAdmininterface with the behaviors necessary to associate unique identifiers with the proxy consumer objects it creates. While theTypedSupplierAdmininterface defined here is capable of creating OMG Event Service style untyped and typed proxy supplier objects, only instances of the proxy supplier interfaces defined in the Notification Service can have associated unique identifiers.

Similarly, the inheritance of theSupplierAdmininterface defined in the

CosNotifyChannelAdminmodule provides an instance supporting the

TypedSupplierAdmininterface defined in theCosTypedNotifyChannelAdmin

module with the behaviors necessary to maintain associated QoS property settings and filter objects. The relationships between the QoS property settings and filter objects to the proxy consumer objects created by aTypedSupplierAdmininstance are identical to those described in Section 3.4.16, “The SupplierAdmin Interface,” on page 3-76. Note again that QoS property settings and filter objects can only be associated with Notification Service style proxy consumers, both typed and untyped.

Inheritance of theSupplierAdmininterface defined inCosNotifyChannelAdmin

also implies thatTypedSupplierAdminalso inherits from the NotifyPublish

interface defined inCosNotifyComm. This inheritance enables optimizing the notification of a group of proxy consumer objects that have been created by the same

TypedSupplierAdmininstance of changes to the types of events being offered to them by suppliers, since this inheritance enables aTypedSupplierAdmininstance to be the target of anoffer_changeoperation. Lastly, inheritance of the

SupplierAdmininterface defined inCosNotifyChannelAdminimplies that an instance of theTypedSupplierAdmininterface supports readonly attributes that maintain the unique identifier of the instance supplied to it by its creating channel, the object reference of the creating channel, and the flag which indicates whether AND or OR semantics will be used when combining the filter objects associated with a

TypedSupplierAdminwith those defined on specific proxy consumers created by the

Locally, theTypedSupplierAdmininterface supports the operations that create new Notification Service style typed proxy consumer instances. Note lastly that due to inheritance of theSupplierAdmininterface defined in the

CosNotifyChannelAdminmodule, an instance supporting the

TypedSupplierAdmininterface supports a readonly attribute which maintains a unique identifier assigned to the instance by the channel which created it.

3.6.6.1 obtain_typed_notification_push_consumer

Theobtain_typed_notification_push_consumeroperation is used to create a new Notification Service style proxy consumer instance, which will support a connection to the channel with which the targetTypedSupplierAdmininstance is associated by a push-style supplier of typed events. The operation accepts as input a string, which identifies the name of the strongly typed interface that the newly created

TypedProxyPushConsumerinstance should support. The supplier, which connects to the newTypedProxyPushConsumerwould use this strongly typed interface to invoke operations to send typed events to the channel.

If the targetTypedSupplierAdmininstance cannot locate an occurrence of the

TypedProxyPushConsumerinterface, which also supports the requested strongly typed interface, theInterfaceNotSupportedexception defined the

CosTypedEventChannelAdminmodule is raised. If the number of suppliers currently connected to the channel with which the targetTypedSupplierAdmin

object is associated exceeds the value of theMaxSuppliersadministrative property, theAdminLimitExceededexception is raised. Otherwise, the target

TypedSupplierAdmininstance creates a new instance supporting the

TypedProxyPushConsumerinterface defined in the

CosTypedNotifyChannelAdminmodule. This interface can subsequently be used for a push-style supplier of typed events to establish a connection to the Notification Service typed event channel. Upon creating the newTypedProxyPushConsumer

instance, the targetTypedSupplierAdmininstance associates with it a unique identifier, which it returns as an output parameter. This unique identifier could subsequently be used as the input parameter to theget_proxy_consumeroperation inherited by the targetTypedSupplierAdmininstance in order to obtain the reference to the newly createdTypedProxyPushConsumerinstance. This reference is returned as the result of theobtain_typed_notification_push_consumer

operation.

3.6.6.2 obtain_typed_notification_pull_consumer

Theobtain_typed_notification_pull_consumeroperation is used to create a new Notification Service style proxy consumer instance, which will support a connection to the channel with which the targetTypedSupplierAdmininstance is associated by a pull-style supplier of typed events. The operation accepts as input a string, which identifies the name of a strongly typed interface that the newly created

TypedProxyPullConsumerinstance should use when invoking operations upon its associatedTypedPullSupplierinstance to receive events.

If the targetTypedSupplierAdmininstance cannot locate an implementation of the

TypedProxyPullConsumerinterface, which will use the requested strongly typed interface to receive events from aTypedPullSupplier, the

NoSuchImplementation exception defined theCosTypedEventChannelAdmin

module is raised. If the number of suppliers currently connected to the channel with which the targetTypedSupplierAdminobject is associated exceeds the value of the

MaxSuppliersadministrative property, theAdminLimitExceededexception is raised. Otherwise, the targetTypedSupplierAdmininstance creates a new instance supporting theTypedProxyPullConsumerinterface defined in the

CosTypedNotifyChannelAdminmodule. This interface can subsequently be used for a pull-style supplier of typed events to establish a connection to the Notification Service typed event channel. Upon creating the newTypedProxyPullConsumer

instance, the targetTypedSupplierAdmininstance associates with it a unique identifier, which it returns as an output parameter. This unique identifier could subsequently be used as the input parameter to theget_proxy_consumeroperation inherited by the targetTypedSupplierAdmininstance in order to obtain the reference to the newly createdTypedProxyPullConsumerinstance. This reference is returned as the result of theobtain_typed_notification_pull_consumeroperation.

In document Notification Service Specification (Page 171-174)