Skip to content

Commit 0f72079

Browse files
committed
Update release notes
Signed-off-by: Leandro Lucarella <[email protected]>
1 parent 012b610 commit 0f72079

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

RELEASE_NOTES.md

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,21 @@
1212

1313
## New Features
1414

15-
<!-- Here goes the main new features and examples or instructions on how to use them -->
15+
- A new configuration mode was added to the resampler (and thus the resampling actor and microgrid high-level interface). When passing a new `ResamplerConfig2` instance to the resampler, it will use a wall clock timer instead of a monotonic clock timer. This timer adjustes sleeps to account for drifts in the monotonic clock, and thus allows for more accurate resampling in cases where the monotonic clock drifts away from the wall clock. The monotonic clock timer option will be deprecated in the future, as it is not really suitable for resampling. The new `ResamplerConfig2` class accepts a `WallClockTimerConfig` to fine-tune the wall clock timer behavior, if necessary.
16+
17+
Example usage:
18+
19+
```python
20+
from frequenz.sdk import microgrid
21+
from frequenz.sdk.timeseries import ResamplerConfig2
22+
23+
await microgrid.initialize(
24+
MICROGRID_API_URL,
25+
# Just replace the old `ResamplerConfig` with the new `ResamplerConfig2`
26+
resampler_config=ResamplerConfig2(resampling_period=timedelta(seconds=1.0)),
27+
)
28+
```
1629

1730
## Bug Fixes
1831

19-
<!-- Here goes notable bug fixes that are worth a special mention or explanation -->
32+
- When using the new wall clock timer in the resampmler, it will now resync to the system time if it drifts away for more than a resample period, and do dynamic adjustments to the timer if the monotonic clock has a small drift compared to the wall clock.

0 commit comments

Comments
 (0)