Skip to content

Commit

Permalink
Remove MultiMap (#6988)
Browse files Browse the repository at this point in the history
  • Loading branch information
piotrp authored Oct 7, 2024
1 parent 353e063 commit 48adf00
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 59 deletions.
1 change: 1 addition & 0 deletions docs/Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
* [#6952](https://github.com/TouK/nussknacker/pull/6952) Improvement: TypeInformation support for scala.Option
* [#6840](https://github.com/TouK/nussknacker/pull/6840) Introduce canCastTo, castTo and castToOrNull extension methods in SpeL.
* [#6974](https://github.com/TouK/nussknacker/pull/6974) Add SpeL suggestions for cast methods parameter.
* [#6988](https://github.com/TouK/nussknacker/pull/6988) Remove unused API classes: `MultiMap`, `TimestampedEvictableStateFunction`

## 1.17

Expand Down
4 changes: 3 additions & 1 deletion docs/MigrationGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,13 @@ To see the biggest differences please consult the [changelog](Changelog.md).
* [#6695](https://github.com/TouK/nussknacker/pull/6695) `SingleTypingResult` API changes:
* Added `typeHintsObjType` which is used as a type for a type hints, suggester and validation.
* Renamed `objType` to `runtimeObjType` which indicates a current object in a runtime.

* [#6766](https://github.com/TouK/nussknacker/pull/6766)
* Process API changes:
* Field `ScenarioWithDetails.labels` was added
* Field `ScenarioWithDetails.tags` was removed (it had the same value as `labels` and was not used)
* [#6988](https://github.com/TouK/nussknacker/pull/6988) Removed unused API classes: `MultiMap`, `TimestampedEvictableStateFunction`.
`MultiMap` was incorrectly handled by Flink's default Kryo serializer, so if you want to copy it to your code
you should write and register a proper serializer.

### REST API changes

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,20 +47,6 @@ abstract class EvictableStateFunction[In, Out, StateType] extends KeyedProcessFu

}

abstract class TimestampedEvictableStateFunction[In, Out, StateType]
extends EvictableStateFunction[In, Out, MultiMap[Long, StateType]] {

override protected def moveEvictionTime(offset: Long, ctx: KeyedProcessFunction[String, In, Out]#Context): Unit = {
super.moveEvictionTime(offset, ctx)
state.update(stateValue.from(ctx.timestamp() - offset))
}

protected def stateValue: MultiMap[Long, StateType] = {
Option(state.value()).getOrElse(MultiMap[Long, StateType](Ordering.Long))
}

}

abstract class LatelyEvictableStateFunction[In, Out, StateType]
extends KeyedProcessFunction[String, In, Out]
with LatelyEvictableStateFunctionMixin[StateType] {
Expand Down

This file was deleted.

0 comments on commit 48adf00

Please sign in to comment.