class SofaBizUninstallEventHandler implements EventHandler<BeforeBizStopEvent> {

    @Override
    public void handleEvent(BeforeBizStopEvent event) {
        doUninstallBiz(event.getSource());
    }

    private void doUninstallBiz(Biz biz) {<FILL_FUNCTION_BODY>}

    @Override
    public int getPriority() {
        return PriorityOrdered.DEFAULT_PRECEDENCE;
    }
}

        // Remove dynamic JVM service cache
        DynamicJvmServiceProxyFinder.getInstance().afterBizUninstall(biz);

        SofaRuntimeManager sofaRuntimeManager = SofaRuntimeContainer.getSofaRuntimeManager(biz
            .getBizClassLoader());

        if (sofaRuntimeManager == null) {
            throw new IllegalStateException("No SofaRuntimeManager match classLoader");
        }
        sofaRuntimeManager.shutDownExternally();
    
<no_super_class>