-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement mqtt message expiry #640
Conversation
.../io/aklivity/zilla/runtime/binding/mqtt/kafka/internal/stream/MqttKafkaSubscribeFactory.java
Show resolved
Hide resolved
...io/aklivity/zilla/specs/binding/mqtt/kafka/streams/kafka/subscribe.expire.message/client.rpt
Outdated
Show resolved
Hide resolved
...io/aklivity/zilla/specs/binding/mqtt/kafka/streams/kafka/subscribe.expire.message/server.rpt
Outdated
Show resolved
Hide resolved
...lla/specs/binding/mqtt/kafka/streams/kafka/publish.one.message.changed.topic.name/client.rpt
Outdated
Show resolved
Hide resolved
.../zilla/specs/binding/mqtt/kafka/streams/kafka/subscribe.expire.message.fragmented/client.rpt
Outdated
Show resolved
Hide resolved
.../io/aklivity/zilla/runtime/binding/mqtt/kafka/internal/stream/MqttKafkaSubscribeProxyIT.java
Outdated
Show resolved
Hide resolved
.../io/aklivity/zilla/runtime/binding/mqtt/kafka/internal/stream/MqttKafkaSubscribeProxyIT.java
Outdated
Show resolved
Hide resolved
@@ -1455,6 +1461,7 @@ private void onKafkaData( | |||
expireInterval = timestamp + helper.timeout - now().toEpochMilli(); | |||
if (expireInterval < 0) | |||
{ | |||
expiredMessage = true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
long expireInterval;
if (helper.timeout != -1)
{
...
}
else
{
expireInterval = helper.timeout;
}
can this be simplified to:
long expireInterval = -1;
if (helper.timeout != -1)
{
...
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Originally I wanted to write this like you showed. But as we're using the expireInterval in a lambda we'd get:
"Variable used in lambda expression should be final or effectively final".
No description provided.