Providers are categorized according to the types of requests they service. Client programs communicate with the CIM Object Manager (and access WBEM data) through the client API (see file:/usr/sadm/lib/wbem/doc/index.html). The CIM Object Manager maps the provider methods to the corresponding client methods in the client API. However, the argument lists and return values of corresponding methods may differ:
If a provider stores data in the CIM Object Manager Repository, then it accesses the Repository using handles to the CIM Object Manager (see “Implementing the Provider Interfaces”), which call the methods of the client API.
If a provider needs to create instances or associations in the CIM Object Manager Repository, then it uses an internal provider (see “Implementing the Provider Interfaces”), which calls methods of Instance or Associator Providers that are internal to WBEM.
Make sure your argument list and return type is correct for the method and class used.
The Solaris WBEM SDK provider types are shown in the following table.
Table 4-1 Provider Types
Type |
Class Name |
Description |
---|---|---|
Instance |
CIMInstanceProvider |
Supply dynamic instances of a given class, and support instance retrieval, enumeration, modification, and deletion. |
Method |
MethodProvider |
Supply methods of one or more classes. |
Associator |
CIMAssociatorProvider |
Supply instances of dynamic association classes. |
Indication |
EventProvider |
Handle indications of CIM events. |
Authorizable |
None |
A marker interface that indicates to the CIM Object Manager that the provider does its own authorization check. |
A single provider can act as one or more of the above types by registering and implementing the relevant methods.
You can include providers in a single Java class file or store each provider in a separate class. The provider name identifies the Java class that serves as the provider for the class. Currently, the CIM Object Manager supports only providers written in the Java language.
Provider and class names must follow these rules:
The class name must be a valid CIM class, that is, that the name contains a prefix of characters, followed by an underscore, followed by more characters.
For example, green_apples and red_apples are valid CIM class names, whereas apples, apples_, and _apples are not.
The provider name specified in the MOF file must match the name of the provider class file.
For example, SimpleCIMInstanceProvider is the provider and Ex_SimpleCIMInstanceProvider is the class.
You must prepend “java:” to every provider qualifier to notify the CIM Object Manager that the provider is written in the Java language.
Follow standard Java class and package naming conventions to create your provider names. The prefix of a package name is written in lowercase ASCII letters and must be one of the top-level domain names (com, edu, gov, mil, net, org), or one of the English two-letter country codes specified in ISO Standards 3166, 1981.
Subsequent components of the package name will vary according to your organization's internal naming conventions. Such conventions might specify that certain directory name components are division, department, project, machine, or login names. For example, the provider name java:com.sun.wbem.cimom indicates the following:
java: – Language used to write the provider
com – Top-level domain name
sun – Company name
wbem – Product name
cimom – Type of class files that implement the CIM Object Manager