blob: 345474d44c813d0b1cb223e65321793327ac0e03 [file] [log] [blame]
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Compute resources</title>
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<!-- Le JavaScript -->
<script src="/assets/js/jquery-1.7.1.min.js" type="text/javascript"></script>
<script src="/assets/js/bootstrap-dropdown.js" type="text/javascript"></script>
<script src="/assets/js/jquery.tweet.js" type="text/javascript"></script>
<script src="/assets/js/application.js" type="text/javascript"></script>
<script src="/assets/js/bootstrap-transition.js"></script>
<script src="/assets/js/bootstrap-alert.js"></script>
<script src="/assets/js/bootstrap-modal.js"></script>
<script src="/assets/js/bootstrap-scrollspy.js"></script>
<script src="/assets/js/bootstrap-tab.js"></script>
<script src="/assets/js/bootstrap-tooltip.js"></script>
<script src="/assets/js/bootstrap-popover.js"></script>
<script src="/assets/js/bootstrap-button.js"></script>
<script src="/assets/js/bootstrap-collapse.js"></script>
<script src="/assets/js/bootstrap-carousel.js"></script>
<script src="/assets/js/bootstrap-typeahead.js"></script>
<!-- Le styles -->
<link href="/assets/css/bootstrap.css" rel="stylesheet">
<link href="/assets/css/application.css" rel="stylesheet">
<link rel="shortcut icon" href="/assets/img/favicon.ico">
</head>
<body><div style="background: red"><h1>2015/07/20 - Apache Deltacloud has been retired. </h1><h2>For more information, please explore the <a href="http://attic.apache.org/">Attic</a>. </h2></div>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="brand" href="/"><img src="/assets/img/logo.png" width="152"
alt="Deltacloud API"/></a>
<ul class="nav top-nav">
<li><a href="/">Home</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">About<b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/about.html">What is Deltacloud?</a></li>
<li><a href="/drivers.html#drivers">Supported Providers</a></li>
</ul>
</li>
<li><a href="/download.html">Download</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Installation<b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/install-deltacloud.html">Install Deltacloud</a></li>
<li><a href="/run-deltacloud-server.html">Run the Deltacloud Server</a></li>
</ul>
</li>
<li class="dropdown">
<a href="/usage.html" class="dropdown-toggle" data-toggle="dropdown">Usage<b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/usage.html#usingapi">Using API</a></li>
<li><a href="/usage.html#clients">Client Libraries</a></li>
<li><a href="/command-tools.html">Command Line Tools</a></li>
</ul>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Contribute<b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/getting-sources.html">Getting Sources</a></li>
<li><a href="/how-to-contribute.html">How Can I Contribute?</a></li>
</ul>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">API<b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/rest-api.html">Deltacloud REST API</a></li>
<li><a href="/curl-examples.html">Deltacloud API cURL examples</a></li>
<li><a href="/drivers.html">Drivers API</a></li>
</ul>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">CIMI<b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="/cimi-rest.html">CIMI REST API</a></li>
<li><a href="/cimi-curl.html">CIMI cURL Examples</a></li>
</ul>
</li>
<li><a href="/contact.html">Contact</a></li>
</ul>
</div>
</div>
</div>
<div class="container content">
<p><br></p>
<div class="row">
<div class="span9">
<h3 id="compute">Compute Resources</h3>
<p>
The compute resources are: instances, instance states, images, realms, hardware profiles, firewalls, load balancers, addresses and keys.
</p>
<h3 id="realms">Realms</h3>
<p>
A realm represents a boundary containing resources, such as a data center. The exact definition of a realm is given by the cloud provider. In some cases, a realm may represent different datacenters, different continents or different pools of resources within a single datacenter. A cloud provider may insist that all the resources exist within a single realm in order to cooperate. For instance, storage volumes may only be allowed to be mounted to instances within the same realm. Generally speaking, going from one realm to another within the same cloud may change many aspects of the cloud, such as SLA’s, pricing terms, etc.
</p>
<h4>Get a list of all realms</h4>
<p>
To list all realms use call <strong>GET /api/realms</strong>. You can filter the list by adding a request parameter <strong>architecture</strong> to the realms that support a specific architecture, such as <strong>i386</strong>. The example below shows the retrieval of all realms for the AWS EC2 driver, which correspond to EC2 "availability zones":
</p>
</div>
<div class="span3">
<ul class="nav nav-list well">
<li class="nav-header">
REST API
</li>
<li><a href="rest-api.html">Introduction</a></li>
<li><a href="api-entry-point.html">API entry point</a></li>
<li class="active"><a href="compute-resources.html">Compute resources</a></li>
<ul class="nav nav-list">
<li><a href="#realms">Realms</a></li>
<li><a href="hardware-profiles.html">Hardware profiles</a></li>
<li><a href="images.html">Images</a></li>
<li><a href="instance-states.html">Instance states</a></li>
<li><a href="instances.html">Instances</a></li>
<li><a href="keys.html">Keys</a></li>
<li><a href="firewalls.html">Firewalls</a></li>
<li><a href="addresses.html">Addresses</a></li>
<li><a href="load-balancers.html">Load balancers</a></li>
</ul>
<li><a href="storage-resources.html">Storage resources</a></li>
</ul>
</div>
</div>
<p>Example request:</p>
<pre>
GET /api/realms?format=xml HTTP/1.1
Authorization: Basic AU1J3UB2121Afd1DdyQWxLaTYTmJMNF4zTXBoRGdhMDh2RUw5ZDAN9zVXVa==
User-Agent: curl/7.20.1 (i386-redhat-linux-gnu)
Host: localhost:3001
Accept: */*
</pre>
<p>Server response:</p>
<pre>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: 639
&lt;?xml version='1.0' encoding='utf-8' ?&gt;
&lt;realms&gt;
&lt;realm href='http://localhost:3001/api/realms/us-east-1a' id='us-east-1a'&gt;
&lt;name&gt;us-east-1a&lt;/name&gt;
&lt;state&gt;available&lt;/state&gt;
&lt;/realm&gt;
&lt;realm href='http://localhost:3001/api/realms/us-east-1b' id='us-east-1b'&gt;
&lt;name&gt;us-east-1b&lt;/name&gt;
&lt;state&gt;available&lt;/state&gt;
&lt;/realm&gt;
&lt;realm href='http://localhost:3001/api/realms/us-east-1c' id='us-east-1c'&gt;
&lt;name&gt;us-east-1c&lt;/name&gt;
&lt;state&gt;available&lt;/state&gt;
&lt;/realm&gt;
&lt;realm href='http://localhost:3001/api/realms/us-east-1d' id='us-east-1d'&gt;
&lt;name&gt;us-east-1d&lt;/name&gt;
&lt;state&gt;available&lt;/state&gt;
&lt;/realm&gt;
&lt;/realms&gt;
</pre>
<h4>Get the details of a realm</h4>
<p>
To provide the details of a realm use call <strong>GET /api/realms/:id</strong>. The server responds with a <strong>name</strong>, a <strong>state</strong> and a <strong>limit</strong> applicable to the current requester. The name is an arbitrary label with no specific meaning in the API. The <strong>state</strong> can be either <strong>AVAILABLE</strong> or <strong>UNAVAILABLE</strong>.
</p>
<p>
The example below shows the realm for the Rackspace driver. Since Rackspace does not currently have a notion of realms, the Deltacloud Rackspace driver provides a single realm called 'US', signifying that all compute resources for that cloud provider are hosted in the United States:
</p>
<p>Example request:</p>
<pre>
GET /api/realms/us?format=xml HTTP/1.1
Authorization: Basic AU1J3UB2121Afd1DdyQWxLaTYTmJMNF4zTXBoRGdhMDh2RUw5ZDAN9zVXVa==
User-Agent: curl/7.20.1 (i386-redhat-linux-gnu)
Host: localhost:3002
Accept: */*
</pre>
<p>Server response:</p>
<pre>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: 182
&lt;?xml version='1.0' encoding='utf-8' ?&gt;
&lt;realm href='http://localhost:3001/api/realms/us' id='us'&gt;
&lt;name&gt;United States&lt;/name&gt;
&lt;state&gt;AVAILABLE&lt;/state&gt;
&lt;limit&gt;&lt;/limit&gt;
&lt;/realm&gt;
</pre>
<p><a class="btn btn-inverse btn-large" style="float: right" href="hardware-profiles.html">Hardware profiles <i class="icon-arrow-right icon-white" style="vertical-align:baseline"> </i></a></p>
<p><br></p>
<footer class="footer">
<p class="pull-right"><span class='icon-circle-arrow-up'>&nbsp;</span><a href="#">Back to top</a></p>
<div class='row'>
<div class='span3'>
<img src="/assets/img/asf.png" alt="Apache Software Foundation"/>
</div>
<div class='span9'>
<strong>Apache Deltacloud</strong> is a top-level project at the <a
href="http://www.apache.org">Apache Software Foundation</a>,
having graduated from the ASF Incubator in October
2011. Through a collaborative and meritocratic development process, Apache
projects deliver enterprise-grade, freely available software products that
attract large communities of users.
</div>
</div>
</footer>
</div> <!-- /container -->
<!-- Piwik -->
<script type="text/javascript">
var pkBaseURL = (("https:" == document.location.protocol) ? "https://stats.salasaga.org/aeolus/piwik/" : "http://stats.salasaga.org/aeolus/piwik/");
document.write(unescape("%3Cscript src='" + pkBaseURL + "piwik.js' type='text/javascript'%3E%3C/script%3E"));
</script><script type="text/javascript">
try {
var piwikTracker = Piwik.getTracker(pkBaseURL + "piwik.php", 2);
piwikTracker.trackPageView();
piwikTracker.enableLinkTracking();
} catch( err ) {}
</script><noscript><p><img src="http://stats.salasaga.org/aeolus/piwik/piwik.php?idsite=2" style="border:0" alt="" /></p></noscript>
<!-- End Piwik Tracking Code -->
</body>
</html>