This method only accepts plain functions and makes it impossible to customize paths in runtime. Am I missing something? Looks like a completely unnecessary restriction, which forces me to go off-track just to find a workaround. Theoretically, I could use global variables if the paths were unconditional, but I need to choose them based on a runtime parameter. So I have to use TLS globals and create a separate custom thread for each TLS connection just to pass these paths to a callback indirectly via globals. Looks like a huge hack for such a simple task.