When a function is created using an isolated class loader it might want to use that class loader again for its invocations, and a lot of tools (Spring etc.) use the context class loader for that kind of thing if they don't have an explicit default value. So we set the context class loader before, and unset it after, the function invocation using a convenience wrapper.