Random Acts of Architecture

Tales of an architect trying to bring order to the chaos that is modern information technology.

The Potential of Cosmos: Containers

cosmos-potential

Cosmos is an operating system construction kit in development since 2006. At first glance, it appeals to the “Internet of Things” (IoT) crowd. One could control home automation or run a Raspberry Pi or Arduino in C#. Cosmos is also interesting technically, as Scott Hanselman describes. .Net languages are rarely used for lower level programming and this project is an interesting case study.

However, there is a whole other angle to consider – a competitor to containers. Containers, single-application virtual machines, provide the hardware independence of virtual machines but are smaller and use an operating system’s existing isolation and switching mechanisms instead of a hypervisor.

If Cosmos or a system built on it supports a reasonable set of APIs, such as an early version of .Net Standard, these could be run like containers. The components and functionality would be minimal, reducing the surface area of attack and the need for patching. They could be smaller than scratch containers because they are a single binary.

A Cosmos container, for want of a better term, could run on bare metal for maximum performance. It could also run as a “pico virtual machine”, needing only a few MB of RAM and storage, to minimize costs.

Of course, there is more to containers than just the image format and hosting engine. Docker, the most common container engine, has a whole ecosystem of orchestration, management and monitoring tools. Many of these are open source and have high contribution rates, so adding Cosmos container support is not unreasonable.

Supporting Cosmos containers directly on hardware may require hypervisor changes, meaning existing IaaS vendors would not initially support it. That said, Amazon does support Arduino as a cloud platform. Cosmos containers could also run in a “serverless” compute service like AWS Lambda.

Of course, the Cosmos team have spent a long time bringing their original vision to fruition and this is a significant change in direction. However, we live in a world of potential where software is changing so quickly and is often open for anyone to build on.

 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: