Skip to content

Commit

Permalink
Merge pull request #211 from nats-io/tyler_duration_i64
Browse files Browse the repository at this point in the history
Use i64 instead of isize for representing Go's time.Duration type. Closes #208.
  • Loading branch information
spacejam committed Sep 1, 2021
2 parents c358859 + fa86add commit ddd9c87
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
# 0.14.0

## Breaking Changes

- #211 `jetstream::ConsumerConfig.ack_wait` and
`jetstream::PubOpts.ttl` have been changed from
`isize` to `i64`.

# 0.13.1

## New Features
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "nats"
version = "0.13.1"
version = "0.14.0"
description = "A Rust NATS client"
authors = ["Derek Collison <derek@nats.io>", "Tyler Neely <tyler@nats.io>", "Stjepan Glavina <stjepan@nats.io>"]
edition = "2018"
Expand Down
4 changes: 2 additions & 2 deletions src/jetstream_types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ pub struct ConsumerConfig {
pub ack_policy: AckPolicy,
/// How long to allow messages to remain un-acknowledged before attempting redelivery
#[serde(default, skip_serializing_if = "is_default")]
pub ack_wait: isize,
pub ack_wait: i64,
/// Maximum number of times a specific message will be delivered. Use this to avoid poison pill messages that repeatedly crash your consumer processes forever.
#[serde(default, skip_serializing_if = "is_default")]
pub max_deliver: i64,
Expand Down Expand Up @@ -551,7 +551,7 @@ pub(crate) struct SubOpts {
/// Options for publishing
#[derive(Debug, Default, Serialize, Deserialize, Clone)]
pub(crate) struct PubOpts {
pub ttl: isize,
pub ttl: i64,
pub id: String,
// Expected last msgId
pub lid: String,
Expand Down

0 comments on commit ddd9c87

Please sign in to comment.