dotnet / dotnet/MQTTnet

Support streams when sending and/or receiving

Open
#939 18 comments 0 reactions 0 assignees View on GitHub
feature-request
Dominant language
C#
Stars
5.1k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

### Describe the feature request

The `MqttApplicationMessage` only supports `byte[]` but it would be nice if it would support a Stream object. The MQTT spec allows for 256MB payloads and using streams makes sense from both when sending and receiving. For example, the ability to pass a FileStream and especially useful if the stream is still being written to.

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Example. I'm am trying to do [...] but [...]

### Which project is your feature request related to?

- Client

### Describe the solution you'd like

Support streams when sending and/or receiving

### Describe alternatives you've considered

The payload byte[] requires all data to be first loaded into memory which is not ideal when dealing with large data fragments and results in unneeded memory pressure.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.