class CustLogAppenderInit implements ApplicationRunner{

    @Autowired
    private TaskFlowRecordAppender taskFlowRecordAppender;

    private final org.slf4j.Logger logger = LoggerFactory.getLogger(CustLogAppenderInit.class);

    @Override
    public void run(ApplicationArguments args) throws Exception {<FILL_FUNCTION_BODY>}
}

        logger.warn("custLogAppender init begin!");
        if (LoggerFactory.getILoggerFactory() instanceof LoggerContext) {
            LoggerContext loggerContext = (LoggerContext) LoggerFactory.getILoggerFactory();
            Logger rootLogger = loggerContext.getLogger(Logger.ROOT_LOGGER_NAME);
            //自定义任务流appender
            taskFlowRecordAppender.setContext(loggerContext);
            taskFlowRecordAppender.start();
            rootLogger.addAppender(taskFlowRecordAppender);
            logger.warn("custLogAppender init Done!");
        } else {
            logger.error("custLogAppender init failed , LoggerFactory.getILoggerFactory()={}",
                    LoggerFactory.getILoggerFactory());
        }
    
<no_super_class>