deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lut...@redhat.com
Subject RFC: Separate CIMI (de)serialization from server functionality
Date Fri, 01 Mar 2013 00:15:26 GMT

This patch shows how we can split the current CIMI::Model classes into two
different class hierarchies, CIMI::Model and CIMI::Service. After the
split, the former will strictly be restricted to (de)serialization of CIMI
resources whereas the latter will be dedicated to interaction with drivers
and the DB.

One motivator for this change is that the (de)serialization functionality
of the current CIMI::Model classes is useful in other contexts, especially
for clients, be those blackbox tests or the CIMI webapp. Dealing with
drivers and the DB on the other hand is only useful for the server.

Once we have completed the split, we should extract the CIMI::Model classes
into a separate gem that can be used as the basis for CIMI clients. An
important aspect of this is that the new CIMI::Model classes should not
make any reference to a context (server) anymore.

The patch is by no means complete, it only shows what this split would look
like using the example of Machine. The tests in
tests/cimi/collection/machines_test.rb do pass though :)

Michal: feel free to expand this patch.

David

Mime
View raw message