# coding=utf-8 # # Copyright (C) 2010-2012 Platform Computing # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either # version 2.1 of the License, or (at your option) any later version. # # This library is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # Lesser General Public License for more details. # # You should have received a copy of the GNU Lesser General Public # License along with this library; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # The OCCI Infrastructure extension.
Created on Jul 20, 2011
@author: tmetsch '''
#============================================================================== # Compute #==============================================================================
'start', 'Start a compute resource')
'stop', 'Stop a compute resource', {'method': ''})
'restart', 'Restart a compute resource', {'method': ''})
'suspend', 'Suspend a compute resource', {'method': ''})
'occi.compute.cores': '', 'occi.compute.hostname': '', 'occi.compute.speed': '', 'occi.compute.memory': '', 'occi.compute.state': 'immutable'}
'compute', [Resource.kind], [START, STOP, RESTART, SUSPEND], 'Compute Resource', COMPUTE_ATTRIBUTES, '/compute/')
#============================================================================== # Network #==============================================================================
'up', 'Bring up a network resource')
'down', 'Bring down a network resource')
'occi.network.label': '', 'occi.network.state': 'immutable'}
'network', [Resource.kind], [UP, DOWN], 'Network Resource', NETWORK_ATTRIBUTES, '/network/')
#IP networking mixin
'occi.network.gateway': '', 'occi.network.allocation': ''}
'ipnetwork', attributes=IPNETWORK_ATTRIBUTES)
#============================================================================== # Storage #==============================================================================
'online', 'Bring storage online')
'offline', 'Bring storage offline')
'backup', 'Backup storage resource')
'snapshot', 'Make a snapshot of storage resource')
'resize', 'Resize storage resource', {'size': 'required'})
'occi.storage.state': 'immutable'}
'storage', [Resource.kind], [ONLINE, OFFLINE, BACKUP, SNAPSHOT, RESIZE], 'Storage Resource', STORAGE_ATTRIBUTES, '/storage/')
#============================================================================== # Linking #==============================================================================
'occi.networkinterface.mac': '', 'occi.networkinterface.state': 'immutable'}
'networkinterface', [Link.kind], [], 'A L2 Network Interface', NETWORKINTERFACE_ATTRIBUTES, '/network/interface/')
'occi.networkinterface.gateway': '', 'occi.networkinterface.allocation': ''}
'networkinterface#', 'ipnetworkinterface', [], [], 'L3/L4 capabilities for L2 Network Interface', IPNETWORKINTERFACE_ATTRIBUTES, '/network/interface/ip/')
'occi.storagelink.mountpoint': '', 'occi.storagelink.state': 'immutable'}
'storagelink', [Link.kind], [], 'A link to a storage resource', STORAGELINK_ATTRIBUTES, '/storage/link/')
#============================================================================== # Templates #==============================================================================
'resource_tpl')
|