Added support for JSM context, untested