deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Koper, Dies" <>
Subject design question about cimi system's subcollection implementations
Date Tue, 26 Feb 2013 10:46:38 GMT
I'm looking at what the best way would be to design a cimi system's subcollections (SystemMachine
and SystemVolume in particular), and their mapping to the drivers.

Retrieval of a system (or collection of systems), gives a response that includes e.g. its

  <machines href="" />

Listing the system's machines, should return a collection of SystemMachines, with references
to the actual machines.

<Collection xmlns="" resourceURI="">
    <name>Mock Instance With Profile Change</name>
    <description>SystemMachine inst0 for System system1</description>
    <machine href="http://localhost:3001/cimi/machines/inst0" />
   <operation rel="delete" href="http://localhost:3001/cimi/systems/system1/machines/inst0"

I'm considering several ways to implement this:
1. From system_machine#self.find, passing the system_id to the existing driver.instances method
to list only the instances of that system, then convert the instances into a SystemMachineCollection.
This would be the most efficient way for fgcp.

2. Introduce a driver.system_machines method and leave it up to the driver how to retrieve
the instances. A disadvantage is that each supporting driver relying on instances() would
have to do the instance->machine conversion themselves.

3. Introduce a driver.system_instances method and leave it up to the driver how to retrieve
the instances belonging to this system. The instance->machine conversion would be done
in system_machine#self.find as in 1. A disadvantage of this is the mixture of cimi and DC

I prefer 1. Possibly by adding a "system" feature for the drivers that support this in their
instances (and storage_volumes, keys?) methods, so that we can use the DB for drivers that

What do you think?

Dies Koper

Software & Solutions Architect

Fujitsu Australia Software Technology (FAST) - Cloud Computing
Tel. +61 2 9452 9061 (Fujitsu internal 7985-29061)

View raw message