(file) Return to IndicationService.h CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / IndicationService

   1 karl  1.79 //%2006////////////////////////////////////////////////////////////////////////
   2 kumpf 1.1  //
   3 karl  1.63 // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
   4            // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
   5            // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
   6 karl  1.47 // IBM Corp.; EMC Corporation, The Open Group.
   7 karl  1.63 // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
   8            // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
   9 karl  1.65 // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
  10            // EMC Corporation; VERITAS Software Corporation; The Open Group.
  11 karl  1.79 // Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.;
  12            // EMC Corporation; Symantec Corporation; The Open Group.
  13 kumpf 1.1  //
  14            // Permission is hereby granted, free of charge, to any person obtaining a copy
  15            // of this software and associated documentation files (the "Software"), to
  16            // deal in the Software without restriction, including without limitation the
  17            // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
  18            // sell copies of the Software, and to permit persons to whom the Software is
  19            // furnished to do so, subject to the following conditions:
  20 kumpf 1.27 // 
  21 kumpf 1.1  // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
  22            // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
  23            // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
  24            // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
  25            // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
  26            // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
  27            // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
  28            // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  29            //
  30            //==============================================================================
  31            //
  32            // Author: Nitin Upasani, Hewlett-Packard Company (Nitin_Upasani@hp.com)
  33            //
  34            // Modified By:  Carol Ann Krug Graves, Hewlett-Packard Company
  35 kumpf 1.39 //                   (carolann_graves@hp.com)
  36            //               Ben Heilbronn, Hewlett-Packard Company (ben_heilbronn@hp.com)
  37            //               Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com)
  38 yi.zhou 1.75 //               Yi Zhou, Hewlett-Packard Company (yi.zhou@hp.com)
  39 kumpf   1.1  //
  40              //%/////////////////////////////////////////////////////////////////////////////
  41              
  42              #ifndef Pegasus_IndicationService_h
  43              #define Pegasus_IndicationService_h
  44              
  45              #include <Pegasus/Common/Config.h>
  46              #include <Pegasus/Common/MessageQueueService.h>
  47              #include <Pegasus/Common/CIMMessage.h>
  48 kumpf   1.78 #include <Pegasus/Common/AcceptLanguageList.h>
  49              #include <Pegasus/Common/ContentLanguageList.h>
  50 kumpf   1.82 // NOCHKSRC
  51 kumpf   1.6  #include <Pegasus/Server/ProviderRegistrationManager/ProviderRegistrationManager.h>
  52 kumpf   1.82 // DOCHKSRC
  53 kumpf   1.54 #include <Pegasus/Server/Linkage.h>
  54 chuck   1.64 #include <Pegasus/Query/QueryExpression/QueryExpression.h>
  55 kumpf   1.1  
  56 kumpf   1.41 #include "ProviderClassList.h"
  57              #include "IndicationOperationAggregate.h"
  58              
  59 kumpf   1.1  PEGASUS_NAMESPACE_BEGIN
  60              
  61 kumpf   1.54 class SubscriptionRepository;
  62              class SubscriptionTable;
  63 kumpf   1.1  
  64              /**
  65 kumpf   1.5      IndicationService class is the service that serves the
  66 kumpf   1.10     Indication Subscription, Indication Filter, and Indication Handler
  67 kumpf   1.5      classes, and processes indications.
  68 kumpf   1.1   */
  69              
  70              class PEGASUS_SERVER_LINKAGE IndicationService : public MessageQueueService
  71              {
  72              public:
  73              
  74                  /**
  75                      Constructs an IndicationSubscription instance and initializes instance
  76                      variables.
  77                   */
  78 kumpf   1.82     IndicationService(
  79                      CIMRepository* repository,
  80                      ProviderRegistrationManager* providerRegManager);
  81 kumpf   1.1  
  82 kumpf   1.82     virtual ~IndicationService();
  83 kumpf   1.1  
  84 mday    1.2      void handleEnqueue(Message* message);
  85 kumpf   1.1  
  86 kumpf   1.82     virtual void handleEnqueue();
  87 kumpf   1.1  
  88 kumpf   1.82     virtual void _handle_async_request(AsyncRequest* req);
  89 kumpf   1.1  
  90 kumpf   1.54     /**
  91                      Gets a String containing the Provider Name, for use in a log message to
  92                      identify the provider.
  93              
  94                      @param   provider              provider instance
  95              
  96                      @return  String containing the Provider Name
  97                   */
  98 kumpf   1.82     static String getProviderLogString(CIMInstance& provider);
  99 kumpf   1.54 
 100 kumpf   1.1      AtomicInt dienow;
 101              
 102                  /**
 103 kumpf   1.5          Operation types for the NotifyProviderRegistration message
 104 kumpf   1.1       */
 105 kumpf   1.5      enum Operation {OP_CREATE = 1, OP_DELETE = 2, OP_MODIFY = 3};
 106 kumpf   1.24 
 107                  static Mutex _mutex;
 108 kumpf   1.1  
 109 kumpf   1.5  private:
 110 kumpf   1.1  
 111 kumpf   1.82     void _initialize();
 112 kumpf   1.1  
 113 kumpf   1.82     void _terminate();
 114 kumpf   1.1  
 115 kumpf   1.82     void _handleGetInstanceRequest(const Message* message);
 116 kumpf   1.1  
 117 kumpf   1.82     void _handleEnumerateInstancesRequest(const Message* message);
 118 kumpf   1.1  
 119 kumpf   1.82     void _handleEnumerateInstanceNamesRequest(const Message* message);
 120 kumpf   1.1  
 121 kumpf   1.82     void _handleCreateInstanceRequest(const Message* message);
 122 kumpf   1.1  
 123 kumpf   1.82     void _handleModifyInstanceRequest(const Message* message);
 124 kumpf   1.1  
 125                  void _handleDeleteInstanceRequest(const Message * message);
 126              
 127 kumpf   1.82     void _handleProcessIndicationRequest(const Message* message);
 128 kumpf   1.1  
 129                  /**
 130 kumpf   1.57         Asynchronous callback function for _handleProcessIndicationRequest.
 131                      The response from the Handler is checked, and if it is not success, the
 132 carolann.graves 1.74         subscription's On Fatal Error Policy is implemented.
 133 kumpf           1.57 
 134                              @param  operation            shared data structure that controls message
 135                                                               processing
 136                              @param  destination          target queue of completion callback
 137                              @param  userParameter        user parameter for callback processing
 138                           */
 139 kumpf           1.82     static void _handleIndicationCallBack(
 140                              AsyncOpNode* operation,
 141                              MessageQueue* destination,
 142                              void* userParameter);
 143 kumpf           1.57 
 144                          /**
 145 kumpf           1.82         Notifies the Indication Service that a change in provider registration
 146                              has occurred.  The Indication Service retrieves the subscriptions
 147                              affected by the registration change, sends the appropriate Create,
 148 carolann.graves 1.74         Modify, and/or Delete requests to the provider, and sends an alert to
 149                              handler instances of subscriptions that are no longer served by the
 150 kumpf           1.10         provider.
 151 kumpf           1.1      */
 152 kumpf           1.82     void _handleNotifyProviderRegistrationRequest(const Message* message);
 153 kumpf           1.1  
 154                          /**
 155 carolann.graves 1.74         Notifies the Indication Service that a provider has been disabled.
 156 kumpf           1.51         The Indication Service retrieves the subscriptions served by the
 157 carolann.graves 1.74         disabled provider, and logs a message for each subscription that is no
 158 kumpf           1.51         longer served by the provider.
 159 kumpf           1.1       */
 160 kumpf           1.82     void _handleNotifyProviderTerminationRequest(const Message* message);
 161 kumpf           1.1  
 162                          /**
 163 carolann.graves 1.74         Notifies the Indication Service that a provider has been enabled.
 164                              The Indication Service retrieves the subscriptions that can be served
 165                              by the enabled provider, sends Create Subscription and Enable
 166                              Indications requests to the provider, and logs a message for each
 167 kumpf           1.51         subscription that is now served by the provider.
 168                           */
 169 kumpf           1.82     void _handleNotifyProviderEnableRequest(const Message* message);
 170 kumpf           1.51 
 171                          /**
 172 carolann.graves 1.80         Notifies the Indication Service that failure of a provider module that
 173                              included at least one indication provider has been detected.
 174                              The Indication Service retrieves the subscriptions served by providers
 175                              in the failed module.  The Indication Service returns in the response
 176                              the number of affected subscriptions, so the sender of the request
 177                              knows if any subscriptions were affected.
 178                           */
 179 kumpf           1.82     void _handleNotifyProviderFailRequest(Message* message);
 180 carolann.graves 1.80 
 181                          /**
 182 carolann.graves 1.74         Determines if it is legal to create an instance.
 183                              Checks for existence of all key and required properties.  Checks that
 184                              properties that MUST NOT exist (based on values of other properties),
 185                              do not exist.  For any property that has a default value, if it does
 186 kumpf           1.5          not exist, adds the property with the default value.
 187                      
 188                              @param   instance              instance to be created
 189                              @param   nameSpace             namespace for instance to be created
 190                      
 191 carolann.graves 1.73         @exception   CIM_ERR_INVALID_PARAMETER  if instance is invalid
 192 carolann.graves 1.74         @exception   CIM_ERR_NOT_SUPPORTED      if the specified class is not
 193 carolann.graves 1.73                                                 supported
 194 kumpf           1.5  
 195 kumpf           1.54         @return  True, if the instance can be created;
 196 kumpf           1.10                  Otherwise throws an exception
 197 kumpf           1.5       */
 198 kumpf           1.82     Boolean _canCreate(
 199                              CIMInstance& instance,
 200                              const CIMNamespaceName& nameSpace);
 201 kumpf           1.5  
 202 kumpf           1.21     /**
 203                              Validates the specified required property in the instance.
 204 carolann.graves 1.74         If the property does not exist, or has a null value, or is not of the
 205 kumpf           1.56         expected type, an exception is thrown, using the specified message.
 206 kumpf           1.21 
 207 carolann.graves 1.74         This function is called by the _canCreate function, and is used to
 208 kumpf           1.21         validate the  Filter and Handler properties in Subscription instances,
 209 carolann.graves 1.74         the Name, Query and Query Language properties in
 210                              Filter instances, the Name and Destination
 211                              properties in CIMXML Handler instances, and the Name,
 212 kumpf           1.21         Trap Destination, and SNMP Version properties in SNMP Mapper instances.
 213                      
 214                              @param   instance              instance to be validated
 215                              @param   propertyName          name of property to be validated
 216 kumpf           1.56         @param   expectedType          expected CIMType of property value
 217 kumpf           1.21         @param   message               message to be used in exception
 218 kumpf           1.82         @param   isArray               indicates whether the validated
 219                                                             property is array
 220 kumpf           1.21 
 221 carolann.graves 1.73         @exception   CIM_ERR_INVALID_PARAMETER  if required property is missing
 222                                                                      or null
 223 kumpf           1.21      */
 224 kumpf           1.82     void _checkRequiredProperty(
 225                              CIMInstance& instance,
 226                              const CIMName& propertyName,
 227 kumpf           1.56         const CIMType expectedType,
 228 kumpf           1.82         const String& message,
 229                              const Boolean isArray = false);
 230 kumpf           1.20 
 231 kumpf           1.5      /**
 232 carolann.graves 1.74         Validates the specified Uint16 (non-array) property and its
 233 carolann.graves 1.69         corresponding String (non-array) Other___ property in the instance.
 234 kumpf           1.15         If the property does not exist, it is added with the default value.
 235                              If the property exists, but its value is NULL, its value is set to
 236                              the default value.
 237                              If the value of the property is Other, but the corresponding Other___
 238 kumpf           1.56         property either does not exist, has a value of NULL, or is not of the
 239 carolann.graves 1.74         correct type, an exception is thrown.
 240 kumpf           1.15         If the value of the property is not Other, but the corresponding
 241                              Other___ property exists and has a non-NULL value, an exception is
 242                              thrown.
 243 carolann.graves 1.74         If the value of the property is not a supported value, an exception is
 244 kumpf           1.56         thrown.
 245 carolann.graves 1.74         This function is called by the _canCreate function, and is used to
 246                              validate the following pairs of properties in Subscription or Handler
 247                              instances: Subscription State, Other Subscription State, Repeat
 248                              Notification Policy, Other Repeat Notification Policy, On Fatal Error
 249                              Policy, Other On Fatal Error Policy, Persistence Type, Other
 250 kumpf           1.15         Persistence Type.
 251                      
 252                              @param   instance              instance to be validated
 253                              @param   propertyName          name of property to be validated
 254                              @param   otherPropertyName     name of Other___ property to be validated
 255                              @param   defaultValue          default value for property
 256                              @param   otherValue            "Other" value for property
 257 kumpf           1.19         @param   validValues           set of valid values for property
 258 kumpf           1.55         @param   supportedValues       set of supported values for property
 259 kumpf           1.15 
 260 carolann.graves 1.73         @exception   CIM_ERR_INVALID_PARAMETER  if value of property or Other___
 261                                                                      property is invalid
 262 kumpf           1.15      */
 263 kumpf           1.82     void _checkPropertyWithOther(
 264                              CIMInstance& instance,
 265                              const CIMName& propertyName,
 266                              const CIMName& otherPropertyName,
 267 kumpf           1.15         const Uint16 defaultValue,
 268 kumpf           1.19         const Uint16 otherValue,
 269 kumpf           1.82         const Array<Uint16>& validValues,
 270                              const Array<Uint16>& supportedValues);
 271 kumpf           1.20 
 272 kumpf           1.21     /**
 273                              Validates the specified property in the instance.
 274                              If the property does not exist, it is added with the default value.
 275                              If the property exists, but its value is NULL, its value is set to
 276                              the default value.
 277 carolann.graves 1.74         This function is called by the _canCreate function, and is used to
 278 carolann.graves 1.62         validate the Source Namespace property in Filter instances.
 279 carolann.graves 1.74         This function is also called by the _initOrValidateStringProperty
 280                              function to validate the CreationClassName, SystemName, and
 281 carolann.graves 1.69         SystemCreationClassName key properties in Filter and Handler instances.
 282 kumpf           1.21 
 283 kumpf           1.56         Note: currently all properties validated by this function are of type
 284 carolann.graves 1.74         String.  To use this function in the future with properties of other
 285                              types, a type parameter would need to be added, and the default value
 286 kumpf           1.56         would need to be passed as a CIMValue instead of a String.
 287                      
 288 carolann.graves 1.69         Note: currently all properties validated by this function are non-array
 289                              properties.  To use this function in the future with both array and
 290 carolann.graves 1.74         non-array properties, a Boolean isArray parameter would need to be
 291 carolann.graves 1.69         added.
 292                      
 293 kumpf           1.21         @param   instance              instance to be validated
 294                              @param   propertyName          name of property to be validated
 295                              @param   defaultValue          default value for property
 296                      
 297                              @return  the value of the property
 298                           */
 299 kumpf           1.82     String _checkPropertyWithDefault(
 300                              CIMInstance& instance,
 301                              const CIMName& propertyName,
 302                              const String& defaultValue);
 303 kumpf           1.56 
 304                          /**
 305                              Validates the specified property in the instance.
 306 carolann.graves 1.62         If the property does not exist, it is added with the default value.
 307                              If the property exists, but its value is NULL, its value is set to
 308                              the default value.
 309 carolann.graves 1.74         If the property exists and has a non-NULL value, its value is validated
 310                              against the default (expected) value.  If the value is invalid, an
 311 carolann.graves 1.62         exception is thrown.
 312 carolann.graves 1.74         This function is called by the _canCreate function, and is used to
 313 carolann.graves 1.62         validate the Creation Class Name, System Name and System Creation Class
 314                              Name properties in Filter and Handler instances.
 315                      
 316                              Note: currently all properties validated by this function are of type
 317 carolann.graves 1.74         String.  To use this function in the future with properties of other
 318                              types, a type parameter would need to be added, and the default value
 319 carolann.graves 1.62         would need to be passed as a CIMValue instead of a String.
 320                      
 321 carolann.graves 1.69         Note: currently all properties validated by this function are non-array
 322                              properties.  To use this function in the future with both array and
 323 carolann.graves 1.74         non-array properties, a Boolean isArray parameter would need to be
 324 carolann.graves 1.69         added.
 325                      
 326 carolann.graves 1.62         @param   instance              instance to be validated
 327                              @param   propertyName          name of property to be validated
 328                              @param   defaultValue          default value for property
 329                      
 330                              @return  the value of the property
 331                           */
 332 kumpf           1.82     String _initOrValidateStringProperty(
 333                              CIMInstance& instance,
 334                              const CIMName& propertyName,
 335                              const String& defaultValue);
 336 carolann.graves 1.62 
 337                          /**
 338                              Validates the specified property in the instance.
 339 kumpf           1.56         If the property exists and its value is not NULL, but it is not of
 340                              the correct type, an exception is thrown.
 341 carolann.graves 1.74         This function is called by the _canCreate function.  It is used to
 342                              validate the FailureTriggerTimeInterval, TimeOfLastStateChange,
 343 kumpf           1.56         SubscriptionDuration, SubscriptionStartTime, SubscriptionTimeRemaining,
 344                              RepeatNotificationInterval, RepeatNotificationGap, and
 345                              RepeatNotificationCount properties in Subscription instances, the Owner
 346 carolann.graves 1.74         property in Handler instances, and the PortNumber, SNMPSecurityName,
 347 kumpf           1.56         and SNMPEngineID properties in SNMP Mapper Handler instances.
 348                      
 349 carolann.graves 1.69         Note: currently all properties validated by this function are non-array
 350                              properties.  To use this function in the future with both array and
 351 carolann.graves 1.74         non-array properties, a Boolean isArray parameter would need to be
 352 carolann.graves 1.69         added.
 353                      
 354 kumpf           1.56         @param   instance              instance to be validated
 355                              @param   propertyName          name of property to be validated
 356                              @param   expectedType          expected CIMType for property
 357 yi.zhou         1.75         @param   isArray               indicates whether the validated
 358                                                             property is array
 359 kumpf           1.56 
 360 carolann.graves 1.73         @exception   CIM_ERR_INVALID_PARAMETER  if property exists and is not
 361                                                                      null but is not of the correct
 362                                                                      type
 363 kumpf           1.56      */
 364 kumpf           1.82     void _checkProperty(
 365                              CIMInstance& instance,
 366                              const CIMName& propertyName,
 367 yi.zhou         1.75         const CIMType expectedType,
 368                              const Boolean isArray = false);
 369 kumpf           1.15 
 370                          /**
 371 carolann.graves 1.76         Validates that all properties in the instance are supported properties,
 372                              and throws an exception if an unknown, unsupported property is found.
 373                      
 374                              @param   instance              instance to be validated
 375                      
 376                              @exception   CIM_ERR_NOT_SUPPORTED      if instance includes an unknown,
 377                                                                      unsupported property
 378                           */
 379 kumpf           1.82     void _checkSupportedProperties(
 380                              const CIMInstance& instance);
 381 carolann.graves 1.76 
 382                          /**
 383 kumpf           1.82         Validates value of the specified Uint16 property in the instance.
 384                              If the value of the property is not a valid value, or is not a
 385 yi.zhou         1.77         supported value, an exception is thrown.
 386                      
 387                              @param   instance              instance to be validated
 388                              @param   propertyName          name of property to be validated
 389                              @param   validValues           set of valid values for property
 390                              @param   supportedValues       set of supported values for property
 391 kumpf           1.82 
 392                              @exception   CIM_ERR_NOT_SUPPORTED      if the property value is not
 393 yi.zhou         1.77                                                 supported
 394 kumpf           1.82                      CIM_ERR_INVALID_PARAMETER  if the property value is not
 395 yi.zhou         1.77                                                 valid
 396                           */
 397 kumpf           1.82     void _checkValue(
 398                              const CIMInstance& instance,
 399                              const CIMName& propertyName,
 400                              const Array<Uint16>& validValues,
 401                              const Array<Uint16>& supportedValues);
 402 yi.zhou         1.77 
 403                          /**
 404 kumpf           1.10         Determines if the user is authorized to modify the instance, and if the
 405 carolann.graves 1.74         specified modification is supported.  Currently, the only modification
 406                              supported is of the Subscription State property of the Subscription
 407 kumpf           1.10         class.
 408 kumpf           1.5  
 409                              @param   request               modification request
 410                              @param   instance              instance to be modified
 411 kumpf           1.37         @param   modifiedInstance      modified instance
 412 kumpf           1.5  
 413 carolann.graves 1.73         @exception   CIM_ERR_NOT_SUPPORTED      if the specified modification is
 414                                                                      not supported
 415                              @exception   CIM_ERR_ACCESS_DENIED      if the user is not authorized to
 416                                                                      modify the instance
 417                              @exception   CIM_ERR_INVALID_PARAMETER  if the modifiedInstance is
 418                                                                      invalid
 419 kumpf           1.5  
 420 kumpf           1.54         @return  True, if the instance can be modified;
 421 kumpf           1.10                  Otherwise throws an exception
 422 kumpf           1.5       */
 423 kumpf           1.82     Boolean _canModify(
 424                              const CIMModifyInstanceRequestMessage* request,
 425                              const CIMObjectPath& instanceReference,
 426                              const CIMInstance& instance,
 427                              CIMInstance& modifiedInstance);
 428 kumpf           1.5  
 429                          /**
 430 carolann.graves 1.74         Determines if the user is authorized to delete the instance, and if it
 431                              is legal to delete the instance.  If authorized, Subscription instances
 432                              may always be deleted.  Filter and non-transient Handler instances may
 433                              only be deleted if they are not being referenced by any Subscription
 434                              instances. If the instance to be deleted is a transient Handler, any
 435 kumpf           1.10         referencing Subscriptions are also deleted.
 436 kumpf           1.5  
 437                              @param   instanceReference     reference for instance to be deleted
 438                              @param   nameSpace             namespace for instance to be deleted
 439 kumpf           1.10         @param   currentUser           current user
 440                      
 441 carolann.graves 1.73         @exception   CIM_ERR_ACCESS_DENIED      if the user is not authorized to
 442                                                                      delete the instance
 443                              @exception   CIM_ERR_FAILED             if the instance to be deleted is
 444                                                                      referenced by a subscription
 445 kumpf           1.5  
 446 kumpf           1.54         @return  True, if the instance can be deleted;
 447 kumpf           1.10                  Otherwise throws an exception
 448 kumpf           1.1       */
 449 kumpf           1.82     Boolean _canDelete(
 450                              const CIMObjectPath& instanceReference,
 451                              const CIMNamespaceName& nameSpace,
 452                              const String& currentUser);
 453 kumpf           1.1  
 454                          /**
 455                              Retrieves list of enabled subscription instances in all namespaces,
 456                              where the subscription indication class matches or is a superclass
 457 kumpf           1.10         of the supported class, and the properties required to process the
 458                              subscription are all contained in the list of supported properties.
 459 carolann.graves 1.74         If the checkProvider parameter value is True, a subscription is only
 460                              included in the list returned if the specified provider accepted the
 461                              subscription.  If the checkProvider parameter value is False, the
 462 kumpf           1.42         provider parameter is not used (ignored).
 463 kumpf           1.1  
 464 kumpf           1.10         @param   supportedClass       the supported class
 465                              @param   nameSpaces           the list of supported namespaces
 466                              @param   supportedProperties  the list of supported properties
 467 kumpf           1.42         @param   checkProvider        indicates whether provider acceptance is
 468                                                                checked
 469                              @param   provider             the provider (used if checkProvider True)
 470 kumpf           1.1  
 471 kumpf           1.26         @return   list of CIMInstance subscriptions
 472 kumpf           1.1       */
 473 kumpf           1.82     Array<CIMInstance> _getMatchingSubscriptions(
 474                              const CIMName& supportedClass,
 475                              const Array<CIMNamespaceName> nameSpaces,
 476                              const CIMPropertyList& supportedProperties,
 477 kumpf           1.43         const Boolean checkProvider = false,
 478 kumpf           1.82         const CIMInstance& provider = CIMInstance());
 479 kumpf           1.1  
 480                          /**
 481                              Retrieves lists of enabled subscription instances in all namespaces
 482                              that are either newly supported or previously supported, based on the
 483 kumpf           1.9          supported class, the supported namespaces before and after modification,
 484 carolann.graves 1.74         and the supported properties before and after modification.  For
 485                              subscriptions based on the supported class, the newSubscriptions list
 486                              returned contains the subscriptions for which the properties required
 487                              to process the subscription are all contained in the new list of
 488                              supported properties, but are not all contained in the old list of
 489 kumpf           1.9          supported properties, and/or the filter source namespace is contained in
 490 carolann.graves 1.74         the new list if supported namespaces, but is not contained in the old
 491                              list of supported namespaces.  The formerSubscriptions list returned
 492 kumpf           1.9          contains the subscriptions for which the properties required to process
 493 carolann.graves 1.74         the subscription are not all contained in the new list of supported
 494                              properties, but are all contained in the old list of supported
 495                              properties, and/or the filter source namespace is not contained in the
 496                              new list if supported namespaces, but is contained in the old list of
 497 kumpf           1.9          supported namespaces.
 498                      
 499 kumpf           1.10         @param   supportedClass       the supported class
 500 kumpf           1.9          @param   newNameSpaces        namespaces supported after modification
 501                              @param   oldNameSpaces        namespaces supported before modification
 502                              @param   newProperties        properties supported after modification
 503                              @param   oldProperties        properties supported before modification
 504 kumpf           1.1          @param   newSubscriptions     the list of newly supported subscriptions
 505                              @param   formerSubscriptions  the list of previously supported
 506                                                                subscriptions
 507                           */
 508 kumpf           1.82     void _getModifiedSubscriptions(
 509                              const CIMName& supportedClass,
 510                              const Array<CIMNamespaceName>& newNameSpaces,
 511                              const Array<CIMNamespaceName>& oldNameSpaces,
 512                              const CIMPropertyList& newProperties,
 513                              const CIMPropertyList& oldProperties,
 514                              Array<CIMInstance>& newSubscriptions,
 515                              Array<CIMInstance>& formerSubscriptions);
 516 kumpf           1.1  
 517                          /**
 518 kumpf           1.9          Determines if all of the required properties in the specified list
 519                              are contained in the specified list of supported properties.
 520                      
 521                              @param   requiredProperties  the required properties
 522 kumpf           1.10         @param   supportedProperties the supported properties
 523 kumpf           1.9  
 524 kumpf           1.54         @return   true, if all required properties are supported;
 525 kumpf           1.9                    false otherwise
 526                           */
 527 kumpf           1.82     Boolean _inPropertyList(
 528                              const CIMPropertyList& requiredProperties,
 529                              const CIMPropertyList& supportedProperties);
 530 kumpf           1.9  
 531                          /**
 532 chuck           1.64         Builds a QueryExpression from the filter query string,
 533                              the query language name, and the namespace in which the query
 534                              is to be run.
 535 kumpf           1.1  
 536                              @param   filterQuery           the filter query string
 537 chuck           1.64         @param   queryLanguage         the query language name
 538                              @param   ns                    query namespace
 539 kumpf           1.1  
 540 chuck           1.64         @return  QueryExpression representing the filter query
 541 kumpf           1.1       */
 542 kumpf           1.82     QueryExpression _getQueryExpression(
 543                              const String& filterQuery,
 544                              const String& queryLanguage,
 545                              const CIMNamespaceName& ns) const;
 546 kumpf           1.1  
 547                          /**
 548 chuck           1.64         Extracts the indication class name from the specified query expression
 549                              (WQL or CQL), and validates that the name represents a subclass of the
 550 kumpf           1.1          Indication class.
 551                      
 552 chuck           1.64         @param   queryExpression       the query expression
 553 kumpf           1.1          @param   nameSpaceName         the namespace
 554                      
 555                              @return  String containing the indication class name
 556                           */
 557 kumpf           1.82     CIMName _getIndicationClassName(
 558                              const QueryExpression& queryExpression,
 559                              const CIMNamespaceName& nameSpaceName) const;
 560 kumpf           1.15 
 561                          /**
 562 kumpf           1.1          Retrieves the list of indication providers that serve the specified
 563                              indication subclasses.
 564                      
 565 chuck           1.64         @param   queryExpression       the query expression
 566                              @param   nameSpace             the namespace name
 567 kumpf           1.1          @param   indicationClassName   the indication class name
 568                              @param   indicationSubclasses  the list of indication subclass names
 569                      
 570                              @return  list of ProviderClassList structs
 571                           */
 572 kumpf           1.82     Array<ProviderClassList> _getIndicationProviders(
 573                              const QueryExpression& queryExpression,
 574                              const CIMNamespaceName& nameSpace,
 575                              const CIMName& indicationClassName,
 576                              const Array<CIMName>& indicationSubclasses) const;
 577 kumpf           1.1  
 578                          /**
 579 carolann.graves 1.74         Retrieves the list of required properties (all the properties
 580                              referenced in the WHERE clause) for the specified filter query
 581 carolann.graves 1.72         expression.
 582 kumpf           1.1  
 583 chuck           1.64         @param   queryExpression       the query expression
 584 kumpf           1.22         @param   nameSpaceName         the namespace
 585 chuck           1.64         @param   indicationClassName   the indication class name
 586 kumpf           1.1  
 587 carolann.graves 1.74         @return  CIMPropertyList of required properties for the filter query
 588 chuck           1.64                  expression
 589 kumpf           1.1       */
 590 kumpf           1.82     CIMPropertyList _getPropertyList(
 591                              const QueryExpression& queryExpression,
 592                              const CIMNamespaceName& nameSpaceName,
 593                              const CIMName& indicationClassName) const;
 594 kumpf           1.22 
 595                          /**
 596 carolann.graves 1.74         Checks if the property list includes all properties in the specified
 597 kumpf           1.22         class.  If so, a NULL CIMPropertyList is returned.  Otherwise, a
 598 carolann.graves 1.74         CIMPropertyList containing the properties is returned.  The list of
 599                              property names in the specified indication class is also returned in
 600                              the indicationClassProperties parameter.
 601 carolann.graves 1.60 
 602                              @param   propertyList                the list of property names
 603                              @param   nameSpaceName               the namespace
 604                              @param   indicationClassName         the indication class name
 605                              @param   indicationClassProperties   the list of property names in the
 606                                                                     specified indication class
 607 kumpf           1.22 
 608 carolann.graves 1.74         @return  CIMPropertyList of properties referenced by the filter query
 609 kumpf           1.22                  select statement
 610                           */
 611 kumpf           1.82     CIMPropertyList _checkPropertyList(
 612                              const Array<CIMName>& propertyList,
 613                              const CIMNamespaceName& nameSpaceName,
 614                              const CIMName& indicationClassName,
 615                              Array<CIMName>& indicationClassProperties) const;
 616 kumpf           1.1  
 617                          /**
 618                              Extracts the condition (WHERE Clause) from the specified filter query
 619                              string.
 620                      
 621                              @param   filterQuery       the filter query
 622                      
 623                              @return  String containing the filter query condition
 624                           */
 625 kumpf           1.82     String _getCondition(
 626                              const String& filterQuery) const;
 627 kumpf           1.1  
 628                          /**
 629 carolann.graves 1.74         Deletes subscriptions referencing the specified handler.  All namespaces
 630                              are searched for subscriptions that reference the handler to be deleted.
 631 kumpf           1.4  
 632 carolann.graves 1.74         @param   nameSpace             the name space of the handler being
 633                                                                 deleted
 634 kumpf           1.4          @param   referenceProperty     the name of the reference property in the
 635                                                                 subscription instance
 636                              @param   handler               the handler reference
 637                           */
 638 kumpf           1.82     void _deleteReferencingSubscriptions(
 639                              const CIMNamespaceName& nameSpace,
 640                              const CIMName& referenceProperty,
 641                              const CIMObjectPath& handler);
 642 kumpf           1.4  
 643                          /**
 644                              Determines if specified Subscription has expired
 645                      
 646                              NOTE: It is assumed that the instance passed to this function is a
 647                              Subscription instance, and that the Subscription Duration and
 648                              Start Time properties exist
 649                      
 650                              @param   instance              the subscription instance
 651                      
 652 kumpf           1.54         @return  True, if the Subscription has expired;
 653 kumpf           1.4                   False otherwise
 654                           */
 655 kumpf           1.82     Boolean _isExpired(
 656                              const CIMInstance& instance) const;
 657 kumpf           1.4  
 658                          /**
 659 carolann.graves 1.74         Deletes specified subscription
 660 kumpf           1.5  
 661                              @param   subscription          the subscription reference
 662                           */
 663 kumpf           1.82     void _deleteExpiredSubscription(
 664                              CIMObjectPath& subscription);
 665 kumpf           1.21 
 666                          /**
 667                              Gets the Subscription Time Remaining property
 668                      
 669 carolann.graves 1.74         Calculates time remaining from Subscription Start Time, Subscription
 670 kumpf           1.21         Duration, and current date time.  If the subscription has a non-null
 671 carolann.graves 1.74         Duration, the Time Remaining is set, and True is returned.  If the
 672                              subscription does not have a non-null Duration, it has no expiration
 673                              date, and the time remaining is unlimited.  In this case, the Time
 674 kumpf           1.21         Remaining is not set and False is returned.
 675 carolann.graves 1.74 
 676 kumpf           1.21         NOTE: It is assumed that the instance passed to this function is a
 677 carolann.graves 1.74         Subscription instance, and that the Start Time property exists and
 678 kumpf           1.21         has a value
 679                      
 680                              @param   instance              Input the subscription instance
 681                              @param   timeRemaining         Output the time remaining (seconds)
 682                      
 683 kumpf           1.54         @return  True, if the subscription has a non-null Duration;
 684 kumpf           1.21                  False otherwise
 685                           */
 686 kumpf           1.82     Boolean _getTimeRemaining(
 687                              const CIMInstance& instance,
 688                              Uint64& timeRemaining) const;
 689 kumpf           1.5  
 690                          /**
 691 kumpf           1.4          Sets the Subscription Time Remaining property
 692                      
 693 carolann.graves 1.74         Calculates time remaining from Subscription Start Time, Subscription
 694 kumpf           1.4          Duration, and current date time
 695 carolann.graves 1.74 
 696 kumpf           1.4          NOTE: It is assumed that the instance passed to this function is a
 697                              Subscription instance, and that the Subscription Duration and
 698                              Start Time properties exist
 699                      
 700                              @param   instance              the subscription instance
 701                           */
 702 kumpf           1.82     void _setTimeRemaining(CIMInstance& instance);
 703 kumpf           1.4  
 704                          /**
 705 kumpf           1.23         Gets the parameter values required to Create or Modify the subscription
 706 kumpf           1.10         request.
 707 carolann.graves 1.74         If no indication providers are found, condition and queryLanguage are
 708 kumpf           1.3          set to empty string.
 709                      
 710 kumpf           1.33         @param   subscriptionInstance  Input subscription instance
 711 carolann.graves 1.74         @param   indicationSubclasses  Output list of subclasses of indication
 712 kumpf           1.33                                            class in filter query
 713 kumpf           1.3          @param   indicationProviders   Output list of providers with associated
 714                                                                 classes
 715                              @param   propertyList          Output list of properties required by the
 716                                                                 subscription
 717 kumpf           1.17         @param   sourceNameSpace       Output source namespace for filter query
 718 kumpf           1.3          @param   condition             Output condition part of the filter query
 719 kumpf           1.58         @param   query                 Output filter query
 720 kumpf           1.3          @param   queryLanguage         Output query language in which the filter
 721                                                                 query is expressed
 722                           */
 723 kumpf           1.82     void _getCreateParams(
 724                              const CIMInstance& subscriptionInstance,
 725                              Array<CIMName>& indicationSubclasses,
 726                              Array<ProviderClassList>& indicationProviders,
 727                              CIMPropertyList& propertyList,
 728                              CIMNamespaceName& sourceNameSpace,
 729                              String& condition,
 730                              String& query,
 731                              String& queryLanguage);
 732 kumpf           1.10 
 733                          /**
 734 kumpf           1.23         Gets the parameter values required to Create or Modify the subscription
 735 kumpf           1.10         request.
 736                      
 737 kumpf           1.33         @param   subscriptionInstance  Input subscription instance
 738 carolann.graves 1.74         @param   indicationSubclasses  Output list of subclasses of indication
 739 kumpf           1.33                                            class in filter query
 740 kumpf           1.10         @param   propertyList          Output list of properties required by the
 741                                                                 subscription
 742 kumpf           1.17         @param   sourceNameSpace       Output source namespace for filter query
 743 kumpf           1.10         @param   condition             Output condition part of the filter query
 744 kumpf           1.58         @param   query                 Output filter query
 745 kumpf           1.10         @param   queryLanguage         Output query language in which the filter
 746                                                                 query is expressed
 747                           */
 748 kumpf           1.82     void _getCreateParams(
 749                              const CIMInstance& subscriptionInstance,
 750                              Array<CIMName>& indicationSubclasses,
 751                              CIMPropertyList& propertyList,
 752                              CIMNamespaceName& sourceNameSpace,
 753                              String& condition,
 754                              String& query,
 755                              String& queryLanguage);
 756 kumpf           1.3  
 757                          /**
 758 kumpf           1.23         Gets the parameter values required to Delete the subscription request.
 759 kumpf           1.5  
 760 kumpf           1.33         @param   subscriptionInstance  Input subscription instance
 761 carolann.graves 1.74         @param   indicationSubclasses  Output list of subclasses of indication
 762 kumpf           1.33                                            class in filter query
 763                              @param   sourceNameSpace       Output source namespace for filter query
 764 kumpf           1.5  
 765 kumpf           1.23         @return  List of providers with associated classes to Delete
 766 kumpf           1.5       */
 767 kumpf           1.82     Array<ProviderClassList> _getDeleteParams(
 768                              const CIMInstance& subscriptionInstance,
 769                              Array<CIMName>& indicationSubclasses,
 770                              CIMNamespaceName& sourceNameSpace);
 771 mday            1.13 
 772 kumpf           1.5      /**
 773 kumpf           1.23         Sends Create subscription request for the specified subscription
 774 carolann.graves 1.68         to each provider in the list.  The requests are sent using SendAsync,
 775 carolann.graves 1.74         and the responses are aggregated in the callback methods.  Create
 776                              Subscription requests are sent to the indication providers using
 777                              SendAsync in the following cases: (1) on creation of an enabled
 778                              subscription instance, and (2) on modification of a subscription
 779                              instance, when the state changes to enabled.  In cases (1) and (2),
 780                              there is an original Create Instance or Modify Instance request to
 781 carolann.graves 1.71         which the Indication Service must respond.
 782 kumpf           1.1  
 783                              @param   indicationProviders   list of providers with associated classes
 784 kumpf           1.54         @param   nameSpace             the nameSpace name of the resource being
 785 carolann.graves 1.74                                            monitored, from the SourceNamespace
 786                                                                 property of the CIM_IndicationFilter
 787                                                                 instance for the specified
 788 kumpf           1.54                                            subscription
 789 kumpf           1.1          @param   propertyList          the properties referenced by the
 790                                                                 subscription
 791                              @param   condition             the condition part of the filter query
 792 kumpf           1.58         @param   query                 the filter query
 793 kumpf           1.1          @param   queryLanguage         the query language in which the filter
 794                                                                 query is expressed
 795 kumpf           1.23         @param   subscription          the subscription to be created
 796 chuck           1.35         @param   acceptLangs           the language of the response, and
 797                                                                 future indications
 798                              @param   contentLangs          the language of the subscription
 799 carolann.graves 1.71         @param   origRequest           the original request (Create
 800 carolann.graves 1.68                                            Instance, Modify Instance)
 801 carolann.graves 1.74         @param   indicationSubclasses  the indication subclasses for the
 802 kumpf           1.41                                            subscription
 803 kumpf           1.9          @param   userName              the userName for authentication
 804                              @param   authType              the authentication type
 805                      
 806 kumpf           1.1       */
 807 kumpf           1.82     void _sendAsyncCreateRequests(
 808                              const Array<ProviderClassList>& indicationProviders,
 809                              const CIMNamespaceName& nameSpace,
 810                              const CIMPropertyList& propertyList,
 811                              const String& condition,
 812                              const String& query,
 813                              const String& queryLanguage,
 814                              const CIMInstance& subscription,
 815                              const AcceptLanguageList& acceptLangs,
 816                              const ContentLanguageList& contentLangs,
 817 kumpf           1.41         const CIMRequestMessage * origRequest,
 818 kumpf           1.82         const Array<CIMName>& indicationSubclasses,
 819                              const String& userName,
 820                              const String& authType = String::EMPTY);
 821 mday            1.13 
 822 kumpf           1.1      /**
 823 carolann.graves 1.68         Sends Create subscription request for the specified subscription
 824                              to each provider in the list.  The requests are sent using SendWait,
 825                              so no callback methods are required.  Create Subscription requests are
 826                              sent to the indication providers using SendWait in the following cases:
 827 carolann.graves 1.74         (1) on notification of a provider registration change newly enabling
 828                              the provider to serve the subscription, (2) on notification that a
 829                              provider has been enabled and may now serve the subscription, and
 830 carolann.graves 1.71         (3) on initialization, for each enabled subscription retrieved from the
 831                              repository.  In cases (1) and (2), there is an original Notify Provider
 832 carolann.graves 1.74         Registration or Notify Provider Enable request to which the Indication
 833 carolann.graves 1.71         Service must respond.  In case (3), there is no original request and no
 834                              response is required.
 835 carolann.graves 1.68 
 836                              @param   indicationProviders   list of providers with associated classes
 837                              @param   nameSpace             the nameSpace name of the resource being
 838                                                                 monitored, from the SourceNamespace
 839                                                                 property of the CIM_IndicationFilter
 840                                                                 instance for the specified
 841                                                                 subscription
 842                              @param   propertyList          the properties referenced by the
 843                                                                 subscription
 844                              @param   condition             the condition part of the filter query
 845                              @param   query                 the filter query
 846                              @param   queryLanguage         the query language in which the filter
 847                                                                 query is expressed
 848                              @param   subscription          the subscription to be created
 849                              @param   acceptLangs           the language of the response, and
 850                                                                 future indications
 851                              @param   contentLangs          the language of the subscription
 852                              @param   userName              the userName for authentication
 853                              @param   authType              the authentication type
 854                      
 855 carolann.graves 1.71         @return  List of providers that accepted subscription
 856 carolann.graves 1.68      */
 857 kumpf           1.82     Array<ProviderClassList> _sendWaitCreateRequests(
 858                              const Array<ProviderClassList>& indicationProviders,
 859                              const CIMNamespaceName& nameSpace,
 860                              const CIMPropertyList& propertyList,
 861                              const String& condition,
 862                              const String& query,
 863                              const String& queryLanguage,
 864                              const CIMInstance& subscription,
 865                              const AcceptLanguageList& acceptLangs,
 866                              const ContentLanguageList& contentLangs,
 867                              const String& userName,
 868                              const String& authType = String::EMPTY);
 869 carolann.graves 1.68 
 870                          /**
 871 kumpf           1.23         Sends Modify subscription request for the specified subscription
 872 carolann.graves 1.68         to each provider in the list.   The requests are sent using SendWait,
 873                              so no callback methods are required.  Modify Subscription requests must
 874 carolann.graves 1.74         be sent to the indication providers on notification of a provider
 875                              registration change, when the provider was formerly serving the
 876                              subscription, and is still serving the subscription, in the following
 877                              cases: (1) the provider is newly serving an additional indication
 878 carolann.graves 1.68         subclass specified by the subscription, or (2) the provider is
 879 carolann.graves 1.74         no longer serving an indication subclass specified by the subscription
 880 kumpf           1.41         (but is still serving at least one of the indication subclasses).
 881 carolann.graves 1.68         In cases (1) and (2), there is an original Notify Provider Registration
 882                              request to which the Indication Service must respond.
 883 kumpf           1.1  
 884                              @param   indicationProviders   list of providers with associated classes
 885 kumpf           1.54         @param   nameSpace             the nameSpace name of the resource being
 886                                                                 monitored, from the SourceNamespace
 887                                                                 property of the CIM_IndicationFilter
 888 carolann.graves 1.74                                            instance for the specified
 889                                                                 subscription
 890 kumpf           1.1          @param   propertyList          the properties referenced by the
 891                                                                 subscription
 892                              @param   condition             the condition part of the filter query
 893 kumpf           1.58         @param   query                 the filter query
 894 kumpf           1.1          @param   queryLanguage         the query language in which the filter
 895                                                                 query is expressed
 896                              @param   subscription          the subscription to be modified
 897 chuck           1.35         @param   acceptLangs           the language of the response, and
 898                                                                 future indications
 899 carolann.graves 1.74         @param   contentLangs          the language of the subscription
 900 kumpf           1.9          @param   userName              the userName for authentication
 901                              @param   authType              the authentication type
 902 kumpf           1.1       */
 903 kumpf           1.82     void _sendWaitModifyRequests(
 904                              const Array<ProviderClassList>& indicationProviders,
 905                              const CIMNamespaceName& nameSpace,
 906                              const CIMPropertyList& propertyList,
 907                              const String& condition,
 908                              const String& query,
 909                              const String& queryLanguage,
 910                              const CIMInstance& subscription,
 911                              const AcceptLanguageList& acceptLangs,
 912                              const ContentLanguageList& contentLangs,
 913                              const String& userName,
 914                              const String& authType = String::EMPTY);
 915 kumpf           1.1  
 916                          /**
 917 kumpf           1.23         Sends Delete subscription request for the specified subscription
 918 carolann.graves 1.68         to each provider in the list.  The requests are sent using SendAsync,
 919 carolann.graves 1.74         and the responses are aggregated in the callback methods.  Delete
 920                              Subscription requests are sent to the indication providers using
 921                              SendAsync in the following cases: (1) on deletion of an enabled
 922                              subscription instance, (2) on modification of a subscription instance,
 923                              when the state changes to disabled, (3) on deletion of an expired
 924                              subscription, and (4) on deletion of a subscription referencing a
 925                              deleted transient handler.  In cases (1) and (2), there is an original
 926                              Delete Instance or Modify Instance request to which the Indication
 927 carolann.graves 1.68         Service must respond.  In cases (3) and (4), there is no orginal request
 928                              and no response is required.
 929 kumpf           1.1  
 930                              @param   indicationProviders   list of providers with associated classes
 931 carolann.graves 1.74         @param   nameSpace             the nameSpace name of the resource being
 932 kumpf           1.54                                            monitored, from the SourceNamespace
 933                                                                 property of the CIM_IndicationFilter
 934 carolann.graves 1.74                                            instance for the specified
 935                                                                 subscription
 936 kumpf           1.1          @param   subscription          the subscription to be modified
 937 chuck           1.35         @param   acceptLangs           the language of the response
 938 carolann.graves 1.74         @param   contentLangs          the language of the subscription
 939                              @param   origRequest           the original request (Delete Instance,
 940 carolann.graves 1.68                                            Modify Instance)
 941 carolann.graves 1.74         @param   indicationSubclasses  the indication subclasses for the
 942 kumpf           1.41                                            subscription
 943 kumpf           1.9          @param   userName              the userName for authentication
 944                              @param   authType              the authentication type
 945 kumpf           1.1       */
 946 kumpf           1.82     void _sendAsyncDeleteRequests(
 947                              const Array<ProviderClassList>& indicationProviders,
 948                              const CIMNamespaceName& nameSpace,
 949                              const CIMInstance& subscription,
 950                              const AcceptLanguageList& acceptLangs,
 951                              const ContentLanguageList& contentLangs,
 952 kumpf           1.41         const CIMRequestMessage * origRequest,
 953 kumpf           1.82         const Array<CIMName>& indicationSubclasses,
 954                              const String& userName,
 955                              const String& authType = String::EMPTY);
 956 kumpf           1.1  
 957                          /**
 958 carolann.graves 1.68         Sends Delete subscription request for the specified subscription
 959                              to each provider in the list.  The requests are sent using SendWait,
 960                              so no callback methods are required.  Delete Subscription requests are
 961 carolann.graves 1.74         sent to the indication providers using SendWait in the following case:
 962                              (1) on notification of a provider registration change newly preventing
 963                              the provider from serving the subscription.  In case (1), there is an
 964                              original Notify Provider Registration request to which the Indication
 965                              Service must respond.
 966 carolann.graves 1.68 
 967                              @param   indicationProviders   list of providers with associated classes
 968                              @param   nameSpace             the nameSpace name of the resource being
 969                                                                 monitored, from the SourceNamespace
 970                                                                 property of the CIM_IndicationFilter
 971                                                                 instance for the specified
 972                                                                 subscription
 973                              @param   subscription          the subscription to be modified
 974                              @param   acceptLangs           the language of the response
 975                              @param   contentLangs          the language of the subscription
 976                              @param   userName              the userName for authentication
 977                              @param   authType              the authentication type
 978                           */
 979 kumpf           1.82     void _sendWaitDeleteRequests(
 980                              const Array<ProviderClassList>& indicationProviders,
 981                              const CIMNamespaceName& nameSpace,
 982                              const CIMInstance& subscription,
 983                              const AcceptLanguageList& acceptLangs,
 984                              const ContentLanguageList& contentLangs,
 985                              const String& userName,
 986                              const String& authType = String::EMPTY);
 987 carolann.graves 1.68 
 988                          /**
 989 kumpf           1.41         Collects responses from providers for aggregation as they are received,
 990 carolann.graves 1.74         and stores them in the IndicationOperationAggregate instance.  Calls
 991                              _handleOperationResponseAggregation to process the responses, once all
 992 kumpf           1.41         expected responses have been received.
 993                      
 994 kumpf           1.57         @param  operation            shared data structure that controls message
 995 kumpf           1.41                                          processing
 996                              @param  destination          target queue of completion callback
 997                              @param  userParameter        user parameter for callback processing
 998                           */
 999 kumpf           1.82     static void _aggregationCallBack(
1000 kumpf           1.41         AsyncOpNode * operation,
1001                              MessageQueue * destination,
1002                              void * userParameter);
1003                      
1004                          /**
1005 carolann.graves 1.74         Calls the appropriate function to processes responses from providers,
1006 kumpf           1.41         based on the type of request sent to providers, once all responses have
1007 carolann.graves 1.74         been received.
1008 kumpf           1.41 
1009 carolann.graves 1.74         @param   operationAggregate    the operation aggregate instance
1010 kumpf           1.41      */
1011 kumpf           1.82     void _handleOperationResponseAggregation(
1012 kumpf           1.41         IndicationOperationAggregate * operationAggregate);
1013                      
1014                          /**
1015 carolann.graves 1.74         Processes create subscription responses from providers, once all have
1016                              been received.  Takes the appropriate action, based on the type of the
1017                              original request, if any, and the responses received.  Sends the
1018 kumpf           1.41         response to the original request, if required.
1019                      
1020 carolann.graves 1.74         @param   operationAggregate    the operation aggregate instance
1021 kumpf           1.41      */
1022 kumpf           1.82     void _handleCreateResponseAggregation(
1023 kumpf           1.41         IndicationOperationAggregate * operationAggregate);
1024                      
1025                          /**
1026 carolann.graves 1.74         Processes modify subscription responses from providers, once all have
1027 kumpf           1.41         been received.  Updates the subscription hash tables.
1028                      
1029 carolann.graves 1.74         @param   operationAggregate    the operation aggregate instance
1030 kumpf           1.41      */
1031 kumpf           1.82     void _handleModifyResponseAggregation(
1032 kumpf           1.41         IndicationOperationAggregate * operationAggregate);
1033                      
1034                          /**
1035 carolann.graves 1.74         Processes delete subscription responses from providers, once all have
1036                              been received.  Updates the subscription hash tables appropriately,
1037                              based on the type of the original request, if any.  Sends the response
1038 kumpf           1.41         to the original request, if required.
1039                      
1040 carolann.graves 1.74         @param   operationAggregate    the operation aggregate instance
1041 kumpf           1.41      */
1042 kumpf           1.82     void _handleDeleteResponseAggregation(
1043 kumpf           1.41         IndicationOperationAggregate * operationAggregate);
1044                      
1045                          /**
1046 kumpf           1.1          Creates an alert instance of the specified class.
1047                      
1048                              @param   alertClassName        the alert class name
1049 kumpf           1.7          @param   subscriptions         subscriptions for which alert is to be
1050 kumpf           1.1                                             created
1051                      
1052                              @return  the created alert instance
1053                           */
1054 kumpf           1.82     CIMInstance _createAlertInstance(
1055                              const CIMName& alertClassName,
1056                              const Array<CIMInstance>& subscriptions);
1057 mday            1.14 
1058 kumpf           1.40 #if 0
1059 kumpf           1.82     /**
1060                              Asynchronous completion routine for _sendAlerts
1061                           */
1062                      
1063                          static void _sendAlertsCallBack(
1064                              AsyncOpNode* operation,
1065                              MessageQueue* callback_destination,
1066                              void* parameter);
1067 kumpf           1.1  
1068                          /**
1069                              Sends specified alert to each unique handler instance for the
1070                              specified subscriptions in the list.
1071                      
1072 kumpf           1.7          @param   subscriptions         subscriptions for which alert is to be
1073 kumpf           1.1                                             sent
1074                              @param   alertInstance         the alert to be sent
1075                           */
1076 kumpf           1.82     void _sendAlerts(
1077                              const Array<CIMInstance>& subscriptions,
1078                              /* const */ CIMInstance& alertInstance);
1079 kumpf           1.40 #endif
1080 carolann.graves 1.74 
1081 kumpf           1.16     /**
1082 carolann.graves 1.74         Sends a Subscription Init Complete request to the Provider
1083 carolann.graves 1.67         Manager Service.
1084                           */
1085 kumpf           1.82     void _sendSubscriptionInitComplete();
1086 kumpf           1.16 
1087 kumpf           1.37     /**
1088                              Gets the value of the Creator property from the specified Subscription
1089 carolann.graves 1.74         instance.  If this function returns False, the value of the creator
1090 kumpf           1.37         parameter is unchanged.
1091                      
1092                              @param   instance              subscription instance
1093                              @param   creator               value of Creator property if retrieved
1094                      
1095 kumpf           1.54         @return  True, if the value of the Creator property was retrieved;
1096 kumpf           1.37                  False if Creator property was missing, null, or of an
1097 kumpf           1.54                        incorrect type
1098 kumpf           1.37      */
1099 kumpf           1.82     Boolean _getCreator(
1100                              const CIMInstance& instance,
1101                              String& creator) const;
1102 kumpf           1.37 
1103                          /**
1104 kumpf           1.54         Validates the specified SubscriptionState property value.
1105 kumpf           1.37 
1106 kumpf           1.54         @param   state                 SubscriptionState property value
1107 kumpf           1.37 
1108 kumpf           1.54         @return  True, if the SubscriptionState property value is valid;
1109                                       False otherwise
1110 kumpf           1.37      */
1111 kumpf           1.82     Boolean _validateState(
1112 kumpf           1.54         const Uint16 state) const;
1113 kumpf           1.37 
1114 kumpf           1.46     /**
1115                              This function peforms an authorization test based on the
1116                              value of the enableSubscriptionForNonprivilegedUsers.
1117                      
1118                              @param   userName                String
1119                      
1120 carolann.graves 1.74         @return  True, if authentication is not enabled or the
1121 kumpf           1.54                        user is a privileged system user;
1122                                       False, if authentication is enabled and the
1123                                             user is not privileged
1124 kumpf           1.46      */
1125 kumpf           1.82     void _checkNonprivilegedAuthorization(
1126                              const String& userName);
1127 kumpf           1.46 
1128 kumpf           1.48     /**
1129 kumpf           1.49         Updates the propertyList, in preparation for calling the Repository.
1130 carolann.graves 1.74         If the propertyList is not null, the Creator property must be added to
1131                              the list.  Also, if the request is for the Subscription class, the
1132                              value of the Time Remaining property need only be calculated if it is
1133                              requested.  In that case, the Subscription Duration and Start Time
1134                              properties must be added to the list if not already there.
1135 kumpf           1.49 
1136                              @param   className             class name for the request
1137                              @param   propertyList          list of properties requested
1138                              @param   setTimeRemaining      indicates whether Time Remaining property
1139                                                             was requested
1140                              @param   startTimeAdded        indicates whether Start Time property was
1141                                                             added to the list
1142                              @param   durationAdded         indicates whether Duration property was
1143                                                             added to the list
1144                           */
1145 kumpf           1.82     void _updatePropertyList(
1146                              CIMName& className,
1147                              CIMPropertyList& propertyList,
1148                              Boolean& setTimeRemaining,
1149                              Boolean& startTimeAdded,
1150                              Boolean& durationAdded);
1151 kumpf           1.49 
1152                          /**
1153 carolann.graves 1.74         Gets a String containing the comma-separated Subscription Filter Name
1154 kumpf           1.48         and Handler Name, for use in a log message to identify the subscription.
1155                      
1156                              @param   subscription          subscription instance
1157                      
1158                              @return  String containing the comma-separated Subscription Filter Name
1159                                       and Handler Name
1160                           */
1161 kumpf           1.82     String _getSubscriptionLogString(CIMInstance& subscription);
1162 kumpf           1.48 
1163 kumpf           1.54     SubscriptionRepository* _subscriptionRepository;
1164 kumpf           1.51 
1165 kumpf           1.54     SubscriptionTable * _subscriptionTable;
1166 kumpf           1.6  
1167 kumpf           1.8      /**
1168                              Handle to Provider Registration Manager
1169                           */
1170                          ProviderRegistrationManager * _providerRegManager;
1171 kumpf           1.5  
1172 carolann.graves 1.74     /**
1173 chuck           1.64         Pointer to CIMRepository, for use in building QueryExpression.
1174                           */
1175                          CIMRepository* _cimRepository;
1176                      
1177 kumpf           1.5      /**
1178                              Integer representing queue ID for accessing Provider Manager Service
1179                           */
1180                          Uint32 _providerManager;
1181                      
1182                          /**
1183                              Integer representing queue ID for accessing Handler Manager Service
1184                           */
1185                          Uint32 _handlerService;
1186                      
1187                          /**
1188 kumpf           1.46         Boolean indicating that the CIM Server has been configured to
1189                              allow non-privileged users read and write access to the
1190                              Subscription classes.
1191                           */
1192                          Boolean _enableSubscriptionsForNonprivilegedUsers;
1193                      
1194 kumpf           1.55     /**
1195 carolann.graves 1.80         Boolean indicating whether authentication is currently enabled in the
1196                              CIM Server.
1197                           */
1198                          Boolean _authenticationEnabled;
1199                      
1200                          /**
1201 kumpf           1.82         Gets the indication class specified by the subscription filter query.
1202 yi.zhou         1.66 
1203 kumpf           1.82         @param instance     the subscription instance
1204 yi.zhou         1.66 
1205 kumpf           1.82         @return CIMClass object for the indication class
1206 yi.zhou         1.66     */
1207 kumpf           1.82     CIMClass _getIndicationClass(const CIMInstance& instance);
1208 yi.zhou         1.66 
1209                          /**
1210 kumpf           1.55         Arrays of valid and supported property values
1211                      
1212 carolann.graves 1.74         Notes:
1213 kumpf           1.55         Valid values are defined by the CIM Event Schema MOF
1214                              Supported values are a subset of the valid values
1215                              Some valid values, as defined in the MOF, are not currently supported
1216                                  by the Pegasus IndicationService
1217                      
1218 carolann.graves 1.74         Supported Values
1219 kumpf           1.55         SubscriptionState: Enabled, Disabled
1220                              RepeatNotificationPolicy: Unknown, Other, None, Suppress, Delay
1221                              OnFatalErrorPolicy: Ignore, Disable, Remove
1222                              PersistenceType: Permanent, Transient
1223 yi.zhou         1.77         SNMPVersion: SNMPv1 Trap, SNMPv2C Trap
1224 kumpf           1.55      */
1225 kumpf           1.82     Array<Uint16> _validStates;
1226                          Array<Uint16> _validRepeatPolicies;
1227                          Array<Uint16> _validErrorPolicies;
1228                          Array<Uint16> _validPersistenceTypes;
1229                          Array<Uint16> _validSNMPVersion;
1230                          Array<Uint16> _supportedStates;
1231                          Array<Uint16> _supportedRepeatPolicies;
1232                          Array<Uint16> _supportedErrorPolicies;
1233                          Array<Uint16> _supportedPersistenceTypes;
1234                          Array<Uint16> _supportedSNMPVersion;
1235 yi.zhou         1.66 
1236 carolann.graves 1.76     /**
1237                              Arrays of names of supported properties for each class
1238                           */
1239 kumpf           1.82     Array<CIMName> _supportedSubscriptionProperties;
1240                          Array<CIMName> _supportedFormattedSubscriptionProperties;
1241                          Array<CIMName> _supportedFilterProperties;
1242                          Array<CIMName> _supportedCIMXMLHandlerProperties;
1243                          Array<CIMName> _supportedCIMXMLListenerDestinationProperties;
1244                          Array<CIMName> _supportedSNMPHandlerProperties;
1245                          Array<CIMName> _supportedSyslogListenerDestinationProperties;
1246                          Array<CIMName> _supportedEmailListenerDestinationProperties;
1247 kumpf           1.1  };
1248                      
1249                      PEGASUS_NAMESPACE_END
1250                      
1251 kumpf           1.41 #endif  /* Pegasus_IndicationService_h */

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2