Skip to content

Optimize memory allocation for mqtt-kafka offset tracking#694

Merged
jfallows merged 3 commits intoaklivity:developfrom
bmaidics:issue-675
Jan 15, 2024
Merged

Optimize memory allocation for mqtt-kafka offset tracking#694
jfallows merged 3 commits intoaklivity:developfrom
bmaidics:issue-675

Conversation

@bmaidics
Copy link
Contributor

@bmaidics bmaidics commented Jan 3, 2024

No description provided.

@bmaidics bmaidics added the bug Something isn't working label Jan 3, 2024
@bmaidics bmaidics self-assigned this Jan 3, 2024
@bmaidics bmaidics linked an issue Jan 3, 2024 that may be closed by this pull request
for (; offset < buffer.capacity(); offset += BitUtil.SIZE_OF_SHORT)
{
metadataList.add((int) buffer.getShort(offset));
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs a version prefix in case we choose to evolve the structure over time.
Needs BIG_ENDIAN as we are putting into an external system so could be read by any endian environment, not just local native endianness.

Also, let's use int16[length] support in .idl to generate a flyweight instead.
See examples in flyweight test resources at https://github.com/aklivity/zilla/blob/develop/build/flyweight-maven-plugin/src/test/resources/test-project/test.idl#L123.

@jfallows jfallows merged commit 6191589 into aklivity:develop Jan 15, 2024
bmaidics added a commit to bmaidics/zilla that referenced this pull request Jan 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Optimize memory allocation for mqtt-kafka offset tracking

2 participants