Changes between Version 3 and Version 4 of AaronHelsinger/GAPI_AM_API_DRAFT/MethodSignatures


Ignore:
Timestamp:
04/11/12 13:57:44 (12 years ago)
Author:
Aaron Helsinger
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • AaronHelsinger/GAPI_AM_API_DRAFT/MethodSignatures

    v3 v4  
    2020GENI specifies that the AM API is provided via [http://www.xmlrpc.com/spec XML-RPC] over an SSL connection. Aggregate Managers shall require client side [wiki:GeniApiCertificates GENI certificates] to authenticate users, accepting only certificates that comply with the adopted [wiki:GeniApiCertificates GENI certificates] standards. The GENI AM API therefore assumes that users have already been authenticated, and that the aggregate manager has available the client certificate to identify the user.
    2121
    22 Clients are authorized to take actions at aggregates using [wiki:GeniApiCredentials GENI credentials]. To that end, all methods that require authorization take an argument {{{credentials}}}. In particular, operations on a single GENI slice will require a credential (set) that authorizes the client whose certificate was used to authenticate to operate on the slice named by a {{{slice_urn}}} argument to the method or on the slice containing the slivers named by a {{{urns}}} argument.
     22Clients are authorized to take actions at aggregates using [wiki:GeniApiCredentials GENI credentials]. To that end, all methods that require authorization take an argument {{{credentials}}}. In particular, operations on a single GENI slice will require a credential (set) that authorizes the client whose certificate was used to authenticate to operate on the slice named by a {{{urn}}} argument to the method or on the slice containing the slivers named by a {{{urns}}} argument.
    2323
    2424The primary data structure used within this API is a resource specification, known as an RSpec. These XML documents follow a specific set of schemas. They are used by aggregates to list and describe local resources (advertisement RSpecs), by experimenters to describe desired resources (request RSpecs), and then by aggregates to describe reserved resources (manifest RSpecs). For more information on RSpecs, see [wiki:GAPI_AM_API_V2_DETAILS#RSpecs the details page].
     
    2626=== Using the GENI AM API ===
    2727
    28 Clients (experimenters) use the AM API to discover resources (!ListResources), request resources (Allocate), provision reserved resources (Provision), start resources (!PerformOperationalAction), check the status of resources as they are started (!Status), extend their reservation (Renew), and then return the resources when done (Delete). Client tools may use !GetVersion to ensure aggregates speak a compatible version of the AM API and known formats for RSpecs. Administrators may call Shutdown to stop the resources of a slice at this aggregate, perhaps if that slice is misbehaving.
    29 
    30 !ListResources returns to the client an advertisement RSpec - a detailed listing of the resources available at that aggregate. From this information, the experimenter may determine which resources to reserve for their use. The RSpec should also have enough information to help the experimenter set the initial configuration for their resources.
    31 
    32 Once the experimenter has selected the resources they want and how to configure them, they produce a request RSpec, detailing the resources they want and how they should be configured. They separately contact their slice authority to obtain a slice credential, granting them rights to reserve resources for that slice. The experimenter then calls Allocate on this API, passing in both the slice credential and the request RSpec. The aggregate then attempts to satisfy the experimenter's resource request. If the aggregate can satisfy the request, the aggregate reserves the resources for the experimenter. The resources have not been provisioned yet, giving the experimenter a chance to verify the reservation. If it is acceptable, the experimenter calls Provision to set up the resources. The aggregate then starts the process of instantiating the resources and configuring them as requested in the request RSpec. Once that process has started, the !CreateSliver call returns with a manifest RSpec, listing the resources as reserved and initially configured for the experimenter. 
    33 
    34 The experimenter can then poll the aggregate manager to watch as the resources are configured and become ready for use, by calling Status. Once the resources are ready for use, the experimenter will call  !PerformOperationalAction(geni_start) to start the resources (e.g. boot a machine). The experimenter will also call Renew to request that their reservation lasts as long as they require the resources for. When the experimenter is done using the resources, they call Delete to end their reservation. The aggregate then stops and clears the resources, freeing them for use by other clients.
     28Clients (experimenters) use the AM API to discover resources (`!ListResources`), request resources (`Allocate`), provision reserved resources (`Provision`), start resources (`!PerformOperationalAction`), check the status of resources as they are started (`Status`), extend their reservation (`Renew`), and then return the resources when done (`Delete`). Client tools may use !`GetVersion` to ensure aggregates speak a compatible version of the AM API and known formats for RSpecs. Administrators may call `Shutdown` to stop the resources of a slice at this aggregate, perhaps if that slice is misbehaving.
     29
     30`!ListResources` returns to the client an advertisement RSpec - a detailed listing of the resources available at that aggregate. From this information, the experimenter may determine which resources to reserve for their use. The RSpec should also have enough information to help the experimenter set the initial configuration for their resources.
     31
     32Once the experimenter has selected the resources they want and how to configure them, they produce a request RSpec, detailing the resources they want and how they should be configured. They separately contact their slice authority to obtain a slice credential (or set of credentials), granting them rights to reserve resources for that slice. The experimenter then calls `Allocate` on this API, passing in both the slice credential and the request RSpec. The aggregate then attempts to satisfy the experimenter's resource request. If the aggregate can satisfy the request, the aggregate reserves the resources for the experimenter. The resources have not been provisioned yet, giving the experimenter a chance to verify the reservation, or check for corresponding resource availability in another aggregate. If it is acceptable, the experimenter calls `Provision` to set up the resources. The aggregate then starts the process of instantiating the resources and configuring them as requested in the request RSpec. Once that process has started, the `Provision` call returns with a manifest RSpec, listing the resources as reserved and initially configured for the experimenter. 
     33
     34The experimenter can then poll the aggregate manager to watch as the resources are configured and become ready for use, by calling `Status` (FIXME: allocation state is geni_provisioned immediately. Is Operational State not yet geni_notready?). Once the resources are ready for use, the experimenter will call  `!PerformOperationalAction(geni_start)` to start the resources (e.g. boot a machine). The experimenter will also call `Renew` to request that their reservation lasts as long as they require the resources for. When the experimenter is done using the resources, they call `Delete` to end their reservation. The aggregate then stops and clears the resources, freeing them for use by other clients.
    3535
    3636Client work flow:
     
    4444 5. {{{Provision(<slice URN or sliver URNs>, <slice credential>, <request RSpec>, <users struct>, {})}}}:
    4545  * Aggregate instantiates resources
    46  6. {{{Status(<slice URN or sliver URNs>, <slice credential>, <new time>, {})}}} to check that resources are provisioned
     46  * Return is a manifest RSpec describing the reserved resources, plus any instantiation-specific configuration information
     47 6. {{{Status(<slice URN or sliver URNs>, <slice credential>, {})}}} to check that resources are provisioned
    4748 7. {{{PerformOperationalAction(<slice URN>, <slice credential>, geni_start, {})}}}:
    4849  * Aggregate starts resources
    49  8. {{{Status(<slice URN or sliver URNs>, <slice credential>, <new time>, {})}}} to check that resources have started
    50  9. {{{Renew(<slice URN or sliver URNs>, <slice credential>, {})}}} to extend reservation
     50 8. {{{Status(<slice URN or sliver URNs>, <slice credential>, {})}}} to check that resources have started
     51 9. {{{Renew(<slice URN or sliver URNs>, <slice credential>, newtime, {})}}} to extend reservation
    5152 10. <Experimenter uses resources>
    5253 11. {{{Delete(<slice URN or sliver URNs>, <slice credential>, {})}}} when done
    5354
    5455=== Changes from AM API v2 ===
    55 '''FIXME: Highlight changes in usage, etc '''
     56This version of the AM API includes multiple changes since version 2 of the AM API. For experimenters, a few things are worth noting:
     57 - The old` !CreateSliver` operation has now been broken into 3 steps:
     58  - `Allocate` to reserve the resources
     59  - `Provision` to instantiate the resources, which may take time to complete
     60  - `PerformOperationalAction(geni_start)` to start (e.g. boot) the resources, which also may take time to complete
     61 - Use the intermediate `geni_allocated` state to coordinate reservations across aggregates, e.g. to ensure another aggregate can give you nodes to be the other end of a requested link
     62 - Multiple methods have been renamed, typically be removing the `Sliver` term from method names.
     63 - Sliver expiration is available in the return from multiple other methods, like `Provision`
     64 - You no longer use `!ListResources` to see the contents of your slice - use `Describe` instead. `!ListResources` is only for the AM's Ad RSpec.
     65 - SSH login names and keys should be available in manifest RSpecs in a standard format.
     66 - Slice name restrictions have been codified and standardized.
     67   - Slice names are <=19 characters, only alphanumeric plus hyphen (no hyphen in first character): `'^[a-zA-Z0-9][-a-zA-Z0-9]+$'`
     68
     69Tool developers should also be aware:
     70 - The `credentials` argument to methods is now a struct, including a type and version for each credential. AMs should advertise which credential types they accept. SAs should advertise which type they provide.
     71 - Aggregates may have their own operational states and actions. The Ad RSpec should define these, probably by `sliver_type`.
    5672
    5773-----