CLI


Gao Kai
 

Hi all,

Yesterday I was asked to give a brief description about my understanding of the design and here is the response.

A deployment scenario through the command line:

When feature alto-service is installed:

karaf $ alto:service <service-name> <operation> [<parameters>]
service-name = { ird-pool | networkmap-pool | costmap-pool | endpointmap-pool }
operation = service-operation

service-operation = { start | stop | autostart { true | false } | status }

instance-pool-operation = {
      list
    | create <id> <description-file>
    | destroy <id>
    | start <id>
    | stop <id>
    | autostart <id> { true | false }
    | status <id> [<version-tag>]
    | update <id> <new-description-file>
    | configure <id> <property> [<parameters>] }

When no parameters are given to configure the command will return the value of
the property.

ird-registry-operation = {
      register <resource-id> { remote <ird-registry-uri> | local <ird-id> }
    | unregister <resource-id> { remote <ird-registry-uri> | local <ird-id> }}

When ird-pool service is activated:

karaf $ alto:ird <operation> [<parameters>]
operation = instance-pool-operation | ird-registry-operation

When networkmap-pool service is activated:

karaf $ alto:networkmap <operation> [<parameters>]
operation = instance-pool-operation | ird-registry-operation

When costmap-pool service is activated:

karaf $ alto:costmap <operation> [<parameters>]
operation = instance-pool-operation | ird-registry-operation

When endpointmap-pool service is activated:

karaf $ alto:endpointmap <operation> [<parameters>]
operation = instance-pool-operation | ird-registry-operation

Here are some examples for the description files:
A static networkmap description file example:

{
    name : "static-map-1",
    generator : {
        class : "static-file-generator",
        file : "/opt/alto/configuration/networkmap/static-map-04542ead1343.map"
    }
}

A host tracker costmap description file example:

{
    name : "hosttrack-map-singleton",
    generator : {
        class : "hosttracker-generator",
        dependency: [
            "static-map-1",
        ]
    },
    autostart : true,
    registry : [
        "remote:http://someoneelse.com/ird/registry",
        "local:root-ird",
    ]
}

The yang-models for ird-pool service and data are described in the attached files (still not complete though).

Yours,

K

‚Äč

Join z.archive.alto-dev@lists.opendaylight.org to automatically receive all group messages.