Temp.RocketMQ.Client 0.0.1

dotnet add package Temp.RocketMQ.Client --version 0.0.1
                    
NuGet\Install-Package Temp.RocketMQ.Client -Version 0.0.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Temp.RocketMQ.Client" Version="0.0.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Temp.RocketMQ.Client" Version="0.0.1" />
                    
Directory.Packages.props
<PackageReference Include="Temp.RocketMQ.Client" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Temp.RocketMQ.Client --version 0.0.1
                    
#r "nuget: Temp.RocketMQ.Client, 0.0.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Temp.RocketMQ.Client@0.0.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Temp.RocketMQ.Client&version=0.0.1
                    
Install as a Cake Addin
#tool nuget:?package=Temp.RocketMQ.Client&version=0.0.1
                    
Install as a Cake Tool

The .NET Implementation of Apache RocketMQ Client

NuGet Gallery

English | 简体中文 | RocketMQ Website

Supported .NET Versions

.NET 5+ and .NET Core 3.1 is supported.

Due to the release of .NET 5 in 2020, which unified .NET Framework and .NET Core, and has gradually become the mainstream platform for .NET development. We strongly recommend using .NET 5+ to access RocketMQ.

We also support access to RocketMQ using .NET Core 3.1. Note: If you want to use .NET Core 3.1 and want to disable TLS/SSL by Org.Apache.Rocketmq.ClientConfig.Builder.EnableSsl(false), add the following code before you run.

// Only necessary if you want to disable TLS/SSL on .NET Core 3.1
AppContext.SetSwitch("System.Net.Http.SocketsHttpHandler.Http2UnencryptedSupport", true)

See more details about .NET 5 from Introducing .NET 5.

Architecture

The client would be developed using the protocols outlined in rocketmq-apis and built on gRPC-dotnet, leveraging Protocol Buffers for data serialization and deserialization during transmission.

Quickstart & Build

Use the command below to add client into your dependencies.

dotnet add package RocketMQ.Client

You can obtain the latest version of RocketMQ.Client from NuGet Gallery. To assist with getting started quickly and working with various message types and clients, we offer examples here.

Layout of this project roughly follows this guide . The solution contains a class library, a unit test module and an example console module. Assuming you are at the home of this repository:

# build the project
dotnet build
# run unit tests
dotnet test -l "console;verbosity=detailed"

Logging System

We use Microsoft.Extensions.Logging as our logging implementation.

The default LoggerFactory is NLog. Similar to the Java binding, we allow the use of environment variables to customize the related configuration:

  • rocketmq_log_level: Log output level, default is INFO.
  • rocketmq_log_root: The root directory of the log output. The default path is $HOME/logs/rocketmq, so the full path is $HOME/logs/rocketmq/rocketmq-client.log.
  • rocketmq_log_file_maxIndex: The maximum number of log files to keep. The default is 10, and the size of a single log file is limited to 64 MB. Adjustment is not supported yet.

If you want to use a custom LoggerFactory, you can use the MqLogManager.UseLoggerFactory method to configure.

var loggerFactory = LoggerFactory.Create(
      builder => builder
         .AddFilter("Org.Apache.Rocketmq", LogLevel.Warning)
         .AddConsole());
MqLogManager.UseLoggerFactory(loggerFactory);

Publishing Steps

  1. Open the command line, and change the directory to the project folder that you want to package.
  2. Run the dotnet pack --configuration Release command. This will create a NuGet package in the bin/Release folder of the project.
  3. To upload the package to NuGet, go to the NuGet website and sign in. Click on the "Upload" button and select the package file from the bin/Release folder.
  4. Follow the instructions on the website to complete the upload process. Once the package is uploaded, it will be available for others to download and use.
Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.0.1 243 6/11/2024