To wrap things up weekly I decided to introduce a short list of Azure news, which seemed the most important for me. It’s a purely subjective collection of articles, which may or may not affect you, still I treat it as a good reminder of what goodness was introduced recently.
As introduced during Microsoft Build 2019, the ability to share your NuGet, Maven or npm packages finally reached its public preview in the previous week. This greatly enhances the overall capability of DevOps to support OSS projects, as now you can deliver the artifacts to your feeds and share them with the community.
The downside? Only the first 2GBs are free – once you reach the maximum capacity, the pricing comes into play(starting at 2$ per GB).
Most of the mature and advanced CI/CD pipelines face a problem of increased delivery time due to multiple steps, which have to be performed to integrate everything. Multiple packages restore operation take forever to complete as lower your ability to deliver quickly and often. This is where caching comes into play, allowing you to share intermediary artifacts and reuse them.
As caching for Azure Pipelines is in preview, you may not get the best results each time yet(in fact, the DevOps team mentioned that in their post), still it’s a feature worth testing in your pipelines. The concept is as simple as the presented example:
Here, all you need is to provide a proper cache key and the path to files. It’s important to provide an immutable key(like a lock package from Yarn or npm), so each consecutive job run will be able to leverage cached files.
What to remember? Between V0 and V1 there may be breaking changes, so make sure you are prepared for them(and don’t go for production with this feature yet). Also make sure your cache key gives you some room for invalidating cached files – you don’t want to end up with outdated packages only because you went for a static cache key.