Search code examples
stateapache-pulsar

Apache Pulsar function's state, is it persisted "forever" if we don't explicitly call deleteState?


When a function uses context.putState(id, object), is the saved object forever saved in the bookkeeper until an explicit deleteState(same id) is called?

Is there some point in time, some action of any kind, or some event which cleans up the used state storage space, besides calling deleteState? Like for example, if a function is deleted, does the bookkeeper still keep the function's state objects persisted, or are they erased as well?


Solution

  • I believe when a function is deleted we delete the table that holds all the states.

    This is definitely something that needs some testing.

    If there are recommendations or ways that state is defined is not well defined please create an issue

    https://github.com/apache/pulsar/issues