Class CursorManagementFunction

java.lang.Object
org.apache.pulsar.functions.api.examples.CursorManagementFunction
All Implemented Interfaces:
org.apache.pulsar.functions.api.Function<String,String>

public class CursorManagementFunction extends Object implements org.apache.pulsar.functions.api.Function<String,String>
A function that demonstrates how to use pulsar admin client exposed from Function Context. In this particular example, for every input message, the function do reset cursor of current function's subscription to a specified timestamp.
  • Constructor Details

    • CursorManagementFunction

      public CursorManagementFunction()
  • Method Details

    • process

      public String process(String input, org.apache.pulsar.functions.api.Context context) throws Exception
      Specified by:
      process in interface org.apache.pulsar.functions.api.Function<String,String>
      Throws:
      Exception