六、以zip方式部署流程

原创
2021/02/21 17:51
阅读数 272

一、压缩文件

将内容压缩

二、代码实现

        ProcessEngine engine = ProcessEngines.getDefaultProcessEngine();

        //根据当前类的路径获取到 资源文件内容
        InputStream inputStream = this.getClass()
                .getClassLoader()
                .getResourceAsStream("bpmn/evection.zip");
        ZipInputStream zipInputStream = new ZipInputStream(inputStream);

        RepositoryService repositoryService = engine.getRepositoryService();
        //使用压缩包进行流程部署
        repositoryService.createDeployment()
                .addZipInputStream(zipInputStream)
                .deploy();

展开阅读全文
加载中
点击引领话题📣 发布并加入讨论🔥
打赏
0 评论
0 收藏
0
分享
返回顶部
顶部