VOOZH about

URL: https://thenewstack.io/nitric-a-cloud-portability-framework-for-code/

⇱ Nitric, a Cloud Portability Framework for Code - The New Stack


TNS
SUBSCRIBE
Join our community of software engineering leaders and aspirational developers. Always stay in-the-know by getting the most important news and exclusive content delivered fresh to your inbox to learn more about at-scale software development.
REQUIRED
It seems that you've previously unsubscribed from our newsletter in the past. Click the button below to open the re-subscribe form in a new tab. When you're done, simply close that tab and continue with this form to complete your subscription.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.
Welcome and thank you for joining The New Stack community!
Please answer a few simple questions to help us deliver the news and resources you are interested in.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Great to meet you!
Tell us a bit about your job so we can cover the topics you find most relevant.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Welcome!

We’re so glad you’re here. You can expect all the best TNS content to arrive Monday through Friday to keep you on top of the news and at the top of your game.

What’s next?

Check your inbox for a confirmation email where you can adjust your preferences and even join additional groups.

Follow TNS on your favorite social media networks.

Become a TNS follower on LinkedIn.

Check out the latest featured and trending stories while you wait for your first TNS newsletter.

PREV
1 of 2
NEXT
VOXPOP
As a JavaScript developer, what non-React tools do you use most often?
Angular
0%
Astro
0%
Svelte
0%
Vue.js
0%
Other
0%
I only use React
0%
I don't use JavaScript
0%
Thanks for your opinion! Subscribe below to get the final results, published exclusively in our TNS Update newsletter:
NEW! Try Stackie AI
From clobbered drafts to real-time sync
Apr 14th 2026 10:00am, by David Moore
TypeScript 6.0 RC arrives as a bridge to a faster future
Mar 14th 2026 9:00am, by Darryl K. Taft
Mastra empowers web devs to build AI agents in TypeScript
Jan 28th 2026 11:00am, by Loraine Lawson
2022-04-15 10:00:08
Nitric, a Cloud Portability Framework for Code
contributed,
Cloud Native Ecosystem / Cloud Services / Open Source

Nitric, a Cloud Portability Framework for Code

Nitric is an open source framework that enables teams to develop and manage a single code base that can be deployed to any cloud.
Apr 15th, 2022 10:00am by Rak Siva
👁 Featued image for: Nitric, a Cloud Portability Framework for Code
Rak Siva
Rak is an engineer on team Nitric with a passion for the cloud native movement and improving development experiences. He has 15 years of experience in the software industry, with his most recent role as the head of engineering for a leading FinTech company. In his spare time, he enjoys traveling and nature photography.

Cloud-managed services are emerging as the fastest way for anyone to build applications in the cloud. The benefits these services provide come with a tradeoff: vendor lock-in. It’s costly to move away from your provider if another solution becomes a better fit in the future.

I’ve been through it myself. Finding initial speed and success with the cloud services, fully utilizing their capabilities, and then running into cost increases and technical limitations. It seems inevitable to be stuck between two bad choices: migrate or absorb the drawbacks.

Nitric is an open source framework that enables teams to develop and manage a single code base that can be deployed to any cloud. We currently support Amazon Web Services, Azure and GCP and plan on expanding to others with community interest and involvement.

Portability for Proprietary Clouds

The idea for Nitric started taking shape as we researched the cloud providers for a project we were working on. We noticed that in this competitive market, the cloud providers have taken inspiration from each other and offer the same functionality with their base services.

The differences come into play with the interfaces, configuration and deployment of those services. Developing against these specifics contributes to lock-in, but the best practices are ultimately cloud-agnostic. We set out to take advantage of the commonalities to elevate the best practices into a reusable framework.

The beating heart of our framework is the Nitric Server, which includes cloud provider-specific plugins for each of the supported services. The Nitric Server is responsible for translating application requests into the format required by the appropriate cloud.

For example, a request to access a document collection in Nitric will translate into reading from DynamoDB in AWS. The SDK layer and the Nitric Server communicate over gRPC, leveraging the efficiencies of connection management in HTTP/2 using protocol buffers to optimize payload sizes.

The Nitric framework offers a consistent set of APIs exposing cloud resources including storage, documents, events, secrets and queues. These fundamental resources are at the core of many applications and are available to compute services which can be exposed as routes or methods in an API gateway. We’ve chosen key services to support in the Nitric framework, and with help from the community, we are aiming to grow this list (look out for “good first issue” tags in our GitHub repositories).

Nitric handles deployment by leveraging an open source tool from the cloud native community, Pulumi — an Infrastructure-as-Code platform. Our framework builds on their efforts toward cloud-agnostic deployments to provide developers with both the infrastructure and resources required to build their applications in a single deployment. We also address fundamental policy issues, e.g., applying the principles of least privilege for all resources which are deployed.

Vendor lock-in is not the only challenge with cloud development, and while we started with tackling the challenges of portability, our mission is to improve the cloud native development experience as a whole. Let me walk through two areas that are important focuses for us.

Eliminating Config

Apps deployed to the managed services are heavy on config, and when you throw additional technologies into the mix, e.g., Open API, the amount of config begins to affect productivity.

The first version of the Nitric framework required config files. Once we started using it for realistically sized projects, we saw that the effort involved was more than writing the code itself. We knew we had to improve on this as the lines of config were time consuming to write, error prone and hard to review.

One of the first ideas we considered was to place a UI in front of the config. At the very least we could minimize errors, but this seemed like a band-aid-style solution. Instead, we asked ourselves an important question: Are config files actually necessary? Brainstorming and researching this topic led to a new feature, which we call “Config-as-Code.”

The Nitric APIs eliminate a large portion of the configuration that developers need to write. On deployment, Nitric will automatically provision and set up permissions for things like collections, buckets, secrets, etc., by inspecting code and detecting resource declaration.

With just a few simple lines of code, we’re ready to provision:

  • An API named “example” that exposes a get method on path “/welcome”.
  • A storage bucket that can only be written to.
  • A document collection named “example” that is ready for read/write.
import { topic, api, collection } from '@nitric/sdk';

const exampleApi = api('example');
const exampleBucket = bucket('example').for('writing');
const exampleCollection = collection('example').for('reading','writing');

// Implement a get method

exampleApi.get('/welcome', async (ctx) => {

...

});

Keeping the Framework Open

A great developer experience should be unrestricted, allowing developers to focus on problem-solving and writing code. Nitric’s APIs don’t limit the use of other frameworks; we’re here to join the ecosystem of amazing development frameworks.

In that vein, we’re appreciative of suggestions to help us build something useful for the community. If you’re interested in our work and itching to give it a go, the Nitric documentation is a great place to start. Check out all of our source code on GitHub and contribute or reach out with feedback!

TRENDING STORIES
Rak Siva, vice president of engineering at Team Nitric, is deeply committed to elevating the experience for software developers. With a rich 15-year tenure in the software industry, he began his engineering journey immersed in the exhilarating challenges of the...
Read more from Rak Siva
SHARE THIS STORY
TRENDING STORIES
Amazon Web Services is a sponsor of The New Stack.
SHARE THIS STORY
TRENDING STORIES
TNS DAILY NEWSLETTER Receive a free roundup of the most recent TNS articles in your inbox each day.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.