Skip to content

About

Datatype Channels over Azure Service Bus

Topics

Resources

Code of conduct

Security policy

Stars

5 stars

Watchers

3 watching

Forks

Repository files navigation

Azure Service Bus Datatype Channels

Build and release with Azure Pipelines NuGet

Small, F#-friendly abstraction layer over Azure Service Bus .NET clients, featuring:

  • Channels module and interface that provide a way to construct Consumer and Publisher instances.
  • Pull-based Consumer interface implementation with deterministic release and background message lock renewal.
  • One-off and reusable Publisher instances.
  • Subscription and queue based bindings, with automatic upkeep (create/update), as well as temporary and deadletter queues.
  • Pluggable serialization and conversion between bus primitives and application message representation.

Consumer and Publisher types facilitate both sides of Datatype Channel pattern and pull-based consumer is useful for implementation of CEP systems with backpressure/throttling.

Loosely based on FsBunny - F# API for event streaming over RMQ.

Building

Pre-requisites:

  • .NET SDK matching global.json (10.0.403 with latest patch in that feature band)
  • Access to the shared avs-oss/Public/OSS-FSharp-Consumption feed in NuGet.config. Saved packages restore anonymously. A new dependency version must first be saved to the feed by a maintainer with Feed and Upstream Reader (Collaborator) on it; CI cannot save packages. See the dependency feed notes.
  • Azure CLI only for explicitly requested local provisioning/integration

Build without Azure access:

dotnet fsi build.fsx -t build

build.fsx is the single entrypoint for local and pipeline orchestration, using FAKE targets with separate dependency graphs. Discover the entire surface without application credentials, local settings or target execution (the dependency cache/feed prerequisite still applies):

dotnet fsi build.fsx -- --help
dotnet fsi build.fsx --list
dotnet fsi build.fsx -t graph ci preview preview-integration preview-publish promote-fetch promote-pack promote-stage publish test

The test suite is an integration suite. It creates Service Bus messaging entities and requires an authenticated identity with access to a test namespace. It is not an offline unit-test suite.

For local integration testing only, the following explicit initialization provisions Azure resources. Do not run it for an offline build or in CI:

dotnet fsi build.fsx -t init <YOUR_LOCATION> <YOUR_RG> <YOUR_NAMESPACE>

Where

  • <YOUR_LOCATION> is Azure region where Service Bus will be provisioned
  • <YOUR_RG> is the name of the resource group to deploy into
  • <YOUR_NAMESPACE> Azure Service Bus namespace to create
dotnet fsi build.fsx

CI and release use three Azure Pipelines:

  • PR validation (.pipelines/azure-pipelines-pr.yml, 1ES Unofficial, avs-oss/Public) builds on the Azure Linux 3 ARM64 pool and runs unsigned build.fsx -t ci with no credentials.
  • Preview (.pipelines/azure-pipelines-preview.yml, 1ES Official, avs-oss/Public) runs on master pushes. It builds X.Y.N-preview with build.fsx -t preview, tests it against an existing Service Bus namespace with preview-integration, then pushes the tested preview to the preview feed with preview-publish.
  • Official promotion (.pipelines/OneBranch.Official.yml, OneBranch, msazure/One) runs manually for one chosen preview run. It fetches that run's drop (promote-fetch), signs the first-party DLL, repacks it as X.Y.N without rebuilding (promote-pack), signs the package and seals the artifact (promote-stage). It does not rebuild or retest: only signatures and the version change. Third-party dependencies are not re-signed.

All three install the global.json-pinned SDK with UseDotNet@2 (an approved runtime download). None of them authenticates to the dependency feed. Release is an explicitly opted-in manual promotion run (publishPackage: true), not a Git tag trigger. The publish target validates the signed, promoted artifact without building or packing; DotNetCoreCLI@2 then pushes it to nuget.org through an external NuGet service connection after release approval. The preview and promotion pipelines have not run yet, and administrator setup is still required; this is not evidence of production readiness. No pipeline runs local init; initCI remains retired and fails closed. The default local target is still test, which contacts Azure. See the pipeline setup and cutover guide for administrator prerequisites and release authorization.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.

When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

Trademarks

This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow Microsoft's Trademark & Brand Guidelines. Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies.

About

Datatype Channels over Azure Service Bus

Topics

Resources

Code of conduct

Security policy

Stars

5 stars

Watchers

3 watching

Forks

Releases

Used by

Contributors

Languages