cloudevents / cloudevents/sdk-java
Replace byte[] in getData() with ByteBuffer?
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 446
- Forks
- 172
- PR merge metrics
- No merged PRs in 30d
Description
ByteBuffers gives a great deal of flexibility (they can be allocated in and off heap). If allocated outside the heap, they give a huge perf boost and, if allocated in the heap, they have more or less the same cost of a byte[].
Replacing byte[] will require changing the MessageReader and MessageWriter interfaces too, together with all the impls
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing getData() and the MessageReader and MessageWriter interfaces, then identify all implementations affected by the proposed type change. Review the API implications of using ByteBuffer, including heap and off-heap allocation, and finish when the interfaces and every implementation consistently reflect the agreed design.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100