[occi-wg] Templates (was Re: OCCI Dashboard)

Sam Johnston samj at samj.net
Sat Jun 27 05:12:33 CDT 2009


On Thu, Jun 25, 2009 at 8:29 PM, <shlomo.swidler at gmail.com> wrote:

> > A template is just a special type of compute resource and there's nothing
> to
> > say we're not going to end up with template network and storage resources
> as
> > well - I really don't think a new noun is justified and would prefer to
> keep
> > things as simple as possible... 3 nouns is about right.
> >
> > Sam
>
> I'm still warping^H^H^H^H^H wrapping my head around RESTful thinking
> as opposed to OO, so please bear with me.
>

That's ok... in fact RESTful interfaces are usually fairly OO - what I call
ROA is just taking it to the extreme. Most people are still thinking like
functional programming (e.g. RPC-style), as reflected in APIs like Amazon
EC2.


> If both "AMI"s (template-computes) and "instances" (actual-computes)
> are "compute" resources, then how would the client distinguish between
> the two? One reason to distinguish between them is to separately
> classify them into different areas of the UI (for example the "Images"
> vs. Instances" tabs of ElasticFox) based on the verbs that can be done
> to them.
>

The simplest solution for this is to add templates to a "template" category.
In fact we could specify a number of well known categories like "validated",
"[in]secure", etc.


> On second thought, I may have answered my own question: we can
> distinguish template-computes from actual-computes by looking at the
> verb links that are provided on them. Actual-computes will have verbs
> such as "start","stop", "pause", "resume", "delete" (depending on
> their current state); while template-computes will only have "start"
> and "delete", and their state will never change (not sure, but it
> seems to me that a template's state will not change - you can only
> create a new resource from a template or delete the template
> altogether).
>

Exactly, only there may be conditions where machines in transition or in
abnormal/error states appear as templates when they should not. I'm not yet
sure whether we need to explicitly state that a machine is a template (or
just rely on the presence or absence of verbs like "clone" and "start"
respectively)... but I am sure that they are the same noun.


> Then again, if an infrastructure provider does not allow
> actual-computes to be "paused" or "resumed" but does allow "start" and
> "stop", then we cannot distinguish between actual-computes that are
> stopped (having verbs "start" and "delete") and between
> template-computes (having verbs "start" and "delete").
>

Right. It's also possible that user permissions will confuse things -
perhaps a failover operator can start but not stop machines for example.


> So then the question remains: how do we reliably distinguish between
> template-computes and actual-computes? Or template-XXs and actual-XXs
> ?
>

I'm thinking categories - we already have a category system that will handle
this well and can even have a dedicated vocabulary/schema for our
well-defined categories.

Sam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.ogf.org/pipermail/occi-wg/attachments/20090627/3783099a/attachment.html 


More information about the occi-wg mailing list