eclipse-paho / eclipse-paho/paho.mqtt.java

Discussion: Could MqttWireMessage.createWireMessage(InputStream) be public ?

Open
#991 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
2.3k
Forks
918
PR merge metrics
No merged PRs in 30d

Description

**This is not a bug issue**

Apologies in advance if this is not the way to open a discussion.

The question is simple, could the method be exposed public:
https://github.com/eclipse/paho.mqtt.java/blob/master/org.eclipse.paho.mqttv5.client/src/main/java/org/eclipse/paho/mqttv5/common/packet/MqttWireMessage.java#L201

or is there a specific need for it to be a ByteArrayInputStream ?

This would prevent needing to read the stream into a byte[] in order to read it again to parse the message, so it could be directly read from the original stream instead.

What do you think ?
Thank you

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading MqttWireMessage.createWireMessage(InputStream) at the linked location and inspect how the method is currently scoped and used. Determine whether exposing it publicly and accepting the original stream is compatible with the client API; the issue is done only after a maintainer decides the intended API and the resulting behavior is specified.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api, networking
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.