addWithOverwrite

open override fun <T> addWithOverwrite(key: Key<T>, value: T?): Any?

Add value for given key even if already present.

Return

Previous value associated with key if any or null

Parameters

key
value

open suspend override fun <T> addWithOverwrite(key: Key<T>, value: T?, timeout: Long?): Any?

Same as addWithOverwrite in ApplicationContext with additional timeout parameter for wait time in case of multiple threads blocking on this method

Return

Parameters

key
value
timeout

in millis