Skip to content

Commit

Permalink
Doc: add change-log 0.9.6
Browse files Browse the repository at this point in the history
  • Loading branch information
drmingdrmer committed Apr 25, 2024
1 parent 14d42e4 commit 061218a
Show file tree
Hide file tree
Showing 2 changed files with 179 additions and 0 deletions.
91 changes: 91 additions & 0 deletions change-log.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,94 @@
## v0.9.6

Summary:

- Added:
- [5776139d](https://github.com/datafuselabs/openraft/commit/5776139d8ac15d94a800d1e0cf073dea5a7b216e) Add `#[since(version="1.0")]` to specify first version of a feature.
- [b172dc8e](https://github.com/datafuselabs/openraft/commit/b172dc8e261f4f2b1149c3ada70524cdf520d5b3) Add macro `expand!()` to expand a template.
- Improved:
- [99596c75](https://github.com/datafuselabs/openraft/commit/99596c754e19792b97737105acea257d70d1d6b6) `declare_raft_types` allows the types in any order.
- Fixed:
- [14d42e4f](https://github.com/datafuselabs/openraft/commit/14d42e4f33581dc0ea9c4eeaf0ff00ebec85dbb2) Load mebmership since `last_applied`, not `last_membership.index` on startup.

Detail:

### Added:

- Added: [5776139d](https://github.com/datafuselabs/openraft/commit/5776139d8ac15d94a800d1e0cf073dea5a7b216e) Add `#[since(version="1.0")]` to specify first version of a feature; by 张炎泼; 2024-04-12

`#[since(version = "1.0.0")]` adds a doc line `/// Since: Version(1.0.0)`.

Example:

```rust,ignore
/// Foo function
///
/// Does something.
#[since(version = "1.0.0")]
fn foo() {}
```

The above code will be transformed into:

```rust,ignore
/// Foo function
///
/// Does something.
///
/// Since: Version(1.0.0)
fn foo() {}
```

- Added: [b172dc8e](https://github.com/datafuselabs/openraft/commit/b172dc8e261f4f2b1149c3ada70524cdf520d5b3) Add macro `expand!()` to expand a template; by 张炎泼; 2024-04-13

`expand!()` renders a template with arguments multiple times.

### Example:

```rust,ignore
expand!(KEYED, // ignore duplicate by `K`
(K, T, V) => {let K: T = V;},
(a, u64, 1),
(a, u32, 2), // duplicate `a` will be ignored
(c, Vec<u8>, vec![1,2])
);
```

The above code will be transformed into:

```rust,ignore
let a: u64 = 1;
let c: Vec<u8> = vec![1, 2];
```

### Improved:

- Improved: [99596c75](https://github.com/datafuselabs/openraft/commit/99596c754e19792b97737105acea257d70d1d6b6) `declare_raft_types` allows the types in any order; by 张炎泼; 2024-04-13

By rewriting the template expanding part with a `#[proc_macro]`
`expand!()` defined in `openraft_macros`, `declare_raft_types`
does not require the types in fixed order:

Example:

```
declare_raft_types!(All:
D = (),
NodeId = u64,
R = (),
Node = (),
```

### Fixed:

- Fixed: [14d42e4f](https://github.com/datafuselabs/openraft/commit/14d42e4f33581dc0ea9c4eeaf0ff00ebec85dbb2) Load mebmership since `last_applied`, not `last_membership.index` on startup; by 张炎泼; 2024-04-25

Modify `StorageHelper::last_membership_in_log()` to scan the log
starting from the last applied index rather than the index of the last
applied membership log. This change reduces unnecessary I/O operations
during startup, previously caused by scanning from an incorrect starting
point.

## v0.9.5

Summary:
Expand Down
88 changes: 88 additions & 0 deletions change-log/v0.9.6.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
Summary:

- Added:
- [5776139d](https://github.com/datafuselabs/openraft/commit/5776139d8ac15d94a800d1e0cf073dea5a7b216e) Add `#[since(version="1.0")]` to specify first version of a feature.
- [b172dc8e](https://github.com/datafuselabs/openraft/commit/b172dc8e261f4f2b1149c3ada70524cdf520d5b3) Add macro `expand!()` to expand a template.
- Improved:
- [99596c75](https://github.com/datafuselabs/openraft/commit/99596c754e19792b97737105acea257d70d1d6b6) `declare_raft_types` allows the types in any order.
- Fixed:
- [14d42e4f](https://github.com/datafuselabs/openraft/commit/14d42e4f33581dc0ea9c4eeaf0ff00ebec85dbb2) Load mebmership since `last_applied`, not `last_membership.index` on startup.

Detail:

### Added:

- Added: [5776139d](https://github.com/datafuselabs/openraft/commit/5776139d8ac15d94a800d1e0cf073dea5a7b216e) Add `#[since(version="1.0")]` to specify first version of a feature; by 张炎泼; 2024-04-12

`#[since(version = "1.0.0")]` adds a doc line `/// Since: Version(1.0.0)`.

Example:

```rust,ignore
/// Foo function
///
/// Does something.
#[since(version = "1.0.0")]
fn foo() {}
```

The above code will be transformed into:

```rust,ignore
/// Foo function
///
/// Does something.
///
/// Since: Version(1.0.0)
fn foo() {}
```

- Added: [b172dc8e](https://github.com/datafuselabs/openraft/commit/b172dc8e261f4f2b1149c3ada70524cdf520d5b3) Add macro `expand!()` to expand a template; by 张炎泼; 2024-04-13

`expand!()` renders a template with arguments multiple times.

### Example:

```rust,ignore
expand!(KEYED, // ignore duplicate by `K`
(K, T, V) => {let K: T = V;},
(a, u64, 1),
(a, u32, 2), // duplicate `a` will be ignored
(c, Vec<u8>, vec![1,2])
);
```

The above code will be transformed into:

```rust,ignore
let a: u64 = 1;
let c: Vec<u8> = vec![1, 2];
```

### Improved:

- Improved: [99596c75](https://github.com/datafuselabs/openraft/commit/99596c754e19792b97737105acea257d70d1d6b6) `declare_raft_types` allows the types in any order; by 张炎泼; 2024-04-13

By rewriting the template expanding part with a `#[proc_macro]`
`expand!()` defined in `openraft_macros`, `declare_raft_types`
does not require the types in fixed order:

Example:

```
declare_raft_types!(All:
D = (),
NodeId = u64,
R = (),
Node = (),
```

### Fixed:

- Fixed: [14d42e4f](https://github.com/datafuselabs/openraft/commit/14d42e4f33581dc0ea9c4eeaf0ff00ebec85dbb2) Load mebmership since `last_applied`, not `last_membership.index` on startup; by 张炎泼; 2024-04-25

Modify `StorageHelper::last_membership_in_log()` to scan the log
starting from the last applied index rather than the index of the last
applied membership log. This change reduces unnecessary I/O operations
during startup, previously caused by scanning from an incorrect starting
point.

0 comments on commit 061218a

Please sign in to comment.