ソースを参照

初始化项目

xueyiming 7 ヶ月 前
コミット
6630126db8
83 ファイル変更10012 行追加137 行削除
  1. 12 0
      long-article-server/pom.xml
  2. 2 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/LongArticleServerApplication.java
  3. 48 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/config/DataSourceConfig.java
  4. 31 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/generator/MybatisGeneratorMain.java
  5. 76 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/generator/PaginationPlugin.java
  6. 36 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/CrawlerVideoMapper.java
  7. 36 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/LongArticlesTextMapper.java
  8. 36 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/MatchVideoMapper.java
  9. 30 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/OffVideoMapper.java
  10. 30 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/RootSourceMapper.java
  11. 48 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/LongArticleSystemPlan.java
  12. 17 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/LongArticleSystemPlanAccount.java
  13. 23 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/MiniprogramCard.java
  14. 27 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/MiniprogramCardQueryResultData.java
  15. 31 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/PlanAccount.java
  16. 23 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/VideoDetail.java
  17. 21 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/ArticleSortRequest.java
  18. 18 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/ArticleSortResponse.java
  19. 15 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/ArticleSortResponseData.java
  20. 19 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/MiniprogramCardRequest.java
  21. 20 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/PublishArticleData.java
  22. 224 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/CrawlerVideo.java
  23. 1312 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/CrawlerVideoExample.java
  24. 90 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/LongArticlesText.java
  25. 621 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/LongArticlesTextExample.java
  26. 158 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/MatchVideo.java
  27. 982 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/MatchVideoExample.java
  28. 79 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/OffVideo.java
  29. 581 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/OffVideoExample.java
  30. 123 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/RootSource.java
  31. 881 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/RootSourceExample.java
  32. 15 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/ArticleSortParam.java
  33. 12 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/FilterSortParam.java
  34. 12 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/GzhArticleSortTaskParam.java
  35. 21 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemContentItemVO.java
  36. 18 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemContentVO.java
  37. 23 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemCreatePushTaskParam.java
  38. 16 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemFilterSortContentParam.java
  39. 18 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemGetContentsParam.java
  40. 17 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemPushContentParam.java
  41. 16 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/MatchVideoVo.java
  42. 22 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/MiniprogramInsertTaskParam.java
  43. 16 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/ProduceAuditLayoutContentObjVO.java
  44. 33 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/PublishMiniprogram.java
  45. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/CardService.java
  46. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/ContentService.java
  47. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/CoreService.java
  48. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/CoverService.java
  49. 10 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/KimiService.java
  50. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/MatchVideoService.java
  51. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/PlanService.java
  52. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/PublishService.java
  53. 4 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/SortService.java
  54. 155 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/CardServiceImpl.java
  55. 92 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/ContentServiceImpl.java
  56. 208 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/CoreServiceImpl.java
  57. 37 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/CoverServiceImpl.java
  58. 47 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/KimiServiceImpl.java
  59. 255 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/MatchVideoServiceImpl.java
  60. 117 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/PlanServiceImpl.java
  61. 97 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/PublishServiceImpl.java
  62. 47 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/SortServiceImpl.java
  63. 44 45
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/DouyinSearch.java
  64. 1 1
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/GetContentUtil.java
  65. 55 91
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/HkspSearch.java
  66. 90 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/HttpClientUtil.java
  67. 193 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/HttpPoolClientUtil.java
  68. 37 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/OSSUploader.java
  69. 55 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/SortUtil.java
  70. 219 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/TimeZoneUtil.java
  71. 161 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/VideoDownloader.java
  72. 207 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/XiGuaUtils.java
  73. 108 0
      long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/page/Page.java
  74. 8 0
      long-article-server/src/main/resources/application-test.properties
  75. 27 0
      long-article-server/src/main/resources/application.properties
  76. 505 0
      long-article-server/src/main/resources/mapper/CrawlerVideoMapper.xml
  77. 293 0
      long-article-server/src/main/resources/mapper/LongArticlesTextMapper.xml
  78. 400 0
      long-article-server/src/main/resources/mapper/MatchVideoMapper.xml
  79. 231 0
      long-article-server/src/main/resources/mapper/OffVideoMapper.xml
  80. 294 0
      long-article-server/src/main/resources/mapper/RootSourceMapper.xml
  81. 13 0
      long-article-server/src/main/resources/mybatis-config.xml
  82. 67 0
      long-article-server/src/main/resources/mybatis-generator-config.xml
  83. 18 0
      pom.xml

+ 12 - 0
long-article-server/pom.xml

@@ -9,4 +9,16 @@
     <artifactId>long-article-server</artifactId>
     <name>long-article-server</name>
     <url>http://maven.apache.org</url>
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-compiler-plugin</artifactId>
+                <configuration>
+                    <source>10</source>
+                    <target>10</target>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
 </project>

+ 2 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/LongArticleServerApplication.java

@@ -1,8 +1,10 @@
 package com.tzld.piaoquan.longarticle;
 
+import com.ctrip.framework.apollo.spring.annotation.EnableApolloConfig;
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
 
+@EnableApolloConfig
 @SpringBootApplication
 public class LongArticleServerApplication {
 

+ 48 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/config/DataSourceConfig.java

@@ -0,0 +1,48 @@
+package com.tzld.piaoquan.longarticle.config;
+
+import com.alibaba.druid.pool.DruidDataSource;
+import org.apache.ibatis.session.SqlSessionFactory;
+import org.mybatis.spring.SqlSessionFactoryBean;
+import org.mybatis.spring.annotation.MapperScan;
+import org.springframework.beans.factory.annotation.Qualifier;
+import org.springframework.boot.context.properties.ConfigurationProperties;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
+import org.springframework.context.annotation.Primary;
+import org.springframework.core.io.support.PathMatchingResourcePatternResolver;
+import org.springframework.jdbc.datasource.DataSourceTransactionManager;
+import org.springframework.transaction.PlatformTransactionManager;
+
+import javax.sql.DataSource;
+
+
+@Configuration
+@MapperScan(basePackages = DataSourceConfig.PACKAGE_MASTER, sqlSessionFactoryRef = "masterSqlSessionFactory")
+public class DataSourceConfig {
+    // 数据源
+    static final String PACKAGE_MASTER = "com.tzld.piaoquan.longarticle.dao";
+    static final String MAPPER_LOCATION_MASTER = "classpath:mapper/*.xml";
+
+    @Bean(name = "dataSource")
+    @ConfigurationProperties("spring.datasource")
+    public DataSource getDataSource(){
+        return new DruidDataSource();
+    }
+
+    @Primary
+    @Bean(name = "masterTransactionManager")
+    public PlatformTransactionManager masterTransactionManager(@Qualifier("dataSource") DataSource dataSource) {
+        return new DataSourceTransactionManager(dataSource);
+    }
+
+    @Primary
+    @Bean(name = "masterSqlSessionFactory")
+    public SqlSessionFactory masterSqlSessionFactory(@Qualifier("dataSource") DataSource dataSource) throws Exception {
+        final SqlSessionFactoryBean sessionFactoryBean = new SqlSessionFactoryBean();
+        sessionFactoryBean.setDataSource(dataSource);
+        sessionFactoryBean.setMapperLocations(new PathMatchingResourcePatternResolver().getResources(DataSourceConfig.MAPPER_LOCATION_MASTER));
+        return sessionFactoryBean.getObject();
+    }
+
+
+}

+ 31 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/generator/MybatisGeneratorMain.java

@@ -0,0 +1,31 @@
+package com.tzld.piaoquan.longarticle.dao.generator;
+
+import org.mybatis.generator.api.MyBatisGenerator;
+import org.mybatis.generator.config.Configuration;
+import org.mybatis.generator.config.xml.ConfigurationParser;
+import org.mybatis.generator.exception.InvalidConfigurationException;
+import org.mybatis.generator.exception.XMLParserException;
+import org.mybatis.generator.internal.DefaultShellCallback;
+
+import java.io.File;
+import java.io.IOException;
+import java.sql.SQLException;
+import java.util.ArrayList;
+import java.util.List;
+
+
+public class MybatisGeneratorMain {
+
+    public static void main(String[] args)
+            throws SQLException, IOException, InterruptedException, InvalidConfigurationException, XMLParserException {
+        List<String> warnings = new ArrayList<>();
+
+        File configFile = new File(MybatisGeneratorMain.class.getResource("/mybatis-generator-config.xml").getFile());
+        ConfigurationParser cp = new ConfigurationParser(warnings);
+        Configuration config = cp.parseConfiguration(configFile);
+        DefaultShellCallback callback = new DefaultShellCallback(true);
+        MyBatisGenerator myBatisGenerator = new MyBatisGenerator(config, callback, warnings);
+        myBatisGenerator.generate(null);
+        System.out.println("genreate finish");
+    }
+}

+ 76 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/generator/PaginationPlugin.java

@@ -0,0 +1,76 @@
+package com.tzld.piaoquan.longarticle.dao.generator;
+
+import org.mybatis.generator.api.CommentGenerator;
+import org.mybatis.generator.api.IntrospectedTable;
+import org.mybatis.generator.api.PluginAdapter;
+import org.mybatis.generator.api.dom.java.*;
+import org.mybatis.generator.api.dom.xml.Attribute;
+import org.mybatis.generator.api.dom.xml.TextElement;
+import org.mybatis.generator.api.dom.xml.XmlElement;
+
+import java.util.List;
+
+public class PaginationPlugin extends PluginAdapter {
+
+    @Override
+    public boolean modelExampleClassGenerated(TopLevelClass topLevelClass, IntrospectedTable introspectedTable) {
+        addPage(topLevelClass, introspectedTable, "page");
+        return super.modelExampleClassGenerated(topLevelClass, introspectedTable);
+    }
+
+    @Override
+    public boolean sqlMapSelectByExampleWithoutBLOBsElementGenerated(XmlElement element, IntrospectedTable introspectedTable) {
+        XmlElement page = new XmlElement("if");
+        page.addAttribute(new Attribute("test", "page != null"));
+        page.addElement(new TextElement("limit #{page.offset} , #{page.pageSize}"));
+        element.addElement(page);
+        return super.sqlMapUpdateByExampleWithoutBLOBsElementGenerated(element, introspectedTable);
+    }
+
+    @Override
+    public boolean sqlMapSelectByExampleWithBLOBsElementGenerated(XmlElement element, IntrospectedTable introspectedTable) {
+        XmlElement page = new XmlElement("if");
+        page.addAttribute(new Attribute("test", "page != null"));
+        page.addElement(new TextElement("limit #{page.offset} , #{page.pageSize}"));
+        element.addElement(page);
+        return super.sqlMapSelectByExampleWithBLOBsElementGenerated(element, introspectedTable);
+    }
+
+    /**
+     * @param topLevelClass
+     * @param introspectedTable
+     * @param name
+     */
+    private void addPage(TopLevelClass topLevelClass, IntrospectedTable introspectedTable, String name) {
+        topLevelClass.addImportedType(new FullyQualifiedJavaType("com.tzld.piaoquan.longarticle.utils.page.Page"));
+        CommentGenerator commentGenerator = context.getCommentGenerator();
+        Field field = new Field();
+        field.setVisibility(JavaVisibility.PROTECTED);
+        field.setType(new FullyQualifiedJavaType("com.tzld.piaoquan.longarticle.utils.page.Page"));
+        field.setName(name);
+        commentGenerator.addFieldComment(field, introspectedTable);
+        topLevelClass.addField(field);
+        char c = name.charAt(0);
+        String camel = Character.toUpperCase(c) + name.substring(1);
+        Method method = new Method();
+        method.setVisibility(JavaVisibility.PUBLIC);
+        method.setName("set" + camel);
+        method.addParameter(new Parameter(new FullyQualifiedJavaType("com.tzld.piaoquan.longarticle.utils.page.Page"), name));
+        method.addBodyLine("this." + name + "=" + name + ";");
+        commentGenerator.addGeneralMethodComment(method, introspectedTable);
+        topLevelClass.addMethod(method);
+        method = new Method();
+        method.setVisibility(JavaVisibility.PUBLIC);
+        method.setReturnType(new FullyQualifiedJavaType("com.tzld.piaoquan.longarticle.utils.page.Page"));
+        method.setName("get" + camel);
+        method.addBodyLine("return " + name + ";");
+        commentGenerator.addGeneralMethodComment(method, introspectedTable);
+        topLevelClass.addMethod(method);
+    }
+
+    @Override
+    public boolean validate(List<String> arg0) {
+        return true;
+    }
+
+}

+ 36 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/CrawlerVideoMapper.java

@@ -0,0 +1,36 @@
+package com.tzld.piaoquan.longarticle.dao.mapper;
+
+import com.tzld.piaoquan.longarticle.model.po.CrawlerVideo;
+import com.tzld.piaoquan.longarticle.model.po.CrawlerVideoExample;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface CrawlerVideoMapper {
+    long countByExample(CrawlerVideoExample example);
+
+    int deleteByExample(CrawlerVideoExample example);
+
+    int deleteByPrimaryKey(Integer id);
+
+    int insert(CrawlerVideo record);
+
+    int insertSelective(CrawlerVideo record);
+
+    List<CrawlerVideo> selectByExampleWithBLOBs(CrawlerVideoExample example);
+
+    List<CrawlerVideo> selectByExample(CrawlerVideoExample example);
+
+    CrawlerVideo selectByPrimaryKey(Integer id);
+
+    int updateByExampleSelective(@Param("record") CrawlerVideo record, @Param("example") CrawlerVideoExample example);
+
+    int updateByExampleWithBLOBs(@Param("record") CrawlerVideo record, @Param("example") CrawlerVideoExample example);
+
+    int updateByExample(@Param("record") CrawlerVideo record, @Param("example") CrawlerVideoExample example);
+
+    int updateByPrimaryKeySelective(CrawlerVideo record);
+
+    int updateByPrimaryKeyWithBLOBs(CrawlerVideo record);
+
+    int updateByPrimaryKey(CrawlerVideo record);
+}

+ 36 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/LongArticlesTextMapper.java

@@ -0,0 +1,36 @@
+package com.tzld.piaoquan.longarticle.dao.mapper;
+
+import com.tzld.piaoquan.longarticle.model.po.LongArticlesText;
+import com.tzld.piaoquan.longarticle.model.po.LongArticlesTextExample;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface LongArticlesTextMapper {
+    long countByExample(LongArticlesTextExample example);
+
+    int deleteByExample(LongArticlesTextExample example);
+
+    int deleteByPrimaryKey(String contentId);
+
+    int insert(LongArticlesText record);
+
+    int insertSelective(LongArticlesText record);
+
+    List<LongArticlesText> selectByExampleWithBLOBs(LongArticlesTextExample example);
+
+    List<LongArticlesText> selectByExample(LongArticlesTextExample example);
+
+    LongArticlesText selectByPrimaryKey(String contentId);
+
+    int updateByExampleSelective(@Param("record") LongArticlesText record, @Param("example") LongArticlesTextExample example);
+
+    int updateByExampleWithBLOBs(@Param("record") LongArticlesText record, @Param("example") LongArticlesTextExample example);
+
+    int updateByExample(@Param("record") LongArticlesText record, @Param("example") LongArticlesTextExample example);
+
+    int updateByPrimaryKeySelective(LongArticlesText record);
+
+    int updateByPrimaryKeyWithBLOBs(LongArticlesText record);
+
+    int updateByPrimaryKey(LongArticlesText record);
+}

+ 36 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/MatchVideoMapper.java

@@ -0,0 +1,36 @@
+package com.tzld.piaoquan.longarticle.dao.mapper;
+
+import com.tzld.piaoquan.longarticle.model.po.MatchVideo;
+import com.tzld.piaoquan.longarticle.model.po.MatchVideoExample;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface MatchVideoMapper {
+    long countByExample(MatchVideoExample example);
+
+    int deleteByExample(MatchVideoExample example);
+
+    int deleteByPrimaryKey(Integer id);
+
+    int insert(MatchVideo record);
+
+    int insertSelective(MatchVideo record);
+
+    List<MatchVideo> selectByExampleWithBLOBs(MatchVideoExample example);
+
+    List<MatchVideo> selectByExample(MatchVideoExample example);
+
+    MatchVideo selectByPrimaryKey(Integer id);
+
+    int updateByExampleSelective(@Param("record") MatchVideo record, @Param("example") MatchVideoExample example);
+
+    int updateByExampleWithBLOBs(@Param("record") MatchVideo record, @Param("example") MatchVideoExample example);
+
+    int updateByExample(@Param("record") MatchVideo record, @Param("example") MatchVideoExample example);
+
+    int updateByPrimaryKeySelective(MatchVideo record);
+
+    int updateByPrimaryKeyWithBLOBs(MatchVideo record);
+
+    int updateByPrimaryKey(MatchVideo record);
+}

+ 30 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/OffVideoMapper.java

@@ -0,0 +1,30 @@
+package com.tzld.piaoquan.longarticle.dao.mapper;
+
+import com.tzld.piaoquan.longarticle.model.po.OffVideo;
+import com.tzld.piaoquan.longarticle.model.po.OffVideoExample;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface OffVideoMapper {
+    long countByExample(OffVideoExample example);
+
+    int deleteByExample(OffVideoExample example);
+
+    int deleteByPrimaryKey(Long videoId);
+
+    int insert(OffVideo record);
+
+    int insertSelective(OffVideo record);
+
+    List<OffVideo> selectByExample(OffVideoExample example);
+
+    OffVideo selectByPrimaryKey(Long videoId);
+
+    int updateByExampleSelective(@Param("record") OffVideo record, @Param("example") OffVideoExample example);
+
+    int updateByExample(@Param("record") OffVideo record, @Param("example") OffVideoExample example);
+
+    int updateByPrimaryKeySelective(OffVideo record);
+
+    int updateByPrimaryKey(OffVideo record);
+}

+ 30 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/dao/mapper/RootSourceMapper.java

@@ -0,0 +1,30 @@
+package com.tzld.piaoquan.longarticle.dao.mapper;
+
+import com.tzld.piaoquan.longarticle.model.po.RootSource;
+import com.tzld.piaoquan.longarticle.model.po.RootSourceExample;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface RootSourceMapper {
+    long countByExample(RootSourceExample example);
+
+    int deleteByExample(RootSourceExample example);
+
+    int deleteByPrimaryKey(String rootSourceId);
+
+    int insert(RootSource record);
+
+    int insertSelective(RootSource record);
+
+    List<RootSource> selectByExample(RootSourceExample example);
+
+    RootSource selectByPrimaryKey(String rootSourceId);
+
+    int updateByExampleSelective(@Param("record") RootSource record, @Param("example") RootSourceExample example);
+
+    int updateByExample(@Param("record") RootSource record, @Param("example") RootSourceExample example);
+
+    int updateByPrimaryKeySelective(RootSource record);
+
+    int updateByPrimaryKey(RootSource record);
+}

+ 48 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/LongArticleSystemPlan.java

@@ -0,0 +1,48 @@
+package com.tzld.piaoquan.longarticle.model.bo;
+
+import com.tzld.piaoquan.longarticle.model.vo.GzhArticleSortTaskParam;
+import com.tzld.piaoquan.longarticle.model.vo.MiniprogramInsertTaskParam;
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+import java.util.List;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class LongArticleSystemPlan {
+
+    //"计划ID")
+    private String id;
+    //"计划名称")
+    private String name;
+    //"操作账号")
+    private List<LongArticleSystemPlanAccount> accountList;
+    //"发布频率(0-每天,1-固定日期)")
+    private Integer publishRate;
+    //"发布频率固定-发布日期 星期 数组[1,2,3,4,5,6,7]")
+    private String publishDate;
+    //"发布窗口时间-开始时间")
+    private String publishWindowStart;
+    //"发布频率固定-结束时间")
+    private String publishWindowEnd;
+    //"发布时间间隔(单位:分钟)")
+    private Integer publishTimeInterval;
+    //"发布数量")
+    private Integer publishNum;
+    //"每次发布数量(公众号每次推送文章数量)")
+    private Integer publishPerNum;
+    //"每次最少发布数量(公众号每次最少推送文章数量)")
+    private Integer publishPerMinNum;
+    //"公众号-推送时间")
+    private String publishPushTime;
+    //"推送方式(公众号),1-手动推送;2-自动群发;3-自动发表;4-自动发布;5-分组群发;6-触发推送")
+    private Integer pushType;
+    //"小程序插入开关(0-关闭 1-打开)")
+    private Integer miniprogramInsertFlag;
+    //"小程序插入任务")
+    private List<MiniprogramInsertTaskParam> miniprogramInsertTasks;
+    //"公众号文章排序任务")
+    private List<GzhArticleSortTaskParam> gzhArticleSortTask;
+}

+ 17 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/LongArticleSystemPlanAccount.java

@@ -0,0 +1,17 @@
+package com.tzld.piaoquan.longarticle.model.bo;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class LongArticleSystemPlanAccount {
+    //"账号ID")
+    private String id;
+    //"账号名称")
+    private String name;
+    //"公众号ID")
+    private String gzhId;
+}

+ 23 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/MiniprogramCard.java

@@ -0,0 +1,23 @@
+package com.tzld.piaoquan.longarticle.model.bo;
+
+import lombok.Data;
+
+import java.math.BigDecimal;
+
+@Data
+public class MiniprogramCard {
+
+    private String productionCover;
+    private String productionName;
+    private String productionPath;
+    private String programAvatar;
+    private String programId;
+    private String programName;
+    private String rootShareId;
+    private String source;
+    private String videoUrl;
+    private BigDecimal paragraphPosition;
+    private Integer mini_id;
+    private String traceId;
+    private Integer miniprogramUseType;
+}

+ 27 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/MiniprogramCardQueryResultData.java

@@ -0,0 +1,27 @@
+package com.tzld.piaoquan.longarticle.model.bo;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+import java.math.BigDecimal;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class MiniprogramCardQueryResultData {
+    private String productionCover;
+    private String productionName;
+    private String productionPath;
+    private String programAvatar;
+    private String programId;
+    private String programName;
+    private String rootShareId;
+    private String source;
+    private String videoUrl;
+    private BigDecimal paragraphPosition;
+    private Integer mini_id;
+    private String traceId;
+    private Integer miniprogramUseType;
+
+}

+ 31 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/PlanAccount.java

@@ -0,0 +1,31 @@
+package com.tzld.piaoquan.longarticle.model.bo;
+
+import lombok.Data;
+
+@Data
+public class PlanAccount {
+    //计划id
+    private String planId;
+    //计划名称
+    private String planName;
+    //账号id
+    private String accountId;
+    //账号名称
+    private String accountName;
+    //公众号ID
+    private String gzhId;
+    //每次发布数量
+    private Integer publishNum;
+    //每次最少发布数量
+    private Integer publishPerMinNum;
+    //推送时间
+    private String publishPushTime;
+    //小程序插入策略
+    private String miniStrategy;
+    //小程序用途,1-自然流,2-投流
+    private Integer miniprogramUseType;
+    //排序策略
+    private String sortStrategy;
+    //推送策略
+    private Integer pushType;
+}

+ 23 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/bo/VideoDetail.java

@@ -0,0 +1,23 @@
+package com.tzld.piaoquan.longarticle.model.bo;
+
+import lombok.Data;
+
+@Data
+public class VideoDetail {
+
+    private String uid;
+
+    private String source;
+
+    private String kimiTitle;
+
+    private String videoId;
+
+    private String videoCover;
+
+    private String videoPath;
+
+    private String videoOss;
+
+    private String traceId;
+}

+ 21 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/ArticleSortRequest.java

@@ -0,0 +1,21 @@
+package com.tzld.piaoquan.longarticle.model.dto;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+import java.util.List;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class ArticleSortRequest {
+    private String accountId;
+    private String accountName;
+    private String ghId;
+    private String strategy;
+    private Integer publishNum;
+    private String planId;
+    private Integer pushType;
+    private List<PublishArticleData> publishArticleList;
+}

+ 18 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/ArticleSortResponse.java

@@ -0,0 +1,18 @@
+package com.tzld.piaoquan.longarticle.model.dto;
+
+import lombok.Data;
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class ArticleSortResponse {
+
+    private boolean isSuccessful;
+    private Integer code;
+    private String msg;
+    private String status;
+    private ArticleSortResponseData data;
+}

+ 15 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/ArticleSortResponseData.java

@@ -0,0 +1,15 @@
+package com.tzld.piaoquan.longarticle.model.dto;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+import java.util.List;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class ArticleSortResponseData {
+    private List<PublishArticleData> rank_list;
+    private List<PublishArticleData> filter_list;
+}

+ 19 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/MiniprogramCardRequest.java

@@ -0,0 +1,19 @@
+package com.tzld.piaoquan.longarticle.model.dto;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class MiniprogramCardRequest {
+    private String ghId;
+    private String accountName;
+    private String content;
+    private String title;
+    private String cover;
+    private String strategy;
+    private String articleId;
+    private String flowPoolLevelTag;
+}

+ 20 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/dto/PublishArticleData.java

@@ -0,0 +1,20 @@
+package com.tzld.piaoquan.longarticle.model.dto;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+import java.util.List;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class PublishArticleData {
+    private String id;
+    private String sourceId;
+    private String title;
+    private String producePlanName;
+    private String filterReason;
+    private Double score;
+    private String contentPoolType;
+}

+ 224 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/CrawlerVideo.java

@@ -0,0 +1,224 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+import java.util.Date;
+
+public class CrawlerVideo {
+    private Integer id;
+
+    private String contentId;
+
+    private String outVideoId;
+
+    private String platform;
+
+    private String videoTitle;
+
+    private Integer playCount;
+
+    private Integer likeCount;
+
+    private Integer shareCount;
+
+    private Date publishTime;
+
+    private Date crawlerTime;
+
+    private Integer duration;
+
+    private Integer downloadStatus;
+
+    private String videoOssPath;
+
+    private String coverOssPath;
+
+    private String userId;
+
+    private String traceId;
+
+    private Float score;
+
+    private String videoUrl;
+
+    private String coverUrl;
+
+    public Integer getId() {
+        return id;
+    }
+
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    public String getContentId() {
+        return contentId;
+    }
+
+    public void setContentId(String contentId) {
+        this.contentId = contentId;
+    }
+
+    public String getOutVideoId() {
+        return outVideoId;
+    }
+
+    public void setOutVideoId(String outVideoId) {
+        this.outVideoId = outVideoId;
+    }
+
+    public String getPlatform() {
+        return platform;
+    }
+
+    public void setPlatform(String platform) {
+        this.platform = platform;
+    }
+
+    public String getVideoTitle() {
+        return videoTitle;
+    }
+
+    public void setVideoTitle(String videoTitle) {
+        this.videoTitle = videoTitle;
+    }
+
+    public Integer getPlayCount() {
+        return playCount;
+    }
+
+    public void setPlayCount(Integer playCount) {
+        this.playCount = playCount;
+    }
+
+    public Integer getLikeCount() {
+        return likeCount;
+    }
+
+    public void setLikeCount(Integer likeCount) {
+        this.likeCount = likeCount;
+    }
+
+    public Integer getShareCount() {
+        return shareCount;
+    }
+
+    public void setShareCount(Integer shareCount) {
+        this.shareCount = shareCount;
+    }
+
+    public Date getPublishTime() {
+        return publishTime;
+    }
+
+    public void setPublishTime(Date publishTime) {
+        this.publishTime = publishTime;
+    }
+
+    public Date getCrawlerTime() {
+        return crawlerTime;
+    }
+
+    public void setCrawlerTime(Date crawlerTime) {
+        this.crawlerTime = crawlerTime;
+    }
+
+    public Integer getDuration() {
+        return duration;
+    }
+
+    public void setDuration(Integer duration) {
+        this.duration = duration;
+    }
+
+    public Integer getDownloadStatus() {
+        return downloadStatus;
+    }
+
+    public void setDownloadStatus(Integer downloadStatus) {
+        this.downloadStatus = downloadStatus;
+    }
+
+    public String getVideoOssPath() {
+        return videoOssPath;
+    }
+
+    public void setVideoOssPath(String videoOssPath) {
+        this.videoOssPath = videoOssPath;
+    }
+
+    public String getCoverOssPath() {
+        return coverOssPath;
+    }
+
+    public void setCoverOssPath(String coverOssPath) {
+        this.coverOssPath = coverOssPath;
+    }
+
+    public String getUserId() {
+        return userId;
+    }
+
+    public void setUserId(String userId) {
+        this.userId = userId;
+    }
+
+    public String getTraceId() {
+        return traceId;
+    }
+
+    public void setTraceId(String traceId) {
+        this.traceId = traceId;
+    }
+
+    public Float getScore() {
+        return score;
+    }
+
+    public void setScore(Float score) {
+        this.score = score;
+    }
+
+    public String getVideoUrl() {
+        return videoUrl;
+    }
+
+    public void setVideoUrl(String videoUrl) {
+        this.videoUrl = videoUrl;
+    }
+
+    public String getCoverUrl() {
+        return coverUrl;
+    }
+
+    public void setCoverUrl(String coverUrl) {
+        this.coverUrl = coverUrl;
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", id=").append(id);
+        sb.append(", contentId=").append(contentId);
+        sb.append(", outVideoId=").append(outVideoId);
+        sb.append(", platform=").append(platform);
+        sb.append(", videoTitle=").append(videoTitle);
+        sb.append(", playCount=").append(playCount);
+        sb.append(", likeCount=").append(likeCount);
+        sb.append(", shareCount=").append(shareCount);
+        sb.append(", publishTime=").append(publishTime);
+        sb.append(", crawlerTime=").append(crawlerTime);
+        sb.append(", duration=").append(duration);
+        sb.append(", downloadStatus=").append(downloadStatus);
+        sb.append(", videoOssPath=").append(videoOssPath);
+        sb.append(", coverOssPath=").append(coverOssPath);
+        sb.append(", userId=").append(userId);
+        sb.append(", traceId=").append(traceId);
+        sb.append(", score=").append(score);
+        sb.append(", videoUrl=").append(videoUrl);
+        sb.append(", coverUrl=").append(coverUrl);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 1312 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/CrawlerVideoExample.java

@@ -0,0 +1,1312 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+import com.tzld.piaoquan.longarticle.utils.page.Page;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+public class CrawlerVideoExample {
+    protected String orderByClause;
+
+    protected boolean distinct;
+
+    protected List<Criteria> oredCriteria;
+
+    protected Page page;
+
+    public CrawlerVideoExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    public void setPage(Page page) {
+        this.page=page;
+    }
+
+    public Page getPage() {
+        return page;
+    }
+
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andIdIsNull() {
+            addCriterion("id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIsNotNull() {
+            addCriterion("id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdEqualTo(Integer value) {
+            addCriterion("id =", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotEqualTo(Integer value) {
+            addCriterion("id <>", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThan(Integer value) {
+            addCriterion("id >", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
+            addCriterion("id >=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThan(Integer value) {
+            addCriterion("id <", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThanOrEqualTo(Integer value) {
+            addCriterion("id <=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIn(List<Integer> values) {
+            addCriterion("id in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotIn(List<Integer> values) {
+            addCriterion("id not in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdBetween(Integer value1, Integer value2) {
+            addCriterion("id between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotBetween(Integer value1, Integer value2) {
+            addCriterion("id not between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIsNull() {
+            addCriterion("content_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIsNotNull() {
+            addCriterion("content_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdEqualTo(String value) {
+            addCriterion("content_id =", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotEqualTo(String value) {
+            addCriterion("content_id <>", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThan(String value) {
+            addCriterion("content_id >", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThanOrEqualTo(String value) {
+            addCriterion("content_id >=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThan(String value) {
+            addCriterion("content_id <", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThanOrEqualTo(String value) {
+            addCriterion("content_id <=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLike(String value) {
+            addCriterion("content_id like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotLike(String value) {
+            addCriterion("content_id not like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIn(List<String> values) {
+            addCriterion("content_id in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotIn(List<String> values) {
+            addCriterion("content_id not in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdBetween(String value1, String value2) {
+            addCriterion("content_id between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotBetween(String value1, String value2) {
+            addCriterion("content_id not between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdIsNull() {
+            addCriterion("out_video_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdIsNotNull() {
+            addCriterion("out_video_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdEqualTo(String value) {
+            addCriterion("out_video_id =", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdNotEqualTo(String value) {
+            addCriterion("out_video_id <>", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdGreaterThan(String value) {
+            addCriterion("out_video_id >", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdGreaterThanOrEqualTo(String value) {
+            addCriterion("out_video_id >=", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdLessThan(String value) {
+            addCriterion("out_video_id <", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdLessThanOrEqualTo(String value) {
+            addCriterion("out_video_id <=", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdLike(String value) {
+            addCriterion("out_video_id like", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdNotLike(String value) {
+            addCriterion("out_video_id not like", value, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdIn(List<String> values) {
+            addCriterion("out_video_id in", values, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdNotIn(List<String> values) {
+            addCriterion("out_video_id not in", values, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdBetween(String value1, String value2) {
+            addCriterion("out_video_id between", value1, value2, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOutVideoIdNotBetween(String value1, String value2) {
+            addCriterion("out_video_id not between", value1, value2, "outVideoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformIsNull() {
+            addCriterion("platform is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformIsNotNull() {
+            addCriterion("platform is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformEqualTo(String value) {
+            addCriterion("platform =", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformNotEqualTo(String value) {
+            addCriterion("platform <>", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformGreaterThan(String value) {
+            addCriterion("platform >", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformGreaterThanOrEqualTo(String value) {
+            addCriterion("platform >=", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformLessThan(String value) {
+            addCriterion("platform <", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformLessThanOrEqualTo(String value) {
+            addCriterion("platform <=", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformLike(String value) {
+            addCriterion("platform like", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformNotLike(String value) {
+            addCriterion("platform not like", value, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformIn(List<String> values) {
+            addCriterion("platform in", values, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformNotIn(List<String> values) {
+            addCriterion("platform not in", values, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformBetween(String value1, String value2) {
+            addCriterion("platform between", value1, value2, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlatformNotBetween(String value1, String value2) {
+            addCriterion("platform not between", value1, value2, "platform");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleIsNull() {
+            addCriterion("video_title is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleIsNotNull() {
+            addCriterion("video_title is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleEqualTo(String value) {
+            addCriterion("video_title =", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleNotEqualTo(String value) {
+            addCriterion("video_title <>", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleGreaterThan(String value) {
+            addCriterion("video_title >", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleGreaterThanOrEqualTo(String value) {
+            addCriterion("video_title >=", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleLessThan(String value) {
+            addCriterion("video_title <", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleLessThanOrEqualTo(String value) {
+            addCriterion("video_title <=", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleLike(String value) {
+            addCriterion("video_title like", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleNotLike(String value) {
+            addCriterion("video_title not like", value, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleIn(List<String> values) {
+            addCriterion("video_title in", values, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleNotIn(List<String> values) {
+            addCriterion("video_title not in", values, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleBetween(String value1, String value2) {
+            addCriterion("video_title between", value1, value2, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoTitleNotBetween(String value1, String value2) {
+            addCriterion("video_title not between", value1, value2, "videoTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountIsNull() {
+            addCriterion("play_count is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountIsNotNull() {
+            addCriterion("play_count is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountEqualTo(Integer value) {
+            addCriterion("play_count =", value, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountNotEqualTo(Integer value) {
+            addCriterion("play_count <>", value, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountGreaterThan(Integer value) {
+            addCriterion("play_count >", value, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountGreaterThanOrEqualTo(Integer value) {
+            addCriterion("play_count >=", value, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountLessThan(Integer value) {
+            addCriterion("play_count <", value, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountLessThanOrEqualTo(Integer value) {
+            addCriterion("play_count <=", value, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountIn(List<Integer> values) {
+            addCriterion("play_count in", values, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountNotIn(List<Integer> values) {
+            addCriterion("play_count not in", values, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountBetween(Integer value1, Integer value2) {
+            addCriterion("play_count between", value1, value2, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPlayCountNotBetween(Integer value1, Integer value2) {
+            addCriterion("play_count not between", value1, value2, "playCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountIsNull() {
+            addCriterion("like_count is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountIsNotNull() {
+            addCriterion("like_count is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountEqualTo(Integer value) {
+            addCriterion("like_count =", value, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountNotEqualTo(Integer value) {
+            addCriterion("like_count <>", value, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountGreaterThan(Integer value) {
+            addCriterion("like_count >", value, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountGreaterThanOrEqualTo(Integer value) {
+            addCriterion("like_count >=", value, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountLessThan(Integer value) {
+            addCriterion("like_count <", value, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountLessThanOrEqualTo(Integer value) {
+            addCriterion("like_count <=", value, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountIn(List<Integer> values) {
+            addCriterion("like_count in", values, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountNotIn(List<Integer> values) {
+            addCriterion("like_count not in", values, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountBetween(Integer value1, Integer value2) {
+            addCriterion("like_count between", value1, value2, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andLikeCountNotBetween(Integer value1, Integer value2) {
+            addCriterion("like_count not between", value1, value2, "likeCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountIsNull() {
+            addCriterion("share_count is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountIsNotNull() {
+            addCriterion("share_count is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountEqualTo(Integer value) {
+            addCriterion("share_count =", value, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountNotEqualTo(Integer value) {
+            addCriterion("share_count <>", value, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountGreaterThan(Integer value) {
+            addCriterion("share_count >", value, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountGreaterThanOrEqualTo(Integer value) {
+            addCriterion("share_count >=", value, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountLessThan(Integer value) {
+            addCriterion("share_count <", value, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountLessThanOrEqualTo(Integer value) {
+            addCriterion("share_count <=", value, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountIn(List<Integer> values) {
+            addCriterion("share_count in", values, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountNotIn(List<Integer> values) {
+            addCriterion("share_count not in", values, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountBetween(Integer value1, Integer value2) {
+            addCriterion("share_count between", value1, value2, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andShareCountNotBetween(Integer value1, Integer value2) {
+            addCriterion("share_count not between", value1, value2, "shareCount");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeIsNull() {
+            addCriterion("publish_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeIsNotNull() {
+            addCriterion("publish_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeEqualTo(Date value) {
+            addCriterion("publish_time =", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeNotEqualTo(Date value) {
+            addCriterion("publish_time <>", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeGreaterThan(Date value) {
+            addCriterion("publish_time >", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeGreaterThanOrEqualTo(Date value) {
+            addCriterion("publish_time >=", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeLessThan(Date value) {
+            addCriterion("publish_time <", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeLessThanOrEqualTo(Date value) {
+            addCriterion("publish_time <=", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeIn(List<Date> values) {
+            addCriterion("publish_time in", values, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeNotIn(List<Date> values) {
+            addCriterion("publish_time not in", values, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeBetween(Date value1, Date value2) {
+            addCriterion("publish_time between", value1, value2, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeNotBetween(Date value1, Date value2) {
+            addCriterion("publish_time not between", value1, value2, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeIsNull() {
+            addCriterion("crawler_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeIsNotNull() {
+            addCriterion("crawler_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeEqualTo(Date value) {
+            addCriterion("crawler_time =", value, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeNotEqualTo(Date value) {
+            addCriterion("crawler_time <>", value, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeGreaterThan(Date value) {
+            addCriterion("crawler_time >", value, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeGreaterThanOrEqualTo(Date value) {
+            addCriterion("crawler_time >=", value, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeLessThan(Date value) {
+            addCriterion("crawler_time <", value, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeLessThanOrEqualTo(Date value) {
+            addCriterion("crawler_time <=", value, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeIn(List<Date> values) {
+            addCriterion("crawler_time in", values, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeNotIn(List<Date> values) {
+            addCriterion("crawler_time not in", values, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeBetween(Date value1, Date value2) {
+            addCriterion("crawler_time between", value1, value2, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCrawlerTimeNotBetween(Date value1, Date value2) {
+            addCriterion("crawler_time not between", value1, value2, "crawlerTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationIsNull() {
+            addCriterion("duration is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationIsNotNull() {
+            addCriterion("duration is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationEqualTo(Integer value) {
+            addCriterion("duration =", value, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationNotEqualTo(Integer value) {
+            addCriterion("duration <>", value, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationGreaterThan(Integer value) {
+            addCriterion("duration >", value, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationGreaterThanOrEqualTo(Integer value) {
+            addCriterion("duration >=", value, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationLessThan(Integer value) {
+            addCriterion("duration <", value, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationLessThanOrEqualTo(Integer value) {
+            addCriterion("duration <=", value, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationIn(List<Integer> values) {
+            addCriterion("duration in", values, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationNotIn(List<Integer> values) {
+            addCriterion("duration not in", values, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationBetween(Integer value1, Integer value2) {
+            addCriterion("duration between", value1, value2, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDurationNotBetween(Integer value1, Integer value2) {
+            addCriterion("duration not between", value1, value2, "duration");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusIsNull() {
+            addCriterion("download_status is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusIsNotNull() {
+            addCriterion("download_status is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusEqualTo(Integer value) {
+            addCriterion("download_status =", value, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusNotEqualTo(Integer value) {
+            addCriterion("download_status <>", value, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusGreaterThan(Integer value) {
+            addCriterion("download_status >", value, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusGreaterThanOrEqualTo(Integer value) {
+            addCriterion("download_status >=", value, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusLessThan(Integer value) {
+            addCriterion("download_status <", value, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusLessThanOrEqualTo(Integer value) {
+            addCriterion("download_status <=", value, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusIn(List<Integer> values) {
+            addCriterion("download_status in", values, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusNotIn(List<Integer> values) {
+            addCriterion("download_status not in", values, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusBetween(Integer value1, Integer value2) {
+            addCriterion("download_status between", value1, value2, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andDownloadStatusNotBetween(Integer value1, Integer value2) {
+            addCriterion("download_status not between", value1, value2, "downloadStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathIsNull() {
+            addCriterion("video_oss_path is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathIsNotNull() {
+            addCriterion("video_oss_path is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathEqualTo(String value) {
+            addCriterion("video_oss_path =", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathNotEqualTo(String value) {
+            addCriterion("video_oss_path <>", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathGreaterThan(String value) {
+            addCriterion("video_oss_path >", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathGreaterThanOrEqualTo(String value) {
+            addCriterion("video_oss_path >=", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathLessThan(String value) {
+            addCriterion("video_oss_path <", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathLessThanOrEqualTo(String value) {
+            addCriterion("video_oss_path <=", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathLike(String value) {
+            addCriterion("video_oss_path like", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathNotLike(String value) {
+            addCriterion("video_oss_path not like", value, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathIn(List<String> values) {
+            addCriterion("video_oss_path in", values, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathNotIn(List<String> values) {
+            addCriterion("video_oss_path not in", values, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathBetween(String value1, String value2) {
+            addCriterion("video_oss_path between", value1, value2, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoOssPathNotBetween(String value1, String value2) {
+            addCriterion("video_oss_path not between", value1, value2, "videoOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathIsNull() {
+            addCriterion("cover_oss_path is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathIsNotNull() {
+            addCriterion("cover_oss_path is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathEqualTo(String value) {
+            addCriterion("cover_oss_path =", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathNotEqualTo(String value) {
+            addCriterion("cover_oss_path <>", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathGreaterThan(String value) {
+            addCriterion("cover_oss_path >", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathGreaterThanOrEqualTo(String value) {
+            addCriterion("cover_oss_path >=", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathLessThan(String value) {
+            addCriterion("cover_oss_path <", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathLessThanOrEqualTo(String value) {
+            addCriterion("cover_oss_path <=", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathLike(String value) {
+            addCriterion("cover_oss_path like", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathNotLike(String value) {
+            addCriterion("cover_oss_path not like", value, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathIn(List<String> values) {
+            addCriterion("cover_oss_path in", values, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathNotIn(List<String> values) {
+            addCriterion("cover_oss_path not in", values, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathBetween(String value1, String value2) {
+            addCriterion("cover_oss_path between", value1, value2, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andCoverOssPathNotBetween(String value1, String value2) {
+            addCriterion("cover_oss_path not between", value1, value2, "coverOssPath");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdIsNull() {
+            addCriterion("user_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdIsNotNull() {
+            addCriterion("user_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdEqualTo(String value) {
+            addCriterion("user_id =", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdNotEqualTo(String value) {
+            addCriterion("user_id <>", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdGreaterThan(String value) {
+            addCriterion("user_id >", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdGreaterThanOrEqualTo(String value) {
+            addCriterion("user_id >=", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdLessThan(String value) {
+            addCriterion("user_id <", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdLessThanOrEqualTo(String value) {
+            addCriterion("user_id <=", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdLike(String value) {
+            addCriterion("user_id like", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdNotLike(String value) {
+            addCriterion("user_id not like", value, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdIn(List<String> values) {
+            addCriterion("user_id in", values, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdNotIn(List<String> values) {
+            addCriterion("user_id not in", values, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdBetween(String value1, String value2) {
+            addCriterion("user_id between", value1, value2, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andUserIdNotBetween(String value1, String value2) {
+            addCriterion("user_id not between", value1, value2, "userId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNull() {
+            addCriterion("trace_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNotNull() {
+            addCriterion("trace_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdEqualTo(String value) {
+            addCriterion("trace_id =", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotEqualTo(String value) {
+            addCriterion("trace_id <>", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThan(String value) {
+            addCriterion("trace_id >", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThanOrEqualTo(String value) {
+            addCriterion("trace_id >=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThan(String value) {
+            addCriterion("trace_id <", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThanOrEqualTo(String value) {
+            addCriterion("trace_id <=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLike(String value) {
+            addCriterion("trace_id like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotLike(String value) {
+            addCriterion("trace_id not like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIn(List<String> values) {
+            addCriterion("trace_id in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotIn(List<String> values) {
+            addCriterion("trace_id not in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdBetween(String value1, String value2) {
+            addCriterion("trace_id between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotBetween(String value1, String value2) {
+            addCriterion("trace_id not between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreIsNull() {
+            addCriterion("score is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreIsNotNull() {
+            addCriterion("score is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreEqualTo(Float value) {
+            addCriterion("score =", value, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreNotEqualTo(Float value) {
+            addCriterion("score <>", value, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreGreaterThan(Float value) {
+            addCriterion("score >", value, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreGreaterThanOrEqualTo(Float value) {
+            addCriterion("score >=", value, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreLessThan(Float value) {
+            addCriterion("score <", value, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreLessThanOrEqualTo(Float value) {
+            addCriterion("score <=", value, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreIn(List<Float> values) {
+            addCriterion("score in", values, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreNotIn(List<Float> values) {
+            addCriterion("score not in", values, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreBetween(Float value1, Float value2) {
+            addCriterion("score between", value1, value2, "score");
+            return (Criteria) this;
+        }
+
+        public Criteria andScoreNotBetween(Float value1, Float value2) {
+            addCriterion("score not between", value1, value2, "score");
+            return (Criteria) this;
+        }
+    }
+
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}

+ 90 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/LongArticlesText.java

@@ -0,0 +1,90 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+public class LongArticlesText {
+    private String contentId;
+
+    private String articleTitle;
+
+    private String kimiTitle;
+
+    private String kimiSummary;
+
+    private String kimiKeys;
+
+    private Integer kimiStatus;
+
+    private String articleText;
+
+    public String getContentId() {
+        return contentId;
+    }
+
+    public void setContentId(String contentId) {
+        this.contentId = contentId;
+    }
+
+    public String getArticleTitle() {
+        return articleTitle;
+    }
+
+    public void setArticleTitle(String articleTitle) {
+        this.articleTitle = articleTitle;
+    }
+
+    public String getKimiTitle() {
+        return kimiTitle;
+    }
+
+    public void setKimiTitle(String kimiTitle) {
+        this.kimiTitle = kimiTitle;
+    }
+
+    public String getKimiSummary() {
+        return kimiSummary;
+    }
+
+    public void setKimiSummary(String kimiSummary) {
+        this.kimiSummary = kimiSummary;
+    }
+
+    public String getKimiKeys() {
+        return kimiKeys;
+    }
+
+    public void setKimiKeys(String kimiKeys) {
+        this.kimiKeys = kimiKeys;
+    }
+
+    public Integer getKimiStatus() {
+        return kimiStatus;
+    }
+
+    public void setKimiStatus(Integer kimiStatus) {
+        this.kimiStatus = kimiStatus;
+    }
+
+    public String getArticleText() {
+        return articleText;
+    }
+
+    public void setArticleText(String articleText) {
+        this.articleText = articleText;
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", contentId=").append(contentId);
+        sb.append(", articleTitle=").append(articleTitle);
+        sb.append(", kimiTitle=").append(kimiTitle);
+        sb.append(", kimiSummary=").append(kimiSummary);
+        sb.append(", kimiKeys=").append(kimiKeys);
+        sb.append(", kimiStatus=").append(kimiStatus);
+        sb.append(", articleText=").append(articleText);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 621 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/LongArticlesTextExample.java

@@ -0,0 +1,621 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+import com.tzld.piaoquan.longarticle.utils.page.Page;
+import java.util.ArrayList;
+import java.util.List;
+
+public class LongArticlesTextExample {
+    protected String orderByClause;
+
+    protected boolean distinct;
+
+    protected List<Criteria> oredCriteria;
+
+    protected Page page;
+
+    public LongArticlesTextExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    public void setPage(Page page) {
+        this.page=page;
+    }
+
+    public Page getPage() {
+        return page;
+    }
+
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andContentIdIsNull() {
+            addCriterion("content_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIsNotNull() {
+            addCriterion("content_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdEqualTo(String value) {
+            addCriterion("content_id =", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotEqualTo(String value) {
+            addCriterion("content_id <>", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThan(String value) {
+            addCriterion("content_id >", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThanOrEqualTo(String value) {
+            addCriterion("content_id >=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThan(String value) {
+            addCriterion("content_id <", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThanOrEqualTo(String value) {
+            addCriterion("content_id <=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLike(String value) {
+            addCriterion("content_id like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotLike(String value) {
+            addCriterion("content_id not like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIn(List<String> values) {
+            addCriterion("content_id in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotIn(List<String> values) {
+            addCriterion("content_id not in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdBetween(String value1, String value2) {
+            addCriterion("content_id between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotBetween(String value1, String value2) {
+            addCriterion("content_id not between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleIsNull() {
+            addCriterion("article_title is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleIsNotNull() {
+            addCriterion("article_title is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleEqualTo(String value) {
+            addCriterion("article_title =", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotEqualTo(String value) {
+            addCriterion("article_title <>", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleGreaterThan(String value) {
+            addCriterion("article_title >", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleGreaterThanOrEqualTo(String value) {
+            addCriterion("article_title >=", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleLessThan(String value) {
+            addCriterion("article_title <", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleLessThanOrEqualTo(String value) {
+            addCriterion("article_title <=", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleLike(String value) {
+            addCriterion("article_title like", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotLike(String value) {
+            addCriterion("article_title not like", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleIn(List<String> values) {
+            addCriterion("article_title in", values, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotIn(List<String> values) {
+            addCriterion("article_title not in", values, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleBetween(String value1, String value2) {
+            addCriterion("article_title between", value1, value2, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotBetween(String value1, String value2) {
+            addCriterion("article_title not between", value1, value2, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleIsNull() {
+            addCriterion("kimi_title is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleIsNotNull() {
+            addCriterion("kimi_title is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleEqualTo(String value) {
+            addCriterion("kimi_title =", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleNotEqualTo(String value) {
+            addCriterion("kimi_title <>", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleGreaterThan(String value) {
+            addCriterion("kimi_title >", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleGreaterThanOrEqualTo(String value) {
+            addCriterion("kimi_title >=", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleLessThan(String value) {
+            addCriterion("kimi_title <", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleLessThanOrEqualTo(String value) {
+            addCriterion("kimi_title <=", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleLike(String value) {
+            addCriterion("kimi_title like", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleNotLike(String value) {
+            addCriterion("kimi_title not like", value, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleIn(List<String> values) {
+            addCriterion("kimi_title in", values, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleNotIn(List<String> values) {
+            addCriterion("kimi_title not in", values, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleBetween(String value1, String value2) {
+            addCriterion("kimi_title between", value1, value2, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiTitleNotBetween(String value1, String value2) {
+            addCriterion("kimi_title not between", value1, value2, "kimiTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryIsNull() {
+            addCriterion("kimi_summary is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryIsNotNull() {
+            addCriterion("kimi_summary is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryEqualTo(String value) {
+            addCriterion("kimi_summary =", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryNotEqualTo(String value) {
+            addCriterion("kimi_summary <>", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryGreaterThan(String value) {
+            addCriterion("kimi_summary >", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryGreaterThanOrEqualTo(String value) {
+            addCriterion("kimi_summary >=", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryLessThan(String value) {
+            addCriterion("kimi_summary <", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryLessThanOrEqualTo(String value) {
+            addCriterion("kimi_summary <=", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryLike(String value) {
+            addCriterion("kimi_summary like", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryNotLike(String value) {
+            addCriterion("kimi_summary not like", value, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryIn(List<String> values) {
+            addCriterion("kimi_summary in", values, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryNotIn(List<String> values) {
+            addCriterion("kimi_summary not in", values, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryBetween(String value1, String value2) {
+            addCriterion("kimi_summary between", value1, value2, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiSummaryNotBetween(String value1, String value2) {
+            addCriterion("kimi_summary not between", value1, value2, "kimiSummary");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysIsNull() {
+            addCriterion("kimi_keys is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysIsNotNull() {
+            addCriterion("kimi_keys is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysEqualTo(String value) {
+            addCriterion("kimi_keys =", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysNotEqualTo(String value) {
+            addCriterion("kimi_keys <>", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysGreaterThan(String value) {
+            addCriterion("kimi_keys >", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysGreaterThanOrEqualTo(String value) {
+            addCriterion("kimi_keys >=", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysLessThan(String value) {
+            addCriterion("kimi_keys <", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysLessThanOrEqualTo(String value) {
+            addCriterion("kimi_keys <=", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysLike(String value) {
+            addCriterion("kimi_keys like", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysNotLike(String value) {
+            addCriterion("kimi_keys not like", value, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysIn(List<String> values) {
+            addCriterion("kimi_keys in", values, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysNotIn(List<String> values) {
+            addCriterion("kimi_keys not in", values, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysBetween(String value1, String value2) {
+            addCriterion("kimi_keys between", value1, value2, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiKeysNotBetween(String value1, String value2) {
+            addCriterion("kimi_keys not between", value1, value2, "kimiKeys");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusIsNull() {
+            addCriterion("kimi_status is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusIsNotNull() {
+            addCriterion("kimi_status is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusEqualTo(Integer value) {
+            addCriterion("kimi_status =", value, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusNotEqualTo(Integer value) {
+            addCriterion("kimi_status <>", value, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusGreaterThan(Integer value) {
+            addCriterion("kimi_status >", value, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusGreaterThanOrEqualTo(Integer value) {
+            addCriterion("kimi_status >=", value, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusLessThan(Integer value) {
+            addCriterion("kimi_status <", value, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusLessThanOrEqualTo(Integer value) {
+            addCriterion("kimi_status <=", value, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusIn(List<Integer> values) {
+            addCriterion("kimi_status in", values, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusNotIn(List<Integer> values) {
+            addCriterion("kimi_status not in", values, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusBetween(Integer value1, Integer value2) {
+            addCriterion("kimi_status between", value1, value2, "kimiStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andKimiStatusNotBetween(Integer value1, Integer value2) {
+            addCriterion("kimi_status not between", value1, value2, "kimiStatus");
+            return (Criteria) this;
+        }
+    }
+
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}

+ 158 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/MatchVideo.java

@@ -0,0 +1,158 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+import java.util.Date;
+
+public class MatchVideo {
+    private Integer id;
+
+    private String traceId;
+
+    private String contentId;
+
+    private String flowPoolLevel;
+
+    private String ghId;
+
+    private String accountName;
+
+    private Integer contentStatus;
+
+    private Integer contentStatusUpdateTime;
+
+    private Integer successStatus;
+
+    private Integer requestTimestamp;
+
+    private Date updateTime;
+
+    private Integer processTimes;
+
+    private String response;
+
+    public Integer getId() {
+        return id;
+    }
+
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    public String getTraceId() {
+        return traceId;
+    }
+
+    public void setTraceId(String traceId) {
+        this.traceId = traceId;
+    }
+
+    public String getContentId() {
+        return contentId;
+    }
+
+    public void setContentId(String contentId) {
+        this.contentId = contentId;
+    }
+
+    public String getFlowPoolLevel() {
+        return flowPoolLevel;
+    }
+
+    public void setFlowPoolLevel(String flowPoolLevel) {
+        this.flowPoolLevel = flowPoolLevel;
+    }
+
+    public String getGhId() {
+        return ghId;
+    }
+
+    public void setGhId(String ghId) {
+        this.ghId = ghId;
+    }
+
+    public String getAccountName() {
+        return accountName;
+    }
+
+    public void setAccountName(String accountName) {
+        this.accountName = accountName;
+    }
+
+    public Integer getContentStatus() {
+        return contentStatus;
+    }
+
+    public void setContentStatus(Integer contentStatus) {
+        this.contentStatus = contentStatus;
+    }
+
+    public Integer getContentStatusUpdateTime() {
+        return contentStatusUpdateTime;
+    }
+
+    public void setContentStatusUpdateTime(Integer contentStatusUpdateTime) {
+        this.contentStatusUpdateTime = contentStatusUpdateTime;
+    }
+
+    public Integer getSuccessStatus() {
+        return successStatus;
+    }
+
+    public void setSuccessStatus(Integer successStatus) {
+        this.successStatus = successStatus;
+    }
+
+    public Integer getRequestTimestamp() {
+        return requestTimestamp;
+    }
+
+    public void setRequestTimestamp(Integer requestTimestamp) {
+        this.requestTimestamp = requestTimestamp;
+    }
+
+    public Date getUpdateTime() {
+        return updateTime;
+    }
+
+    public void setUpdateTime(Date updateTime) {
+        this.updateTime = updateTime;
+    }
+
+    public Integer getProcessTimes() {
+        return processTimes;
+    }
+
+    public void setProcessTimes(Integer processTimes) {
+        this.processTimes = processTimes;
+    }
+
+    public String getResponse() {
+        return response;
+    }
+
+    public void setResponse(String response) {
+        this.response = response;
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", id=").append(id);
+        sb.append(", traceId=").append(traceId);
+        sb.append(", contentId=").append(contentId);
+        sb.append(", flowPoolLevel=").append(flowPoolLevel);
+        sb.append(", ghId=").append(ghId);
+        sb.append(", accountName=").append(accountName);
+        sb.append(", contentStatus=").append(contentStatus);
+        sb.append(", contentStatusUpdateTime=").append(contentStatusUpdateTime);
+        sb.append(", successStatus=").append(successStatus);
+        sb.append(", requestTimestamp=").append(requestTimestamp);
+        sb.append(", updateTime=").append(updateTime);
+        sb.append(", processTimes=").append(processTimes);
+        sb.append(", response=").append(response);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 982 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/MatchVideoExample.java

@@ -0,0 +1,982 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+import com.tzld.piaoquan.longarticle.utils.page.Page;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+public class MatchVideoExample {
+    protected String orderByClause;
+
+    protected boolean distinct;
+
+    protected List<Criteria> oredCriteria;
+
+    protected Page page;
+
+    public MatchVideoExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    public void setPage(Page page) {
+        this.page=page;
+    }
+
+    public Page getPage() {
+        return page;
+    }
+
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andIdIsNull() {
+            addCriterion("id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIsNotNull() {
+            addCriterion("id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdEqualTo(Integer value) {
+            addCriterion("id =", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotEqualTo(Integer value) {
+            addCriterion("id <>", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThan(Integer value) {
+            addCriterion("id >", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
+            addCriterion("id >=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThan(Integer value) {
+            addCriterion("id <", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThanOrEqualTo(Integer value) {
+            addCriterion("id <=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIn(List<Integer> values) {
+            addCriterion("id in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotIn(List<Integer> values) {
+            addCriterion("id not in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdBetween(Integer value1, Integer value2) {
+            addCriterion("id between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotBetween(Integer value1, Integer value2) {
+            addCriterion("id not between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNull() {
+            addCriterion("trace_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNotNull() {
+            addCriterion("trace_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdEqualTo(String value) {
+            addCriterion("trace_id =", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotEqualTo(String value) {
+            addCriterion("trace_id <>", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThan(String value) {
+            addCriterion("trace_id >", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThanOrEqualTo(String value) {
+            addCriterion("trace_id >=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThan(String value) {
+            addCriterion("trace_id <", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThanOrEqualTo(String value) {
+            addCriterion("trace_id <=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLike(String value) {
+            addCriterion("trace_id like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotLike(String value) {
+            addCriterion("trace_id not like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIn(List<String> values) {
+            addCriterion("trace_id in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotIn(List<String> values) {
+            addCriterion("trace_id not in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdBetween(String value1, String value2) {
+            addCriterion("trace_id between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotBetween(String value1, String value2) {
+            addCriterion("trace_id not between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIsNull() {
+            addCriterion("content_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIsNotNull() {
+            addCriterion("content_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdEqualTo(String value) {
+            addCriterion("content_id =", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotEqualTo(String value) {
+            addCriterion("content_id <>", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThan(String value) {
+            addCriterion("content_id >", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThanOrEqualTo(String value) {
+            addCriterion("content_id >=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThan(String value) {
+            addCriterion("content_id <", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThanOrEqualTo(String value) {
+            addCriterion("content_id <=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLike(String value) {
+            addCriterion("content_id like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotLike(String value) {
+            addCriterion("content_id not like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIn(List<String> values) {
+            addCriterion("content_id in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotIn(List<String> values) {
+            addCriterion("content_id not in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdBetween(String value1, String value2) {
+            addCriterion("content_id between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotBetween(String value1, String value2) {
+            addCriterion("content_id not between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelIsNull() {
+            addCriterion("flow_pool_level is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelIsNotNull() {
+            addCriterion("flow_pool_level is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelEqualTo(String value) {
+            addCriterion("flow_pool_level =", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelNotEqualTo(String value) {
+            addCriterion("flow_pool_level <>", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelGreaterThan(String value) {
+            addCriterion("flow_pool_level >", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelGreaterThanOrEqualTo(String value) {
+            addCriterion("flow_pool_level >=", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelLessThan(String value) {
+            addCriterion("flow_pool_level <", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelLessThanOrEqualTo(String value) {
+            addCriterion("flow_pool_level <=", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelLike(String value) {
+            addCriterion("flow_pool_level like", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelNotLike(String value) {
+            addCriterion("flow_pool_level not like", value, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelIn(List<String> values) {
+            addCriterion("flow_pool_level in", values, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelNotIn(List<String> values) {
+            addCriterion("flow_pool_level not in", values, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelBetween(String value1, String value2) {
+            addCriterion("flow_pool_level between", value1, value2, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andFlowPoolLevelNotBetween(String value1, String value2) {
+            addCriterion("flow_pool_level not between", value1, value2, "flowPoolLevel");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdIsNull() {
+            addCriterion("gh_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdIsNotNull() {
+            addCriterion("gh_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdEqualTo(String value) {
+            addCriterion("gh_id =", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotEqualTo(String value) {
+            addCriterion("gh_id <>", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdGreaterThan(String value) {
+            addCriterion("gh_id >", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdGreaterThanOrEqualTo(String value) {
+            addCriterion("gh_id >=", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdLessThan(String value) {
+            addCriterion("gh_id <", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdLessThanOrEqualTo(String value) {
+            addCriterion("gh_id <=", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdLike(String value) {
+            addCriterion("gh_id like", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotLike(String value) {
+            addCriterion("gh_id not like", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdIn(List<String> values) {
+            addCriterion("gh_id in", values, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotIn(List<String> values) {
+            addCriterion("gh_id not in", values, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdBetween(String value1, String value2) {
+            addCriterion("gh_id between", value1, value2, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotBetween(String value1, String value2) {
+            addCriterion("gh_id not between", value1, value2, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameIsNull() {
+            addCriterion("account_name is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameIsNotNull() {
+            addCriterion("account_name is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameEqualTo(String value) {
+            addCriterion("account_name =", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotEqualTo(String value) {
+            addCriterion("account_name <>", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameGreaterThan(String value) {
+            addCriterion("account_name >", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameGreaterThanOrEqualTo(String value) {
+            addCriterion("account_name >=", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameLessThan(String value) {
+            addCriterion("account_name <", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameLessThanOrEqualTo(String value) {
+            addCriterion("account_name <=", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameLike(String value) {
+            addCriterion("account_name like", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotLike(String value) {
+            addCriterion("account_name not like", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameIn(List<String> values) {
+            addCriterion("account_name in", values, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotIn(List<String> values) {
+            addCriterion("account_name not in", values, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameBetween(String value1, String value2) {
+            addCriterion("account_name between", value1, value2, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotBetween(String value1, String value2) {
+            addCriterion("account_name not between", value1, value2, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusIsNull() {
+            addCriterion("content_status is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusIsNotNull() {
+            addCriterion("content_status is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusEqualTo(Integer value) {
+            addCriterion("content_status =", value, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusNotEqualTo(Integer value) {
+            addCriterion("content_status <>", value, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusGreaterThan(Integer value) {
+            addCriterion("content_status >", value, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusGreaterThanOrEqualTo(Integer value) {
+            addCriterion("content_status >=", value, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusLessThan(Integer value) {
+            addCriterion("content_status <", value, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusLessThanOrEqualTo(Integer value) {
+            addCriterion("content_status <=", value, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusIn(List<Integer> values) {
+            addCriterion("content_status in", values, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusNotIn(List<Integer> values) {
+            addCriterion("content_status not in", values, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusBetween(Integer value1, Integer value2) {
+            addCriterion("content_status between", value1, value2, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusNotBetween(Integer value1, Integer value2) {
+            addCriterion("content_status not between", value1, value2, "contentStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeIsNull() {
+            addCriterion("content_status_update_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeIsNotNull() {
+            addCriterion("content_status_update_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeEqualTo(Integer value) {
+            addCriterion("content_status_update_time =", value, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeNotEqualTo(Integer value) {
+            addCriterion("content_status_update_time <>", value, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeGreaterThan(Integer value) {
+            addCriterion("content_status_update_time >", value, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeGreaterThanOrEqualTo(Integer value) {
+            addCriterion("content_status_update_time >=", value, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeLessThan(Integer value) {
+            addCriterion("content_status_update_time <", value, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeLessThanOrEqualTo(Integer value) {
+            addCriterion("content_status_update_time <=", value, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeIn(List<Integer> values) {
+            addCriterion("content_status_update_time in", values, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeNotIn(List<Integer> values) {
+            addCriterion("content_status_update_time not in", values, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeBetween(Integer value1, Integer value2) {
+            addCriterion("content_status_update_time between", value1, value2, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentStatusUpdateTimeNotBetween(Integer value1, Integer value2) {
+            addCriterion("content_status_update_time not between", value1, value2, "contentStatusUpdateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusIsNull() {
+            addCriterion("success_status is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusIsNotNull() {
+            addCriterion("success_status is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusEqualTo(Integer value) {
+            addCriterion("success_status =", value, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusNotEqualTo(Integer value) {
+            addCriterion("success_status <>", value, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusGreaterThan(Integer value) {
+            addCriterion("success_status >", value, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusGreaterThanOrEqualTo(Integer value) {
+            addCriterion("success_status >=", value, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusLessThan(Integer value) {
+            addCriterion("success_status <", value, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusLessThanOrEqualTo(Integer value) {
+            addCriterion("success_status <=", value, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusIn(List<Integer> values) {
+            addCriterion("success_status in", values, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusNotIn(List<Integer> values) {
+            addCriterion("success_status not in", values, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusBetween(Integer value1, Integer value2) {
+            addCriterion("success_status between", value1, value2, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andSuccessStatusNotBetween(Integer value1, Integer value2) {
+            addCriterion("success_status not between", value1, value2, "successStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampIsNull() {
+            addCriterion("request_timestamp is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampIsNotNull() {
+            addCriterion("request_timestamp is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampEqualTo(Integer value) {
+            addCriterion("request_timestamp =", value, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampNotEqualTo(Integer value) {
+            addCriterion("request_timestamp <>", value, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampGreaterThan(Integer value) {
+            addCriterion("request_timestamp >", value, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampGreaterThanOrEqualTo(Integer value) {
+            addCriterion("request_timestamp >=", value, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampLessThan(Integer value) {
+            addCriterion("request_timestamp <", value, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampLessThanOrEqualTo(Integer value) {
+            addCriterion("request_timestamp <=", value, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampIn(List<Integer> values) {
+            addCriterion("request_timestamp in", values, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampNotIn(List<Integer> values) {
+            addCriterion("request_timestamp not in", values, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampBetween(Integer value1, Integer value2) {
+            addCriterion("request_timestamp between", value1, value2, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimestampNotBetween(Integer value1, Integer value2) {
+            addCriterion("request_timestamp not between", value1, value2, "requestTimestamp");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeIsNull() {
+            addCriterion("update_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeIsNotNull() {
+            addCriterion("update_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeEqualTo(Date value) {
+            addCriterion("update_time =", value, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeNotEqualTo(Date value) {
+            addCriterion("update_time <>", value, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeGreaterThan(Date value) {
+            addCriterion("update_time >", value, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) {
+            addCriterion("update_time >=", value, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeLessThan(Date value) {
+            addCriterion("update_time <", value, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeLessThanOrEqualTo(Date value) {
+            addCriterion("update_time <=", value, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeIn(List<Date> values) {
+            addCriterion("update_time in", values, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeNotIn(List<Date> values) {
+            addCriterion("update_time not in", values, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeBetween(Date value1, Date value2) {
+            addCriterion("update_time between", value1, value2, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andUpdateTimeNotBetween(Date value1, Date value2) {
+            addCriterion("update_time not between", value1, value2, "updateTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesIsNull() {
+            addCriterion("process_times is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesIsNotNull() {
+            addCriterion("process_times is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesEqualTo(Integer value) {
+            addCriterion("process_times =", value, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesNotEqualTo(Integer value) {
+            addCriterion("process_times <>", value, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesGreaterThan(Integer value) {
+            addCriterion("process_times >", value, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesGreaterThanOrEqualTo(Integer value) {
+            addCriterion("process_times >=", value, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesLessThan(Integer value) {
+            addCriterion("process_times <", value, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesLessThanOrEqualTo(Integer value) {
+            addCriterion("process_times <=", value, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesIn(List<Integer> values) {
+            addCriterion("process_times in", values, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesNotIn(List<Integer> values) {
+            addCriterion("process_times not in", values, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesBetween(Integer value1, Integer value2) {
+            addCriterion("process_times between", value1, value2, "processTimes");
+            return (Criteria) this;
+        }
+
+        public Criteria andProcessTimesNotBetween(Integer value1, Integer value2) {
+            addCriterion("process_times not between", value1, value2, "processTimes");
+            return (Criteria) this;
+        }
+    }
+
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}

+ 79 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/OffVideo.java

@@ -0,0 +1,79 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+public class OffVideo {
+    private Long videoId;
+
+    private Long publishTime;
+
+    private Integer videoStatus;
+
+    private String traceId;
+
+    private Long getOffTime;
+
+    private Integer checkStatus;
+
+    public Long getVideoId() {
+        return videoId;
+    }
+
+    public void setVideoId(Long videoId) {
+        this.videoId = videoId;
+    }
+
+    public Long getPublishTime() {
+        return publishTime;
+    }
+
+    public void setPublishTime(Long publishTime) {
+        this.publishTime = publishTime;
+    }
+
+    public Integer getVideoStatus() {
+        return videoStatus;
+    }
+
+    public void setVideoStatus(Integer videoStatus) {
+        this.videoStatus = videoStatus;
+    }
+
+    public String getTraceId() {
+        return traceId;
+    }
+
+    public void setTraceId(String traceId) {
+        this.traceId = traceId;
+    }
+
+    public Long getGetOffTime() {
+        return getOffTime;
+    }
+
+    public void setGetOffTime(Long getOffTime) {
+        this.getOffTime = getOffTime;
+    }
+
+    public Integer getCheckStatus() {
+        return checkStatus;
+    }
+
+    public void setCheckStatus(Integer checkStatus) {
+        this.checkStatus = checkStatus;
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", videoId=").append(videoId);
+        sb.append(", publishTime=").append(publishTime);
+        sb.append(", videoStatus=").append(videoStatus);
+        sb.append(", traceId=").append(traceId);
+        sb.append(", getOffTime=").append(getOffTime);
+        sb.append(", checkStatus=").append(checkStatus);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 581 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/OffVideoExample.java

@@ -0,0 +1,581 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+import com.tzld.piaoquan.longarticle.utils.page.Page;
+import java.util.ArrayList;
+import java.util.List;
+
+public class OffVideoExample {
+    protected String orderByClause;
+
+    protected boolean distinct;
+
+    protected List<Criteria> oredCriteria;
+
+    protected Page page;
+
+    public OffVideoExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    public void setPage(Page page) {
+        this.page=page;
+    }
+
+    public Page getPage() {
+        return page;
+    }
+
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andVideoIdIsNull() {
+            addCriterion("video_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdIsNotNull() {
+            addCriterion("video_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdEqualTo(Long value) {
+            addCriterion("video_id =", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdNotEqualTo(Long value) {
+            addCriterion("video_id <>", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdGreaterThan(Long value) {
+            addCriterion("video_id >", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdGreaterThanOrEqualTo(Long value) {
+            addCriterion("video_id >=", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdLessThan(Long value) {
+            addCriterion("video_id <", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdLessThanOrEqualTo(Long value) {
+            addCriterion("video_id <=", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdIn(List<Long> values) {
+            addCriterion("video_id in", values, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdNotIn(List<Long> values) {
+            addCriterion("video_id not in", values, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdBetween(Long value1, Long value2) {
+            addCriterion("video_id between", value1, value2, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdNotBetween(Long value1, Long value2) {
+            addCriterion("video_id not between", value1, value2, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeIsNull() {
+            addCriterion("publish_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeIsNotNull() {
+            addCriterion("publish_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeEqualTo(Long value) {
+            addCriterion("publish_time =", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeNotEqualTo(Long value) {
+            addCriterion("publish_time <>", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeGreaterThan(Long value) {
+            addCriterion("publish_time >", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeGreaterThanOrEqualTo(Long value) {
+            addCriterion("publish_time >=", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeLessThan(Long value) {
+            addCriterion("publish_time <", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeLessThanOrEqualTo(Long value) {
+            addCriterion("publish_time <=", value, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeIn(List<Long> values) {
+            addCriterion("publish_time in", values, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeNotIn(List<Long> values) {
+            addCriterion("publish_time not in", values, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeBetween(Long value1, Long value2) {
+            addCriterion("publish_time between", value1, value2, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andPublishTimeNotBetween(Long value1, Long value2) {
+            addCriterion("publish_time not between", value1, value2, "publishTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusIsNull() {
+            addCriterion("video_status is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusIsNotNull() {
+            addCriterion("video_status is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusEqualTo(Integer value) {
+            addCriterion("video_status =", value, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusNotEqualTo(Integer value) {
+            addCriterion("video_status <>", value, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusGreaterThan(Integer value) {
+            addCriterion("video_status >", value, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusGreaterThanOrEqualTo(Integer value) {
+            addCriterion("video_status >=", value, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusLessThan(Integer value) {
+            addCriterion("video_status <", value, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusLessThanOrEqualTo(Integer value) {
+            addCriterion("video_status <=", value, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusIn(List<Integer> values) {
+            addCriterion("video_status in", values, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusNotIn(List<Integer> values) {
+            addCriterion("video_status not in", values, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusBetween(Integer value1, Integer value2) {
+            addCriterion("video_status between", value1, value2, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoStatusNotBetween(Integer value1, Integer value2) {
+            addCriterion("video_status not between", value1, value2, "videoStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNull() {
+            addCriterion("trace_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNotNull() {
+            addCriterion("trace_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdEqualTo(String value) {
+            addCriterion("trace_id =", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotEqualTo(String value) {
+            addCriterion("trace_id <>", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThan(String value) {
+            addCriterion("trace_id >", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThanOrEqualTo(String value) {
+            addCriterion("trace_id >=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThan(String value) {
+            addCriterion("trace_id <", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThanOrEqualTo(String value) {
+            addCriterion("trace_id <=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLike(String value) {
+            addCriterion("trace_id like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotLike(String value) {
+            addCriterion("trace_id not like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIn(List<String> values) {
+            addCriterion("trace_id in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotIn(List<String> values) {
+            addCriterion("trace_id not in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdBetween(String value1, String value2) {
+            addCriterion("trace_id between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotBetween(String value1, String value2) {
+            addCriterion("trace_id not between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeIsNull() {
+            addCriterion("get_off_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeIsNotNull() {
+            addCriterion("get_off_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeEqualTo(Long value) {
+            addCriterion("get_off_time =", value, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeNotEqualTo(Long value) {
+            addCriterion("get_off_time <>", value, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeGreaterThan(Long value) {
+            addCriterion("get_off_time >", value, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeGreaterThanOrEqualTo(Long value) {
+            addCriterion("get_off_time >=", value, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeLessThan(Long value) {
+            addCriterion("get_off_time <", value, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeLessThanOrEqualTo(Long value) {
+            addCriterion("get_off_time <=", value, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeIn(List<Long> values) {
+            addCriterion("get_off_time in", values, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeNotIn(List<Long> values) {
+            addCriterion("get_off_time not in", values, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeBetween(Long value1, Long value2) {
+            addCriterion("get_off_time between", value1, value2, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andGetOffTimeNotBetween(Long value1, Long value2) {
+            addCriterion("get_off_time not between", value1, value2, "getOffTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusIsNull() {
+            addCriterion("check_status is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusIsNotNull() {
+            addCriterion("check_status is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusEqualTo(Integer value) {
+            addCriterion("check_status =", value, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusNotEqualTo(Integer value) {
+            addCriterion("check_status <>", value, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusGreaterThan(Integer value) {
+            addCriterion("check_status >", value, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusGreaterThanOrEqualTo(Integer value) {
+            addCriterion("check_status >=", value, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusLessThan(Integer value) {
+            addCriterion("check_status <", value, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusLessThanOrEqualTo(Integer value) {
+            addCriterion("check_status <=", value, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusIn(List<Integer> values) {
+            addCriterion("check_status in", values, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusNotIn(List<Integer> values) {
+            addCriterion("check_status not in", values, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusBetween(Integer value1, Integer value2) {
+            addCriterion("check_status between", value1, value2, "checkStatus");
+            return (Criteria) this;
+        }
+
+        public Criteria andCheckStatusNotBetween(Integer value1, Integer value2) {
+            addCriterion("check_status not between", value1, value2, "checkStatus");
+            return (Criteria) this;
+        }
+    }
+
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}

+ 123 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/RootSource.java

@@ -0,0 +1,123 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+public class RootSource {
+    private String rootSourceId;
+
+    private String accountName;
+
+    private String ghId;
+
+    private String articleTitle;
+
+    private Integer requestTime;
+
+    private String traceId;
+
+    private Integer pushType;
+
+    private Long videoId;
+
+    private String contentId;
+
+    private String ossName;
+
+    public String getRootSourceId() {
+        return rootSourceId;
+    }
+
+    public void setRootSourceId(String rootSourceId) {
+        this.rootSourceId = rootSourceId;
+    }
+
+    public String getAccountName() {
+        return accountName;
+    }
+
+    public void setAccountName(String accountName) {
+        this.accountName = accountName;
+    }
+
+    public String getGhId() {
+        return ghId;
+    }
+
+    public void setGhId(String ghId) {
+        this.ghId = ghId;
+    }
+
+    public String getArticleTitle() {
+        return articleTitle;
+    }
+
+    public void setArticleTitle(String articleTitle) {
+        this.articleTitle = articleTitle;
+    }
+
+    public Integer getRequestTime() {
+        return requestTime;
+    }
+
+    public void setRequestTime(Integer requestTime) {
+        this.requestTime = requestTime;
+    }
+
+    public String getTraceId() {
+        return traceId;
+    }
+
+    public void setTraceId(String traceId) {
+        this.traceId = traceId;
+    }
+
+    public Integer getPushType() {
+        return pushType;
+    }
+
+    public void setPushType(Integer pushType) {
+        this.pushType = pushType;
+    }
+
+    public Long getVideoId() {
+        return videoId;
+    }
+
+    public void setVideoId(Long videoId) {
+        this.videoId = videoId;
+    }
+
+    public String getContentId() {
+        return contentId;
+    }
+
+    public void setContentId(String contentId) {
+        this.contentId = contentId;
+    }
+
+    public String getOssName() {
+        return ossName;
+    }
+
+    public void setOssName(String ossName) {
+        this.ossName = ossName;
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", rootSourceId=").append(rootSourceId);
+        sb.append(", accountName=").append(accountName);
+        sb.append(", ghId=").append(ghId);
+        sb.append(", articleTitle=").append(articleTitle);
+        sb.append(", requestTime=").append(requestTime);
+        sb.append(", traceId=").append(traceId);
+        sb.append(", pushType=").append(pushType);
+        sb.append(", videoId=").append(videoId);
+        sb.append(", contentId=").append(contentId);
+        sb.append(", ossName=").append(ossName);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 881 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/po/RootSourceExample.java

@@ -0,0 +1,881 @@
+package com.tzld.piaoquan.longarticle.model.po;
+
+import com.tzld.piaoquan.longarticle.utils.page.Page;
+import java.util.ArrayList;
+import java.util.List;
+
+public class RootSourceExample {
+    protected String orderByClause;
+
+    protected boolean distinct;
+
+    protected List<Criteria> oredCriteria;
+
+    protected Page page;
+
+    public RootSourceExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    public void setPage(Page page) {
+        this.page=page;
+    }
+
+    public Page getPage() {
+        return page;
+    }
+
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andRootSourceIdIsNull() {
+            addCriterion("root_source_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdIsNotNull() {
+            addCriterion("root_source_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdEqualTo(String value) {
+            addCriterion("root_source_id =", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdNotEqualTo(String value) {
+            addCriterion("root_source_id <>", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdGreaterThan(String value) {
+            addCriterion("root_source_id >", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdGreaterThanOrEqualTo(String value) {
+            addCriterion("root_source_id >=", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdLessThan(String value) {
+            addCriterion("root_source_id <", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdLessThanOrEqualTo(String value) {
+            addCriterion("root_source_id <=", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdLike(String value) {
+            addCriterion("root_source_id like", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdNotLike(String value) {
+            addCriterion("root_source_id not like", value, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdIn(List<String> values) {
+            addCriterion("root_source_id in", values, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdNotIn(List<String> values) {
+            addCriterion("root_source_id not in", values, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdBetween(String value1, String value2) {
+            addCriterion("root_source_id between", value1, value2, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andRootSourceIdNotBetween(String value1, String value2) {
+            addCriterion("root_source_id not between", value1, value2, "rootSourceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameIsNull() {
+            addCriterion("account_name is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameIsNotNull() {
+            addCriterion("account_name is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameEqualTo(String value) {
+            addCriterion("account_name =", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotEqualTo(String value) {
+            addCriterion("account_name <>", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameGreaterThan(String value) {
+            addCriterion("account_name >", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameGreaterThanOrEqualTo(String value) {
+            addCriterion("account_name >=", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameLessThan(String value) {
+            addCriterion("account_name <", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameLessThanOrEqualTo(String value) {
+            addCriterion("account_name <=", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameLike(String value) {
+            addCriterion("account_name like", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotLike(String value) {
+            addCriterion("account_name not like", value, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameIn(List<String> values) {
+            addCriterion("account_name in", values, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotIn(List<String> values) {
+            addCriterion("account_name not in", values, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameBetween(String value1, String value2) {
+            addCriterion("account_name between", value1, value2, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andAccountNameNotBetween(String value1, String value2) {
+            addCriterion("account_name not between", value1, value2, "accountName");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdIsNull() {
+            addCriterion("gh_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdIsNotNull() {
+            addCriterion("gh_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdEqualTo(String value) {
+            addCriterion("gh_id =", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotEqualTo(String value) {
+            addCriterion("gh_id <>", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdGreaterThan(String value) {
+            addCriterion("gh_id >", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdGreaterThanOrEqualTo(String value) {
+            addCriterion("gh_id >=", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdLessThan(String value) {
+            addCriterion("gh_id <", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdLessThanOrEqualTo(String value) {
+            addCriterion("gh_id <=", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdLike(String value) {
+            addCriterion("gh_id like", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotLike(String value) {
+            addCriterion("gh_id not like", value, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdIn(List<String> values) {
+            addCriterion("gh_id in", values, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotIn(List<String> values) {
+            addCriterion("gh_id not in", values, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdBetween(String value1, String value2) {
+            addCriterion("gh_id between", value1, value2, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andGhIdNotBetween(String value1, String value2) {
+            addCriterion("gh_id not between", value1, value2, "ghId");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleIsNull() {
+            addCriterion("article_title is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleIsNotNull() {
+            addCriterion("article_title is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleEqualTo(String value) {
+            addCriterion("article_title =", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotEqualTo(String value) {
+            addCriterion("article_title <>", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleGreaterThan(String value) {
+            addCriterion("article_title >", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleGreaterThanOrEqualTo(String value) {
+            addCriterion("article_title >=", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleLessThan(String value) {
+            addCriterion("article_title <", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleLessThanOrEqualTo(String value) {
+            addCriterion("article_title <=", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleLike(String value) {
+            addCriterion("article_title like", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotLike(String value) {
+            addCriterion("article_title not like", value, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleIn(List<String> values) {
+            addCriterion("article_title in", values, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotIn(List<String> values) {
+            addCriterion("article_title not in", values, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleBetween(String value1, String value2) {
+            addCriterion("article_title between", value1, value2, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andArticleTitleNotBetween(String value1, String value2) {
+            addCriterion("article_title not between", value1, value2, "articleTitle");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeIsNull() {
+            addCriterion("request_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeIsNotNull() {
+            addCriterion("request_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeEqualTo(Integer value) {
+            addCriterion("request_time =", value, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeNotEqualTo(Integer value) {
+            addCriterion("request_time <>", value, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeGreaterThan(Integer value) {
+            addCriterion("request_time >", value, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeGreaterThanOrEqualTo(Integer value) {
+            addCriterion("request_time >=", value, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeLessThan(Integer value) {
+            addCriterion("request_time <", value, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeLessThanOrEqualTo(Integer value) {
+            addCriterion("request_time <=", value, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeIn(List<Integer> values) {
+            addCriterion("request_time in", values, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeNotIn(List<Integer> values) {
+            addCriterion("request_time not in", values, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeBetween(Integer value1, Integer value2) {
+            addCriterion("request_time between", value1, value2, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andRequestTimeNotBetween(Integer value1, Integer value2) {
+            addCriterion("request_time not between", value1, value2, "requestTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNull() {
+            addCriterion("trace_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIsNotNull() {
+            addCriterion("trace_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdEqualTo(String value) {
+            addCriterion("trace_id =", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotEqualTo(String value) {
+            addCriterion("trace_id <>", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThan(String value) {
+            addCriterion("trace_id >", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdGreaterThanOrEqualTo(String value) {
+            addCriterion("trace_id >=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThan(String value) {
+            addCriterion("trace_id <", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLessThanOrEqualTo(String value) {
+            addCriterion("trace_id <=", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdLike(String value) {
+            addCriterion("trace_id like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotLike(String value) {
+            addCriterion("trace_id not like", value, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdIn(List<String> values) {
+            addCriterion("trace_id in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotIn(List<String> values) {
+            addCriterion("trace_id not in", values, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdBetween(String value1, String value2) {
+            addCriterion("trace_id between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andTraceIdNotBetween(String value1, String value2) {
+            addCriterion("trace_id not between", value1, value2, "traceId");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeIsNull() {
+            addCriterion("push_type is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeIsNotNull() {
+            addCriterion("push_type is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeEqualTo(Integer value) {
+            addCriterion("push_type =", value, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeNotEqualTo(Integer value) {
+            addCriterion("push_type <>", value, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeGreaterThan(Integer value) {
+            addCriterion("push_type >", value, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeGreaterThanOrEqualTo(Integer value) {
+            addCriterion("push_type >=", value, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeLessThan(Integer value) {
+            addCriterion("push_type <", value, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeLessThanOrEqualTo(Integer value) {
+            addCriterion("push_type <=", value, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeIn(List<Integer> values) {
+            addCriterion("push_type in", values, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeNotIn(List<Integer> values) {
+            addCriterion("push_type not in", values, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeBetween(Integer value1, Integer value2) {
+            addCriterion("push_type between", value1, value2, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andPushTypeNotBetween(Integer value1, Integer value2) {
+            addCriterion("push_type not between", value1, value2, "pushType");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdIsNull() {
+            addCriterion("video_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdIsNotNull() {
+            addCriterion("video_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdEqualTo(Long value) {
+            addCriterion("video_id =", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdNotEqualTo(Long value) {
+            addCriterion("video_id <>", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdGreaterThan(Long value) {
+            addCriterion("video_id >", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdGreaterThanOrEqualTo(Long value) {
+            addCriterion("video_id >=", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdLessThan(Long value) {
+            addCriterion("video_id <", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdLessThanOrEqualTo(Long value) {
+            addCriterion("video_id <=", value, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdIn(List<Long> values) {
+            addCriterion("video_id in", values, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdNotIn(List<Long> values) {
+            addCriterion("video_id not in", values, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdBetween(Long value1, Long value2) {
+            addCriterion("video_id between", value1, value2, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andVideoIdNotBetween(Long value1, Long value2) {
+            addCriterion("video_id not between", value1, value2, "videoId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIsNull() {
+            addCriterion("content_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIsNotNull() {
+            addCriterion("content_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdEqualTo(String value) {
+            addCriterion("content_id =", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotEqualTo(String value) {
+            addCriterion("content_id <>", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThan(String value) {
+            addCriterion("content_id >", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdGreaterThanOrEqualTo(String value) {
+            addCriterion("content_id >=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThan(String value) {
+            addCriterion("content_id <", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLessThanOrEqualTo(String value) {
+            addCriterion("content_id <=", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdLike(String value) {
+            addCriterion("content_id like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotLike(String value) {
+            addCriterion("content_id not like", value, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdIn(List<String> values) {
+            addCriterion("content_id in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotIn(List<String> values) {
+            addCriterion("content_id not in", values, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdBetween(String value1, String value2) {
+            addCriterion("content_id between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andContentIdNotBetween(String value1, String value2) {
+            addCriterion("content_id not between", value1, value2, "contentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameIsNull() {
+            addCriterion("oss_name is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameIsNotNull() {
+            addCriterion("oss_name is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameEqualTo(String value) {
+            addCriterion("oss_name =", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameNotEqualTo(String value) {
+            addCriterion("oss_name <>", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameGreaterThan(String value) {
+            addCriterion("oss_name >", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameGreaterThanOrEqualTo(String value) {
+            addCriterion("oss_name >=", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameLessThan(String value) {
+            addCriterion("oss_name <", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameLessThanOrEqualTo(String value) {
+            addCriterion("oss_name <=", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameLike(String value) {
+            addCriterion("oss_name like", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameNotLike(String value) {
+            addCriterion("oss_name not like", value, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameIn(List<String> values) {
+            addCriterion("oss_name in", values, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameNotIn(List<String> values) {
+            addCriterion("oss_name not in", values, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameBetween(String value1, String value2) {
+            addCriterion("oss_name between", value1, value2, "ossName");
+            return (Criteria) this;
+        }
+
+        public Criteria andOssNameNotBetween(String value1, String value2) {
+            addCriterion("oss_name not between", value1, value2, "ossName");
+            return (Criteria) this;
+        }
+    }
+
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}

+ 15 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/ArticleSortParam.java

@@ -0,0 +1,15 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Data;
+
+@Data
+public class ArticleSortParam {
+
+    private String accountId;
+    private String accountName;
+    private String ghId;
+    private String strategy;
+    private Integer publishNum;
+    private String planId;
+    private Integer pushType;
+}

+ 12 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/FilterSortParam.java

@@ -0,0 +1,12 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Getter;
+import lombok.Setter;
+
+import java.util.List;
+
+@Getter
+@Setter
+public class FilterSortParam {
+    private List<FilterSortContentParam> filterSortContentList;
+}

+ 12 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/GzhArticleSortTaskParam.java

@@ -0,0 +1,12 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Data;
+
+import java.util.List;
+@Data
+public class GzhArticleSortTaskParam {
+    //"策略")
+    private String strategy;
+    // "账号ID列表")
+    private List<String> accountIds;
+}

+ 21 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemContentItemVO.java

@@ -0,0 +1,21 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class LongArticleSystemContentItemVO {
+    //"发布内容ID")
+    private String publishContentId;
+    //"来源ID,一般为生成内容ID")
+    private String sourceId;
+    //"标题")
+    private String title;
+    //"正文")
+    private String content;
+    private String flowPoolLevelTag;
+
+}

+ 18 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemContentVO.java

@@ -0,0 +1,18 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+import java.util.List;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class LongArticleSystemContentVO {
+
+    //"内容总数")
+    private Long totalCount;
+    //"内容列表")
+    private List<LongArticleSystemContentItemVO> contentItemList;
+}

+ 23 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemCreatePushTaskParam.java

@@ -0,0 +1,23 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.ToString;
+
+import java.util.List;
+
+@Getter
+@Setter
+@ToString
+public class LongArticleSystemCreatePushTaskParam {
+
+    //"计划ID")
+    private String planId;
+    //"账号ID")
+    private String accountId;
+    //"1-手动推送;2-自动群发;3-自动发表;4-自动发布;5-分组群发;6-触发推送")
+    private Integer pushType;
+    //"计划推送时间戳")
+    private Long pushScheduleTimestamp;
+    private List<LongArticleSystemPushContentParam> pushContentList;
+}

+ 16 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemFilterSortContentParam.java

@@ -0,0 +1,16 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+
+import lombok.Getter;
+import lombok.Setter;
+
+@Getter
+@Setter
+public class FilterSortContentParam {
+
+    //"发布内容ID")
+    private String publishContentId;
+    //"过滤原因")
+    private String filterReason;
+
+}

+ 18 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemGetContentsParam.java

@@ -0,0 +1,18 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Getter;
+import lombok.Setter;
+
+@Getter
+@Setter
+public class LongArticleSystemGetContentsParam {
+
+    //"计划ID")
+    private String planId;
+    //"账号ID")
+    private String accountId;
+    //"页码,第1开始")
+    private Integer pageNum;
+    //"每页个数")
+    private Integer pageSize;
+}

+ 17 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/LongArticleSystemPushContentParam.java

@@ -0,0 +1,17 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.ToString;
+
+import java.util.List;
+
+@Getter
+@Setter
+@ToString
+public class LongArticleSystemPushContentParam {
+    //"发布内容ID")
+    private String publishContentId;
+    //"排版内容")
+    private List<PublishMiniprogram> miniprogramCardList;
+}

+ 16 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/MatchVideoVo.java

@@ -0,0 +1,16 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Data;
+
+@Data
+public class MatchVideoVo {
+
+    private String ghId;
+    private String accountName;
+    private String content;
+    private String title;
+    private String cover;
+    private String strategy;
+    private String articleId;
+    private String flowPoolLevelTag;
+}

+ 22 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/MiniprogramInsertTaskParam.java

@@ -0,0 +1,22 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Data;
+
+import java.util.List;
+
+@Data
+public class MiniprogramInsertTaskParam {
+
+    //"任务ID")
+    private String taskId;
+    //"任务序号")
+    private Integer taskIndex;
+    //"任务名称")
+    private String name;
+    //"策略")
+    private String strategy;
+    //"账号ID列表")
+    private List<String> accountIds;
+    //"小程序用途,1-自然流,2-投流'")
+    private Integer miniprogramUseType;
+}

+ 16 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/ProduceAuditLayoutContentObjVO.java

@@ -0,0 +1,16 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.experimental.Accessors;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+public class ProduceAuditLayoutContentObjVO {
+
+    //"排版内容类型 0文本 1图片 2公众号 3首图/尾图 4小程序卡片")
+    private Integer type;
+    //"排版内容")
+    private String data;
+}

+ 33 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/model/vo/PublishMiniprogram.java

@@ -0,0 +1,33 @@
+package com.tzld.piaoquan.longarticle.model.vo;
+
+
+import lombok.Getter;
+import lombok.Setter;
+import lombok.ToString;
+import lombok.experimental.Accessors;
+
+import java.math.BigDecimal;
+
+@Getter
+@Setter
+@Accessors(chain = true)
+@ToString
+public class PublishMiniprogram {
+
+    private String productionCover;
+    private String productionName;
+    private String productionPath;
+    private String programAvatar;
+    private String programId;
+    private String programName;
+    private String rootShareId;
+    private String source;
+    private String videoUrl;
+    private BigDecimal paragraphPosition;
+    private Integer mini_id;
+    private String traceId;
+    private Integer miniprogramUseType;
+
+
+
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/CardService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface CardService {
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/ContentService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface ContentService {
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/CoreService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface CoreService {
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/CoverService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface CoverService {
+}

+ 10 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/KimiService.java

@@ -0,0 +1,10 @@
+package com.tzld.piaoquan.longarticle.service;
+
+import com.tzld.piaoquan.longarticle.model.po.LongArticlesText;
+
+public interface KimiService {
+
+    void addContent(String contentId, String articleTitle, String articleText);
+
+    LongArticlesText getKimiText(String contentId);
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/MatchVideoService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface MatchVideoService {
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/PlanService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface PlanService {
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/PublishService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface PublishService {
+}

+ 4 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/SortService.java

@@ -0,0 +1,4 @@
+package com.tzld.piaoquan.longarticle.service;
+
+public interface SortService {
+}

+ 155 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/CardServiceImpl.java

@@ -0,0 +1,155 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import com.alibaba.fastjson.JSONObject;
+import com.ctrip.framework.apollo.spring.annotation.ApolloJsonValue;
+import com.tzld.piaoquan.longarticle.model.bo.VideoDetail;
+import com.tzld.piaoquan.longarticle.model.vo.PublishMiniprogram;
+import com.tzld.piaoquan.longarticle.service.CardService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.util.StringUtils;
+
+import java.math.BigDecimal;
+import java.net.URLEncoder;
+import java.nio.charset.StandardCharsets;
+import java.security.MessageDigest;
+import java.security.NoSuchAlgorithmException;
+import java.util.*;
+
+@Service
+public class CardServiceImpl implements CardService {
+
+    @ApolloJsonValue("${miniMap:{}}")
+    private JSONObject miniProgramMap;
+
+    @Autowired
+    CoverServiceImpl coverService;
+
+
+    public JSONObject createGzhPath(String videoId, String sharedUid, String ghId, Integer miniProgramType) {
+        String rootShareId = UUID.randomUUID().toString();
+        String rootSourceId;
+
+        switch (miniProgramType) {
+            case 2:
+                rootSourceId = "touliu_tencentGzhArticle_" + ghId + "_" + generateSourceId();
+                break;
+            case 1:
+                rootSourceId = "longArticles_" + generateSourceId();
+                break;
+            case 3:
+                rootSourceId = "WeCom_" + generateSourceId();
+                break;
+            default:
+                rootSourceId = "Error mini_program_type " + miniProgramType;
+        }
+
+        String url = String.format("pages/user-videos?id=%s&su=%s&fromGzh=1&rootShareId=%s&shareId=%s&rootSourceId=%s",
+                videoId, sharedUid, rootShareId, rootShareId, rootSourceId);
+        String productionPath = String.format("pages/category?jumpPage=%s", URLEncoder.encode(url, StandardCharsets.UTF_8));
+        JSONObject jsonObject = new JSONObject();
+        jsonObject.put("rootShareId", rootShareId);
+        jsonObject.put("rootSourceId", rootSourceId);
+        jsonObject.put("productionPath", productionPath);
+        return jsonObject;
+    }
+
+    private String generateSourceId() {
+        long timestamp = System.currentTimeMillis();
+        int randomNum = new Random().nextInt(9000) + 1000;
+        String hashInput = timestamp + "-" + randomNum;
+        return md5(hashInput);
+    }
+
+    private String md5(String input) {
+        try {
+            MessageDigest md = MessageDigest.getInstance("MD5");
+            byte[] messageDigest = md.digest(input.getBytes(StandardCharsets.UTF_8));
+            StringBuilder sb = new StringBuilder();
+            for (byte b : messageDigest) {
+                sb.append(String.format("%02x", b));
+            }
+            return sb.toString();
+        } catch (NoSuchAlgorithmException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public PublishMiniprogram generateSingleCard(Integer index, String ghId, Integer miniId, VideoDetail videoDetail, Integer miniProgramType, String publishContentId) {
+        String strMiniId = String.valueOf(miniId);
+        JSONObject miniInfo = miniProgramMap.getJSONObject(strMiniId);
+        String avatar = miniInfo.getString("avatar");
+        String appId = miniInfo.getString("id");
+        String appName = miniInfo.getString("name");
+
+        String videoId = videoDetail.getVideoId();
+        String uid = videoDetail.getUid();
+        JSONObject jsonObject = createGzhPath(videoId, uid, ghId, miniProgramType);
+
+        PublishMiniprogram publishMiniprogram = new PublishMiniprogram();
+        publishMiniprogram.setProgramId(appId);
+        publishMiniprogram.setProgramName(appName);
+        publishMiniprogram.setProgramAvatar(avatar);
+        publishMiniprogram.setMini_id(miniId);
+        publishMiniprogram.setMiniprogramUseType(miniProgramType);
+        String kimiTitle = videoDetail.getKimiTitle();
+        if (StringUtils.hasText(kimiTitle)) {
+            kimiTitle = kimiTitle.replace("\"", "");
+            if (kimiTitle.length() > 32) {
+                kimiTitle = kimiTitle.substring(0, 32);
+            }
+            publishMiniprogram.setProductionName(kimiTitle);
+        }
+        String videoCover = videoDetail.getVideoCover();
+        String imageUrl = coverService.pushCover(videoCover, publishContentId);
+        if (StringUtils.isEmpty(imageUrl)) {
+            //TODO 上线要放开
+//            return null;
+        }
+        publishMiniprogram.setProductionCover(imageUrl);
+        publishMiniprogram.setProductionPath(jsonObject.getString("productionPath"));
+        publishMiniprogram.setRootShareId(jsonObject.getString("rootShareId"));
+        publishMiniprogram.setSource(videoDetail.getSource());
+        publishMiniprogram.setVideoUrl(videoDetail.getVideoPath());
+        publishMiniprogram.setTraceId(videoDetail.getTraceId());
+        publishMiniprogram.setParagraphPosition(BigDecimal.valueOf(index * 0.25));
+        if (index == 1) {
+            publishMiniprogram.setParagraphPosition(BigDecimal.valueOf(0.01));
+        }
+        return publishMiniprogram;
+    }
+
+    public List<PublishMiniprogram> generateCards(String ghId, List<VideoDetail> videoDetails, int miniProgramType, String publishContentId) {
+        int long_articles_mini_program_id = 25;
+        int touliu_mini_program_id = 33;
+        int we_com_mini_program_id = 27;
+        int miniId = 0;
+
+        List<PublishMiniprogram> cardList = new ArrayList<>();
+
+        switch (miniProgramType) {
+            case 1:
+                miniId = long_articles_mini_program_id;
+                break;
+            case 2:
+                miniId = touliu_mini_program_id;
+                break;
+            case 3:
+                miniId = we_com_mini_program_id;
+                break;
+            default:
+                break;
+        }
+        if (miniId == 0) {
+            return null;
+        }
+        for (int index = 0; index < videoDetails.size(); index++) {
+            VideoDetail videoDetail = videoDetails.get(index);
+            PublishMiniprogram card = generateSingleCard(index + 1, ghId, miniId, videoDetail, miniProgramType, publishContentId);
+            if (card != null) {
+                cardList.add(card);
+            }
+        }
+        return cardList;
+    }
+}

+ 92 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/ContentServiceImpl.java

@@ -0,0 +1,92 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONArray;
+import com.alibaba.fastjson.JSONObject;
+import com.ctrip.framework.apollo.spring.annotation.ApolloJsonValue;
+import com.tzld.piaoquan.longarticle.dao.mapper.CrawlerVideoMapper;
+import com.tzld.piaoquan.longarticle.model.dto.MiniprogramCardRequest;
+import com.tzld.piaoquan.longarticle.model.po.CrawlerVideo;
+import com.tzld.piaoquan.longarticle.model.po.CrawlerVideoExample;
+import com.tzld.piaoquan.longarticle.model.po.LongArticlesText;
+import com.tzld.piaoquan.longarticle.model.vo.LongArticleSystemContentItemVO;
+import com.tzld.piaoquan.longarticle.service.ContentService;
+import com.tzld.piaoquan.longarticle.service.KimiService;
+import com.tzld.piaoquan.longarticle.utils.*;
+import lombok.extern.slf4j.Slf4j;
+import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.*;
+import java.util.stream.Collectors;
+
+@Slf4j
+@Service
+public class ContentServiceImpl implements ContentService {
+
+    private static final HttpPoolClientUtil HTTP_POOL_CLIENT_UTIL_DEFAULT = HttpClientUtil.create(5000, 5000, 20, 100, 3, 3000);
+
+    @ApolloJsonValue("${testAccountLevel2:{}}")
+    private Map<String, Integer> ghIdMap;
+
+    @Autowired
+    private CrawlerVideoMapper crawlerVideoMapper;
+
+    public boolean submitMiniprogramCard(MiniprogramCardRequest request) {
+        String apiUrl = "http://47.99.132.47:8111/search_videos";
+        List<LongArticleSystemContentItemVO> contentItemList = new ArrayList<>();
+        try {
+            String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(request));
+            JSONObject jsonObject = JSON.parseObject(res);
+            Integer code = jsonObject.getInteger("code");
+            if (code == 0) {
+                return true;
+            }
+        } catch (Exception e) {
+            log.error("submitMiniprogramCard error", e);
+        }
+        return false;
+    }
+
+
+    public List<CrawlerVideo> getContentVideo(String contentId, String flowPoolLevel, String ghId) {
+        CrawlerVideoExample example = new CrawlerVideoExample();
+        example.setOrderByClause("score desc");
+        example.createCriteria().andDownloadStatusEqualTo(2).andContentIdEqualTo(contentId);
+        List<CrawlerVideo> crawlerVideoList = crawlerVideoMapper.selectByExample(example);
+        List<CrawlerVideo> videoList;
+        switch (flowPoolLevel) {
+            case "autoArticlePoolLevel4":
+                // 冷启层,全量做
+                videoList = shuffleList(crawlerVideoList).subList(0, Math.min(crawlerVideoList.size(), 3));
+                break;
+            case "autoArticlePoolLevel3":
+                //次条,只针对具体账号做
+                if (ghIdMap.containsKey(ghId)) {
+                    videoList = shuffleList(crawlerVideoList).subList(0, Math.min(crawlerVideoList.size(), 3));
+                } else {
+                    videoList = crawlerVideoList.subList(0, Math.min(crawlerVideoList.size(), 3));
+                }
+                break;
+            case "autoArticlePoolLevel1":
+                // 头条,先不做
+                videoList = crawlerVideoList.subList(0, Math.min(crawlerVideoList.size(), 3));
+                break;
+            default:
+                videoList = crawlerVideoList.subList(0, Math.min(crawlerVideoList.size(), 3));
+                break;
+        }
+
+        return videoList;
+    }
+
+    public static <T> List<T> shuffleList(List<T> oriList) {
+        // 使用 ArrayList 创建副本
+        List<T> shuffledList = new ArrayList<>(oriList);
+        Collections.shuffle(shuffledList); // 随机打乱列表
+        return shuffledList;
+    }
+
+}

+ 208 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/CoreServiceImpl.java

@@ -0,0 +1,208 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import com.tzld.piaoquan.longarticle.model.bo.*;
+import com.tzld.piaoquan.longarticle.model.dto.ArticleSortRequest;
+import com.tzld.piaoquan.longarticle.model.dto.ArticleSortResponse;
+import com.tzld.piaoquan.longarticle.model.dto.ArticleSortResponseData;
+import com.tzld.piaoquan.longarticle.model.dto.PublishArticleData;
+import com.tzld.piaoquan.longarticle.model.po.CrawlerVideo;
+import com.tzld.piaoquan.longarticle.model.po.LongArticlesText;
+import com.tzld.piaoquan.longarticle.model.vo.*;
+import com.tzld.piaoquan.longarticle.service.CoreService;
+import com.tzld.piaoquan.longarticle.utils.TimeZoneUtil;
+import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.ArrayList;
+import java.util.List;
+
+@Service
+public class CoreServiceImpl implements CoreService {
+
+    @Autowired
+    private PlanServiceImpl planService;
+
+    @Autowired
+    private SortServiceImpl sortService;
+
+    @Autowired
+    private ContentServiceImpl contentService;
+
+    @Autowired
+    private PublishServiceImpl publishService;
+
+    @Autowired
+    private KimiServiceImpl kimiService;
+
+    @Autowired
+    private CardServiceImpl cardService;
+
+    @Autowired
+    private CoverServiceImpl coverService;
+
+    public void core() {
+        List<PlanAccount> planAccounts = new ArrayList<>();
+
+        List<LongArticleSystemPlan> allLongArticleSystemPlans = planService.getAllLongArticleSystemPlan();
+//        for (LongArticleSystemPlan longArticleSystemPlan : allLongArticleSystemPlans) {
+//            //获取排序策略
+//            Map<String, String> sortStgMap = new HashMap<>();
+//            List<GzhArticleSortTaskParam> gzhArticleSortTask = longArticleSystemPlan.getGzhArticleSortTask();
+//            for (GzhArticleSortTaskParam gzhArticleSortTaskParam : gzhArticleSortTask) {
+//                String strategy = gzhArticleSortTaskParam.getStrategy();
+//                List<String> accountIds = gzhArticleSortTaskParam.getAccountIds();
+//                for (String accountId : accountIds) {
+//                    sortStgMap.put(accountId, strategy);
+//                }
+//            }
+//            //获取小程序策略
+//            Map<String, MiniprogramInsertTaskParam> miniStgMap = new HashMap<>();
+//            List<MiniprogramInsertTaskParam> miniprogramInsertTasks = longArticleSystemPlan.getMiniprogramInsertTasks();
+//            for (MiniprogramInsertTaskParam miniprogramInsertTaskParam : miniprogramInsertTasks) {
+//                List<String> accountIds = miniprogramInsertTaskParam.getAccountIds();
+//                for (String accountId : accountIds) {
+//                    miniStgMap.put(accountId, miniprogramInsertTaskParam);
+//                }
+//            }
+//            for (LongArticleSystemPlanAccount account : longArticleSystemPlan.getAccountList()) {
+//                PlanAccount planAccount = new PlanAccount();
+//                String accountId = account.getId();
+//                planAccount.setPlanId(longArticleSystemPlan.getId());
+//                planAccount.setPlanName(longArticleSystemPlan.getName());
+//                planAccount.setAccountId(accountId);
+//                planAccount.setAccountName(account.getName());
+//                planAccount.setGzhId(account.getGzhId());
+//                planAccount.setPublishNum(longArticleSystemPlan.getPublishNum());
+//                planAccount.setPublishPerMinNum(longArticleSystemPlan.getPublishPerMinNum());
+//                planAccount.setPublishPushTime(longArticleSystemPlan.getPublishPushTime());
+//                MiniprogramInsertTaskParam miniprogramInsertTaskParam = miniStgMap.get(accountId);
+//                if (miniprogramInsertTaskParam != null) {
+//                    planAccount.setMiniprogramUseType(miniprogramInsertTaskParam.getMiniprogramUseType());
+//                    planAccount.setMiniStrategy(miniprogramInsertTaskParam.getStrategy());
+//                } else {
+//                    planAccount.setMiniprogramUseType(1);
+//                    planAccount.setMiniStrategy("strategy_v1");
+//                }
+//                if (sortStgMap.containsKey(accountId)) {
+//                    planAccount.setSortStrategy(sortStgMap.get(accountId));
+//                } else {
+//                    planAccount.setSortStrategy("ArticleRankV1");
+//                }
+//                planAccount.setPushType(longArticleSystemPlan.getPushType());
+//                planAccounts.add(planAccount);
+//            }
+//        }
+
+//        for (PlanAccount planAccount : planAccounts) {
+//            LongArticleSystemGetContentsParam param = new LongArticleSystemGetContentsParam();
+//            param.setAccountId(param.getAccountId());
+//            param.setPlanId(planAccount.getPlanId());
+//            LongArticleSystemContentVO longArticleSystemContentVO = planService.listWaitingMatchMiniprogramContents(param);
+//            //TODO 调用匹配接口
+//
+//            //TODO 匹配成功后  通知AIGC
+//
+//        }
+
+        PlanAccount planAccount1 = new PlanAccount();
+        planAccount1.setAccountId("20231208111728193795195");
+        planAccount1.setAccountName("票圈大事件");
+        planAccount1.setGzhId("gh_9e559b3b94ca");
+        planAccount1.setPlanId("20241012140830436890740");
+        planAccount1.setPublishNum(8);
+        planAccount1.setMiniStrategy("strategy_v1");
+        planAccount1.setSortStrategy("ArticleRankV5");
+        planAccount1.setPublishPerMinNum(4);
+        planAccount1.setMiniprogramUseType(1);
+        planAccount1.setPushType(2);
+        planAccounts.add(planAccount1);
+
+
+        for (PlanAccount planAccount : planAccounts) {
+            ArticleSortRequest articleSortRequest = new ArticleSortRequest();
+            articleSortRequest.setAccountId(planAccount.getAccountId());
+            articleSortRequest.setAccountName(planAccount.getAccountName());
+            articleSortRequest.setGhId(planAccount.getGzhId());
+            articleSortRequest.setStrategy(planAccount.getSortStrategy());
+            articleSortRequest.setPublishNum(planAccount.getPublishNum());
+            articleSortRequest.setPlanId(planAccount.getPlanId());
+            articleSortRequest.setPushType(planAccount.getPushType());
+
+            ArticleSortResponse articleSortResponse = sortService.publishArticleSort(articleSortRequest);
+            ArticleSortResponseData data = articleSortResponse.getData();
+            if (data == null || CollectionUtils.isEmpty(data.getRank_list())) {
+                continue;
+            }
+            if (!CollectionUtils.isEmpty(data.getFilter_list())) {
+                List<FilterSortContentParam> list = new ArrayList<>();
+                for (PublishArticleData publishArticleData : data.getFilter_list()) {
+                    FilterSortContentParam param = new FilterSortContentParam();
+                    param.setFilterReason(publishArticleData.getFilterReason());
+                    param.setPublishContentId(publishArticleData.getId());
+                    list.add(param);
+                }
+                FilterSortParam param = new FilterSortParam();
+                param.setFilterSortContentList(list);
+                planService.filterSortContents(param);
+            }
+            List<LongArticleSystemPushContentParam> pushContentList = new ArrayList<>();
+            //排序结束
+            List<PublishArticleData> rankList = data.getRank_list();
+            for (PublishArticleData publishArticleData : rankList) {
+                LongArticleSystemPushContentParam contentParam = new LongArticleSystemPushContentParam();
+                String publishContentId = publishArticleData.getId();
+                List<CrawlerVideo> contentVideos =
+                        contentService.getContentVideo(publishArticleData.getSourceId(), publishArticleData.getContentPoolType(), planAccount.getGzhId());
+                List<VideoDetail> videoDetails = new ArrayList<>();
+                for (CrawlerVideo crawlerVideo : contentVideos) {
+                    String videoOssPath = crawlerVideo.getVideoOssPath();
+                    String platform = crawlerVideo.getPlatform();
+                    String userId = crawlerVideo.getUserId();
+                    String traceId = crawlerVideo.getTraceId();
+                    String kimiTitle;
+                    LongArticlesText kimiText = kimiService.getKimiText(crawlerVideo.getContentId());
+                    if (kimiText != null && StringUtils.isNotEmpty(kimiText.getKimiTitle())) {
+                        kimiTitle = kimiText.getKimiTitle();
+                    } else {
+                        kimiTitle = crawlerVideo.getVideoTitle();
+                    }
+                    VideoDetail publish = publishService.publish(videoOssPath, userId, kimiTitle, platform, traceId);
+                    if (publish == null) {
+                        continue;
+                    }
+                    videoDetails.add(publish);
+                }
+                if (videoDetails.size() < 2) {
+                    continue;
+                }
+                String gzhId = planAccount.getGzhId();
+                List<PublishMiniprogram> cardList = cardService.generateCards(gzhId, videoDetails, planAccount.getMiniprogramUseType(), publishContentId);
+                if (CollectionUtils.isEmpty(cardList)) {
+                    continue;
+                }
+                contentParam.setPublishContentId(publishContentId);
+                contentParam.setMiniprogramCardList(cardList);
+                pushContentList.add(contentParam);
+            }
+            LongArticleSystemCreatePushTaskParam gzhPushParam = new LongArticleSystemCreatePushTaskParam();
+            gzhPushParam.setPlanId(planAccount.getPlanId());
+            gzhPushParam.setAccountId(planAccount.getAccountId());
+            gzhPushParam.setPushType(planAccount.getPushType());
+            gzhPushParam.setPushScheduleTimestamp(System.currentTimeMillis());
+            if (StringUtils.isNotEmpty(planAccount.getPublishPushTime())) {
+                String dateTimeStr = TimeZoneUtil.todayYMD(TimeZoneUtil.Timezone.china) + " " + planAccount.getPublishPushTime();
+                gzhPushParam.setPushScheduleTimestamp(TimeZoneUtil.getDateStrTimestamp(dateTimeStr, "yyyy-MM-dd HH:mm:ss", TimeZoneUtil.Timezone.china));
+            } else {
+                gzhPushParam.setPushScheduleTimestamp(System.currentTimeMillis());
+            }
+            gzhPushParam.setPushContentList(pushContentList);
+            if (pushContentList.size() < planAccount.getPublishPerMinNum()) {
+                //TODO 数量不足
+            }
+            planService.createPushTask(gzhPushParam);
+        }
+
+    }
+}

+ 37 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/CoverServiceImpl.java

@@ -0,0 +1,37 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.tzld.piaoquan.longarticle.service.CoverService;
+import com.tzld.piaoquan.longarticle.utils.HttpClientUtil;
+import com.tzld.piaoquan.longarticle.utils.HttpPoolClientUtil;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+
+@Slf4j
+@Service
+public class CoverServiceImpl implements CoverService {
+
+    private static final HttpPoolClientUtil HTTP_POOL_CLIENT_UTIL_DEFAULT = HttpClientUtil.create(5000, 5000, 20, 100, 3, 3000);
+
+
+    public String pushCover(String coverUrl, String publishContentId) {
+        String apiUrl = "http://aigc-testapi.cybertogether.net/aigc//publish/LongArticleSystem/uploadMiniprogramCover";
+        try {
+            JSONObject param = new JSONObject();
+            param.put("coverUrl", coverUrl);
+            param.put("publishContentId", publishContentId);
+            String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSONObject.toJSONString(param));
+            JSONObject jsonObject = JSON.parseObject(res);
+            Integer code = jsonObject.getInteger("code");
+            if (code == 0) {
+                JSONObject data = jsonObject.getJSONObject("data");
+                return data.getString("wxUrl");
+            }
+            return null;
+        } catch (Exception e) {
+            log.error("getAllLongArticleSystemPlan error", e);
+        }
+        return null;
+    }
+}

+ 47 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/KimiServiceImpl.java

@@ -0,0 +1,47 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import com.tzld.piaoquan.longarticle.dao.mapper.LongArticlesTextMapper;
+import com.tzld.piaoquan.longarticle.model.po.LongArticlesText;
+import com.tzld.piaoquan.longarticle.model.po.LongArticlesTextExample;
+import com.tzld.piaoquan.longarticle.service.KimiService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.List;
+
+@Service
+public class KimiServiceImpl implements KimiService {
+
+    @Autowired
+    LongArticlesTextMapper longArticlesTextMapper;
+
+    @Override
+    public void addContent(String contentId, String articleTitle, String articleText) {
+
+        LongArticlesTextExample example = new LongArticlesTextExample();
+        example.createCriteria().andContentIdEqualTo(contentId);
+        long l = longArticlesTextMapper.countByExample(example);
+        if (l == 0) {
+            LongArticlesText longArticlesText = new LongArticlesText();
+            longArticlesText.setContentId(contentId);
+            longArticlesText.setArticleTitle(articleTitle);
+            longArticlesText.setArticleText(articleText);
+            longArticlesText.setKimiStatus(0);
+            longArticlesTextMapper.insertSelective(longArticlesText);
+        }
+        longArticlesTextMapper.selectByExample(example);
+
+    }
+
+    @Override
+    public LongArticlesText getKimiText(String contentId) {
+        LongArticlesTextExample example = new LongArticlesTextExample();
+        example.createCriteria().andContentIdEqualTo(contentId);
+        List<LongArticlesText> longArticlesTexts = longArticlesTextMapper.selectByExample(example);
+        if(CollectionUtils.isEmpty(longArticlesTexts)){
+            return null;
+        }
+        return longArticlesTexts.get(0);
+    }
+}

+ 255 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/MatchVideoServiceImpl.java

@@ -0,0 +1,255 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import cn.hutool.json.JSONObject;
+import com.alibaba.fastjson.JSONArray;
+import com.tzld.piaoquan.longarticle.dao.mapper.CrawlerVideoMapper;
+import com.tzld.piaoquan.longarticle.dao.mapper.MatchVideoMapper;
+import com.tzld.piaoquan.longarticle.model.po.*;
+import com.tzld.piaoquan.longarticle.model.vo.MatchVideoVo;
+import com.tzld.piaoquan.longarticle.service.KimiService;
+import com.tzld.piaoquan.longarticle.service.MatchVideoService;
+import com.tzld.piaoquan.longarticle.utils.*;
+import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.*;
+
+@Service
+public class MatchVideoServiceImpl implements MatchVideoService {
+
+    private static final int MAX_NUM = 3;
+
+    @Autowired
+    KimiService kimiService;
+
+    @Autowired
+    private MatchVideoMapper matchVideoMapper;
+
+    @Autowired
+    private CrawlerVideoMapper crawlerVideoMapper;
+
+    public void addMatchVideo(MatchVideoVo matchVideoVo) {
+        MatchVideoExample example = new MatchVideoExample();
+        example.createCriteria().andContentIdEqualTo(matchVideoVo.getArticleId()).andGhIdEqualTo(matchVideoVo.getGhId());
+        long l = matchVideoMapper.countByExample(example);
+        if (l > 0) {
+            return;
+        }
+        String traceId = "search-" + UUID.randomUUID();
+        MatchVideo matchVideo = new MatchVideo();
+        matchVideo.setTraceId(traceId);
+        matchVideo.setContentId(matchVideoVo.getArticleId());
+        matchVideo.setAccountName(matchVideoVo.getAccountName());
+        matchVideo.setFlowPoolLevel(matchVideo.getFlowPoolLevel());
+        matchVideo.setProcessTimes(1);
+        matchVideo.setContentStatus(0);
+        long timestamp = System.currentTimeMillis() / 1000;
+        matchVideo.setContentStatusUpdateTime(Long.valueOf(timestamp).intValue());
+        matchVideoMapper.insertSelective(matchVideo);
+    }
+
+    public void matchContent() {
+        CrawlerVideoExample example = new CrawlerVideoExample();
+        example.createCriteria().andDownloadStatusEqualTo(0);
+        crawlerVideoMapper.selectByExample(example);
+    }
+
+    public Boolean existHistoryContent(String contentId) {
+        CrawlerVideoExample example = new CrawlerVideoExample();
+        example.createCriteria().andContentIdEqualTo(contentId).andDownloadStatusEqualTo(2);
+        long l = crawlerVideoMapper.countByExample(example);
+        return l >= MAX_NUM;
+    }
+
+    public void pushOss(String traceId) {
+        CrawlerVideoExample example = new CrawlerVideoExample();
+        example.createCriteria().andTraceIdEqualTo(traceId).andDownloadStatusEqualTo(0);
+        List<CrawlerVideo> crawlerVideoList = crawlerVideoMapper.selectByExampleWithBLOBs(example);
+        if (CollectionUtils.isEmpty(crawlerVideoList)) {
+            return;
+        }
+        for (CrawlerVideo crawlerVideo : crawlerVideoList) {
+            String platform = crawlerVideo.getPlatform();
+            String outVideoId = crawlerVideo.getOutVideoId();
+            String videoPath = VideoDownloader.generateVideoPath(platform, outVideoId);
+            String coverPath = VideoDownloader.generateCoverPath(platform, outVideoId);
+            videoPath = VideoDownloader.downloadVideo(videoPath, platform, crawlerVideo.getVideoUrl(), "video");
+            coverPath = VideoDownloader.downloadCover(coverPath, platform, crawlerVideo.getCoverUrl());
+            if (StringUtils.isNotEmpty(videoPath) && StringUtils.isNotEmpty(coverPath)) {
+                String videoOssPath = OSSUploader.uploadToOSS(videoPath, "video");
+                String coverOssPath = OSSUploader.uploadToOSS(coverPath, "image");
+                if (StringUtils.isNotEmpty(videoOssPath) && StringUtils.isNotEmpty(coverOssPath)) {
+                    CrawlerVideo udpateCrawlerVideo = new CrawlerVideo();
+                    udpateCrawlerVideo.setVideoOssPath(videoOssPath);
+                    udpateCrawlerVideo.setCoverOssPath(coverOssPath);
+                    udpateCrawlerVideo.setId(crawlerVideo.getId());
+                    udpateCrawlerVideo.setDownloadStatus(2);
+                    crawlerVideoMapper.updateByPrimaryKeySelective(udpateCrawlerVideo);
+                }
+            }
+        }
+    }
+
+    public boolean addVideo(String contentId, String traceId) {
+        LongArticlesText kimiText = kimiService.getKimiText(contentId);
+        if (kimiText == null) {
+            //TODO 报警  KIMI查询不到
+            return false;
+        }
+        List<JSONObject> video = getVideo(contentId, kimiText);
+        List<JSONObject> jsonObjects = SortUtil.titleSimilarityRank(kimiText.getKimiTitle(), video);
+        List<CrawlerVideo> crawlerVideoList = getCrawlerVideoList(jsonObjects, traceId, contentId);
+        if (!CollectionUtils.isEmpty(crawlerVideoList)) {
+            for (CrawlerVideo crawlerVideo : crawlerVideoList) {
+                crawlerVideoMapper.insertSelective(crawlerVideo);
+            }
+        }
+        System.out.println();
+        System.out.println();
+        System.out.println(crawlerVideoList);
+        return false;
+    }
+
+    private List<CrawlerVideo> getCrawlerVideoList(List<JSONObject> jsonObjects, String traceId, String contentId) {
+        List<CrawlerVideo> crawlerVideoList = new ArrayList<>();
+        for (JSONObject jsonObject : jsonObjects) {
+            String platform = jsonObject.getStr("platform");
+            CrawlerVideo crawlerVideo = new CrawlerVideo();
+            crawlerVideo.setContentId(contentId);
+            crawlerVideo.setTraceId(traceId);
+            crawlerVideo.setPlatform(platform);
+            if (Objects.equals(platform, "dy_search")) {
+                crawlerVideo.setOutVideoId(jsonObject.getStr("channel_content_id"));
+                crawlerVideo.setVideoTitle(jsonObject.getStr("title"));
+                crawlerVideo.setPublishTime(jsonObject.getDate("publish_timestamp"));
+                List<JSONObject> videoUrlList = jsonObject.get("video_url_list", List.class);
+                if (!CollectionUtils.isEmpty(videoUrlList)) {
+                    crawlerVideo.setVideoUrl(videoUrlList.get(0).getStr("video_url"));
+                    crawlerVideo.setDuration(videoUrlList.get(0).getInt("video_duration"));
+                }
+                List<JSONObject> imageUrlList = jsonObject.get("image_url_list", List.class);
+                if (!CollectionUtils.isEmpty(imageUrlList)) {
+                    crawlerVideo.setCoverUrl(imageUrlList.get(0).getStr("image_url"));
+                }
+                crawlerVideo.setPlayCount(jsonObject.getInt("play_count"));
+                crawlerVideo.setLikeCount(jsonObject.getInt("like_count"));
+                crawlerVideo.setScore(jsonObject.getFloat("score"));
+                if (cheakCrawlerVideo(crawlerVideo)) {
+                    crawlerVideoList.add(crawlerVideo);
+                }
+
+                continue;
+            }
+            if (Objects.equals(platform, "baidu_search")) {
+                crawlerVideo.setOutVideoId(jsonObject.getStr("id"));
+                crawlerVideo.setVideoTitle(jsonObject.getStr("title"));
+                crawlerVideo.setPublishTime(jsonObject.getDate("publish_timestamp"));
+                crawlerVideo.setVideoUrl(jsonObject.getStr("playurl"));
+                crawlerVideo.setCoverUrl(jsonObject.getStr("poster"));
+                crawlerVideo.setPlayCount(jsonObject.getInt("play_cnt"));
+                crawlerVideo.setLikeCount(jsonObject.getInt("like_count") == null ? 0 : jsonObject.getInt("like_count"));
+                crawlerVideo.setDuration(jsonObject.getInt("duration"));
+                crawlerVideo.setScore(jsonObject.getFloat("score"));
+                if (cheakCrawlerVideo(crawlerVideo)) {
+                    crawlerVideoList.add(crawlerVideo);
+                }
+                continue;
+            }
+        }
+        return crawlerVideoList;
+    }
+
+    private boolean cheakCrawlerVideo(CrawlerVideo crawlerVideo) {
+        if (StringUtils.isEmpty(crawlerVideo.getOutVideoId())) {
+            return false;
+        }
+        if (StringUtils.isEmpty(crawlerVideo.getVideoUrl())) {
+            return false;
+        }
+        if (StringUtils.isEmpty(crawlerVideo.getCoverUrl())) {
+            return false;
+        }
+        if (StringUtils.isEmpty(crawlerVideo.getPlatform())) {
+            return false;
+        }
+        if (Objects.isNull(crawlerVideo.getPublishTime())) {
+            crawlerVideo.setPublishTime(new Date());
+        }
+        if (Objects.isNull(crawlerVideo.getDuration())) {
+            crawlerVideo.setDuration(0);
+        }
+        if (Objects.isNull(crawlerVideo.getPlayCount())) {
+            crawlerVideo.setPlayCount(0);
+        }
+        if (Objects.isNull(crawlerVideo.getLikeCount())) {
+            crawlerVideo.setLikeCount(0);
+        }
+        if (Objects.isNull(crawlerVideo.getShareCount())) {
+            crawlerVideo.setShareCount(0);
+        }
+        return true;
+    }
+
+    public List<JSONObject> getVideo(String contentId, LongArticlesText kimiText) {
+
+        List<JSONObject> res = new ArrayList<>();
+        List<JSONObject> kimiSummarys = searchVideo(kimiText.getKimiSummary().substring(0, 15), new ArrayList<>(), "");
+        if (!CollectionUtils.isEmpty(kimiSummarys)) {
+            res.addAll(kimiSummarys);
+        }
+        if (res.size() > 3) {
+            return res;
+        }
+        List<JSONObject> kimiTitles = searchVideo(kimiText.getKimiTitle().substring(0, 15), new ArrayList<>(), "");
+        if (!CollectionUtils.isEmpty(kimiTitles)) {
+            res.addAll(kimiTitles);
+        }
+        if (res.size() > 3) {
+            return res;
+        }
+        String kimiKeys = kimiText.getKimiKeys();
+        JSONArray jsonArray = JSONArray.parseArray(kimiKeys);
+        if (jsonArray == null || jsonArray.isEmpty()) {
+            return res;
+        }
+        for (int i = 0; i < jsonArray.size(); i++) {
+            String key = jsonArray.getString(i);
+            List<JSONObject> keys = searchVideo(key, new ArrayList<>(), "");
+            if (!CollectionUtils.isEmpty(keys)) {
+                res.addAll(keys);
+            }
+            if (res.size() > 3) {
+                return res;
+            }
+        }
+        return res;
+    }
+
+
+    public List<JSONObject> searchVideo(String keyword, List<String> words, String traceId) {
+        List<JSONObject> jsonObjects = DouyinSearch.douyinSearch(keyword, words, traceId);
+        if (!CollectionUtils.isEmpty(jsonObjects)) {
+            for (JSONObject jsonObject : jsonObjects) {
+                jsonObject.put("platform", "dy_search");
+            }
+        }
+        if (jsonObjects.size() >= 3) {
+            return jsonObjects;
+        }
+        List<JSONObject> jsonObjects1 = HkspSearch.hkspSearch(keyword, words, traceId);
+        if (CollectionUtils.isEmpty(jsonObjects1)) {
+            return jsonObjects;
+        }
+        for (JSONObject jsonObject : jsonObjects1) {
+            jsonObject.put("platform", "baidu_search");
+        }
+        if (CollectionUtils.isEmpty(jsonObjects)) {
+            return jsonObjects1;
+        }
+        jsonObjects.addAll(jsonObjects1);
+        return jsonObjects;
+    }
+
+}

+ 117 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/PlanServiceImpl.java

@@ -0,0 +1,117 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONArray;
+import com.alibaba.fastjson.JSONObject;
+import com.tzld.piaoquan.longarticle.model.bo.LongArticleSystemPlan;
+import com.tzld.piaoquan.longarticle.model.vo.*;
+import com.tzld.piaoquan.longarticle.utils.HttpClientUtil;
+import com.tzld.piaoquan.longarticle.utils.HttpPoolClientUtil;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.ArrayList;
+import java.util.List;
+
+@Slf4j
+@Service
+public class PlanServiceImpl {
+
+    private static final HttpPoolClientUtil HTTP_POOL_CLIENT_UTIL_DEFAULT = HttpClientUtil.create(5000, 5000, 20, 100, 3, 3000);
+
+
+    public List<LongArticleSystemPlan> getAllLongArticleSystemPlan() {
+        String apiUrl = "http://aigc-testapi.cybertogether.net/aigc/publish/LongArticleSystem/getAllLongArticleSystemPlan";
+        try {
+            String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl);
+            JSONObject jsonObject = JSON.parseObject(res);
+            Integer code = jsonObject.getInteger("code");
+            if (code == 0) {
+                JSONArray data = jsonObject.getJSONArray("data");
+                List<LongArticleSystemPlan> list = data.toJavaList(LongArticleSystemPlan.class);
+                return list;
+            }
+            return null;
+        } catch (Exception e) {
+            log.error("getAllLongArticleSystemPlan error", e);
+        }
+        return null;
+    }
+
+    public List<LongArticleSystemContentItemVO> getContentItemList(LongArticleSystemGetContentsParam param) {
+        List<LongArticleSystemContentItemVO> contentItemList = new ArrayList<>();
+        int pageNum = 1;
+        int pageSize = 500;
+        param.setPageNum(pageNum);
+        param.setPageSize(pageSize);
+        LongArticleSystemContentVO longArticleSystemContentVO = listWaitingMatchMiniprogramContents(param);
+        if (longArticleSystemContentVO == null) {
+            return new ArrayList<>();
+        }
+        if (!CollectionUtils.isEmpty(longArticleSystemContentVO.getContentItemList())) {
+            contentItemList.addAll(longArticleSystemContentVO.getContentItemList());
+        }
+        Long totalCount = longArticleSystemContentVO.getTotalCount();
+        while ((long) pageNum * pageSize < totalCount) {
+            pageNum++;
+            param.setPageNum(pageNum);
+            LongArticleSystemContentVO longArticleSystemContentVO1 = listWaitingMatchMiniprogramContents(param);
+            if (longArticleSystemContentVO1 != null && !CollectionUtils.isEmpty(longArticleSystemContentVO.getContentItemList())) {
+                contentItemList.addAll(longArticleSystemContentVO.getContentItemList());
+            }
+        }
+        return contentItemList;
+    }
+
+    public LongArticleSystemContentVO listWaitingMatchMiniprogramContents(LongArticleSystemGetContentsParam param) {
+        String apiUrl = "http://aigc-api.cybertogether.net/publish/LongArticleSystem/listWaitingMatchMiniprogramContents";
+        List<LongArticleSystemContentItemVO> contentItemList = new ArrayList<>();
+        try {
+            String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
+            JSONObject jsonObject = JSON.parseObject(res);
+            Integer code = jsonObject.getInteger("code");
+            if (code == 0) {
+                LongArticleSystemContentVO longArticleSystemContentVO = jsonObject.getJSONObject("data").toJavaObject(LongArticleSystemContentVO.class);
+                return longArticleSystemContentVO;
+            }
+        } catch (Exception e) {
+            log.error("listWaitingMatchMiniprogramContents error", e);
+        }
+        return null;
+    }
+
+    public boolean createPushTask(LongArticleSystemCreatePushTaskParam param) {
+        String apiUrl = "http://aigc-api.cybertogether.net/publish/LongArticleSystem/uploadMiniprogramCover";
+        List<LongArticleSystemContentItemVO> contentItemList = new ArrayList<>();
+        try {
+            String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
+            JSONObject jsonObject = JSON.parseObject(res);
+            Integer code = jsonObject.getInteger("code");
+            if (code == 0) {
+                return true;
+            }
+        } catch (Exception e) {
+            log.error("listWaitingMatchMiniprogramContents error", e);
+        }
+        return false;
+    }
+
+    public boolean filterSortContents(FilterSortParam param) {
+        String apiUrl = "http://aigc-api.cybertogether.net/publish/LongArticleSystem/filterSortContents";
+        List<LongArticleSystemContentItemVO> contentItemList = new ArrayList<>();
+        try {
+            String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
+            JSONObject jsonObject = JSON.parseObject(res);
+            Integer code = jsonObject.getInteger("code");
+            if (code == 0) {
+                return true;
+            }
+        } catch (Exception e) {
+            log.error("listWaitingMatchMiniprogramContents error", e);
+        }
+        return false;
+    }
+
+
+}

+ 97 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/PublishServiceImpl.java

@@ -0,0 +1,97 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+import cn.hutool.http.HttpRequest;
+import cn.hutool.http.HttpResponse;
+import cn.hutool.json.JSONObject;
+import cn.hutool.json.JSONUtil;
+import com.tzld.piaoquan.longarticle.model.bo.VideoDetail;
+import com.tzld.piaoquan.longarticle.service.PublishService;
+import org.apache.commons.lang3.StringUtils;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+@Service
+public class PublishServiceImpl implements PublishService {
+
+
+    public VideoDetail publish(String ossPath, String uid, String title, String platform, String traceId) {
+        String videoId = publishToPQ(ossPath, uid, title);
+        if (videoId == null) {
+            return null;
+        }
+        VideoDetail videoDetail = getPQVideoDetail(videoId);
+        videoDetail.setKimiTitle(title);
+        videoDetail.setUid(uid);
+        videoDetail.setVideoOss(ossPath);
+        videoDetail.setSource(platform);
+        videoDetail.setTraceId(traceId);
+        return videoDetail;
+    }
+
+    private static final String PUBLISH_URL = "https://vlogapi.piaoquantv.com/longvideoapi/crawler/video/send";
+    private static final String VIDEO_DETAIL_URL = "https://longvideoapi.piaoquantv.com/longvideoapi/openapi/video/batchSelectVideoInfo";
+
+    public String publishToPQ(String ossPath, String uid, String title) {
+
+        Map<String, Object> payload = new HashMap<>();
+        payload.put("deviceToken", "9ef064f2f7869b3fd67d6141f8a899175dddc91240971172f1f2a662ef891408");
+        payload.put("fileExtensions", "MP4");
+        payload.put("loginUid", uid);
+        payload.put("networkType", "Wi-Fi");
+        payload.put("platform", "iOS");
+        payload.put("requestId", "fb972cbd4f390afcfd3da1869cd7d001");
+        payload.put("sessionId", "362290597725ce1fa870d7be4f46dcc2");
+        payload.put("subSessionId", "362290597725ce1fa870d7be4f46dcc2");
+        payload.put("title", title);
+        payload.put("token", "524a8bc871dbb0f4d4717895083172ab37c02d2f");
+        payload.put("uid", uid);
+        payload.put("versionCode", "486");
+        payload.put("versionName", "3.4.12");
+        payload.put("videoFromScene", "1");
+        payload.put("videoPath", ossPath);
+        payload.put("viewStatus", "1");
+        payload.put("appType", 888880);
+        payload.put("repeatStatus", 1);
+
+        HttpResponse response = HttpRequest.post(PUBLISH_URL)
+                .header("User-Agent", "PQSpeed/486 CFNetwork/1410.1 Darwin/22.6.0")
+                .header("cookie", "JSESSIONID=4DEA2B5173BB9A9E82DB772C0ACDBC9F; JSESSIONID=D02C334150025222A0B824A98B539B78")
+                .header("referer", "http://appspeed.piaoquantv.com")
+                .header("accept-language", "zh-CN,zh-Hans;q=0.9")
+                .header("Content-Type", "application/x-www-form-urlencoded")
+                .form(payload) // 发送表单数据
+                .execute();
+        String body = response.body();
+        JSONObject jsonObject = JSONUtil.parseObj(body);
+        String videoId = jsonObject.getByPath("data.id", String.class);
+        return videoId; // 返回响应体
+    }
+
+    public VideoDetail getPQVideoDetail(String videoId) {
+        Map<String, Object> data = new HashMap<>();
+        data.put("videoIdList", new String[]{videoId});
+
+        HttpResponse response = HttpRequest.post(VIDEO_DETAIL_URL)
+                .header("Content-Type", "application/json")
+                .body(JSONUtil.toJsonStr(data)) // 将数据转换为 JSON 字符串
+                .execute();
+        VideoDetail videoDetail = new VideoDetail();
+        JSONObject jsonObject = JSONUtil.parseObj(response.body());
+        List<JSONObject> list = jsonObject.get("data", List.class);
+        if (!CollectionUtils.isEmpty(data)) {
+            String id = list.get(0).getStr("id");
+            String shareImgPath = list.get(0).getStr("shareImgPath");
+            String videoPath = list.get(0).getStr("videoPath");
+            if (StringUtils.isNotEmpty(id)) {
+                videoDetail.setVideoId(id);
+            }
+            videoDetail.setVideoCover(shareImgPath);
+            videoDetail.setVideoPath(videoPath);
+        }
+        return videoDetail;
+    }
+}

+ 47 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/service/impl/SortServiceImpl.java

@@ -0,0 +1,47 @@
+package com.tzld.piaoquan.longarticle.service.impl;
+
+
+import cn.hutool.core.collection.CollectionUtil;
+import com.alibaba.fastjson.JSON;
+import com.tzld.piaoquan.longarticle.model.dto.ArticleSortRequest;
+import com.tzld.piaoquan.longarticle.model.dto.ArticleSortResponse;
+import com.tzld.piaoquan.longarticle.utils.HttpClientUtil;
+import com.tzld.piaoquan.longarticle.utils.HttpPoolClientUtil;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+
+import java.io.IOException;
+import java.util.Objects;
+
+@Slf4j
+@Service
+public class SortServiceImpl {
+
+    private static final HttpPoolClientUtil HTTP_POOL_CLIENT_UTIL_DEFAULT = HttpClientUtil.create(5000, 200000, 20, 100, 3, 3000);
+
+    public ArticleSortResponse publishArticleSort(ArticleSortRequest request) {
+        ArticleSortResponse response = new ArticleSortResponse();
+        String apiUrl = "http://101.37.174.139:80/recommend";
+        int retryTimes = 2;
+        while (retryTimes > 0) {
+            try {
+                retryTimes--;
+                log.info("publishArticleSort,request:{}", JSON.toJSONString(request));
+                String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(request));
+                log.info("publishArticleSort recommend Api返回数据:{}", res);
+
+                response = JSON.parseObject(res, ArticleSortResponse.class);
+                if (Objects.nonNull(response) && Objects.nonNull(response.getData())) {
+                    response.setSuccessful(true);
+                    if (CollectionUtil.isNotEmpty(response.getData().getRank_list())) {
+                        break;
+                    }
+                }
+            } catch (Exception e) {
+                log.error("publishArticleSort recommend response parseObject", e);
+            }
+        }
+        return response;
+    }
+
+}

+ 44 - 45
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/DouyinSearch.java

@@ -8,51 +8,53 @@ import java.util.List;
 
 public class DouyinSearch {
 
-    public static List<JSONObject> douyinSearch(String keyword, String sensitiveWords, String traceId) {
-        String url = "http://8.217.190.241:8888/crawler/dou_yin/top_hub_content";
-        JSONObject payload = new JSONObject();
-        payload.put("keyword", keyword);
-        payload.put("category", "全部");
-        payload.put("period", "近90天");
-        payload.put("content_modal", "视频");
-        payload.put("cursor", "");
-
-        HttpResponse response = HttpRequest.post(url)
-                .header("Content-Type", "application/json")
-                .body(payload.toString())
-                .execute();
-
-        List<JSONObject> resultList = new ArrayList<>();
-
-        try {
-            JSONObject jsonResponse = JSONUtil.parseObj(response.body());
-            List<JSONObject> dtList = jsonResponse.getByPath("data.data", List.class);
-
-            for (JSONObject obj : dtList) {
-                try {
-                    String title = obj.getStr("video_desc");
-                    String videoId = obj.getStr("video_id");
-                    int duration = obj.getInt("duration");
-
-                    if (sensitiveFlag(sensitiveWords, title) && duration < 30000) {
-                        JSONObject res = douyinDetail(videoId);
-                        if (res != null) {
-                            resultList.add(res);
-                        }
-                    }
-                } catch (Exception e) {
-                    System.out.println(e.getMessage());
-                    // 处理异常
-                }
-            }
-
-            return resultList;
-        } catch (Exception e) {
-            return new ArrayList<>();
-        }
+    public static List<JSONObject> douyinSearch(String keyword, List<String> sensitiveWords, String traceId) {
+        return new ArrayList<>();
+//        String url = "http://8.217.190.241:8888/crawler/dou_yin/top_hub_content";
+//        JSONObject payload = new JSONObject();
+//        payload.put("keyword", keyword);
+//        payload.put("category", "全部");
+//        payload.put("period", "近90天");
+//        payload.put("content_modal", "视频");
+//        payload.put("cursor", "");
+//
+//        HttpResponse response = HttpRequest.post(url)
+//                .header("Content-Type", "application/json")
+//                .body(payload.toString())
+//                .execute();
+//
+//        List<JSONObject> resultList = new ArrayList<>();
+//
+//        try {
+//            JSONObject jsonResponse = JSONUtil.parseObj(response.body());
+//            List<JSONObject> dtList = jsonResponse.getByPath("data.data", List.class);
+//
+//            for (JSONObject obj : dtList) {
+//                try {
+//                    String title = obj.getStr("video_desc");
+//                    String videoId = obj.getStr("video_id");
+//                    int duration = obj.getInt("duration");
+//
+//                    if (sensitiveFlag(sensitiveWords.toString(), title) && duration < 30000) {
+//                        JSONObject res = douyinDetail(videoId);
+//                        if (res != null) {
+//                            resultList.add(res);
+//                        }
+//                    }
+//                } catch (Exception e) {
+//                    System.out.println(e.getMessage());
+//                    // 处理异常
+//                }
+//            }
+//
+//            return resultList;
+//        } catch (Exception e) {
+//            return new ArrayList<>();
+//        }
     }
 
     public static JSONObject douyinDetail(String videoId) {
+        System.out.println(videoId);
         String url = "http://8.217.190.241:8888/crawler/dou_yin/detail";
         JSONObject payload = new JSONObject();
         payload.put("content_id", videoId);
@@ -76,9 +78,6 @@ public class DouyinSearch {
         return true; // 示例
     }
 
-    public static void main(String[] args) {
-        System.out.println(douyinSearch("美女", "", ""));
-    }
 }
 
 

+ 1 - 1
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/getContentUtil.java → long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/GetContentUtil.java

@@ -5,7 +5,7 @@ import org.apache.commons.lang3.StringUtils;
 
 import java.util.Objects;
 
-public class getContentUtil {
+public class GetContentUtil {
     public static void main(String[] args) {
         String articleTitle = "中国宣布重大消息,韩国被吓,美国不服气,俄罗斯和朝鲜都笑了!";
         String articleContent = "在当前国际政治舞台上,中朝关系、朝鲜半岛安全局势以及广泛的国际政治关系如同一副错综复杂的画卷,引人注目。\n" +

+ 55 - 91
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/HkspSearch.java

@@ -6,10 +6,7 @@ import cn.hutool.json.JSONObject;
 import cn.hutool.json.JSONUtil;
 
 import java.io.IOException;
-import java.net.Authenticator;
-import java.net.InetSocketAddress;
-import java.net.PasswordAuthentication;
-import java.net.Proxy;
+import java.net.*;
 import java.security.MessageDigest;
 import java.security.NoSuchAlgorithmException;
 import java.util.ArrayList;
@@ -19,59 +16,48 @@ import java.util.UUID;
 
 public class HkspSearch {
 
-
-
-    public static void main(String[] args) throws IOException {
-        System.out.println(hkspSearch("测试", "", "ccc"));
-
-    }
-
-    public static List<JSONObject> hkspSearch(String key, String sensitiveWords, String traceId) throws IOException {
-        long timestampMilliseconds = System.currentTimeMillis();
-        String url = "https://haokan.baidu.com/haokan/ui-search/pc/search/video";
-
-        // 生成签名
-        String strings = String.format("%d_%s_%d_%d_%d", 1, key, 10, timestampMilliseconds, 1);
-        String sign = md5(strings);
-
-        JSONObject params = new JSONObject();
-        params.put("pn", 1);
-        params.put("rn", 10);
-        params.put("type", "video");
-        params.put("query", key);
-        params.put("sign", sign);
-        params.put("version", 1);
-        params.put("timestamp", timestampMilliseconds);
-
-        String base64String = Base64.getEncoder().encodeToString(UUID.randomUUID().toString().getBytes());
-
-        // 这行代码是身份验证的关键配置,不然身份验证不起作用
-        System.setProperty("jdk.http.auth.tunneling.disabledSchemes", "");
-        // 身份验证
-        Authenticator.setDefault(
-                new Authenticator() {
-                    public PasswordAuthentication getPasswordAuthentication() {
-                        return new PasswordAuthentication(
-                                "t11983523373311", "mtuhdr2z".toCharArray());
-                    }
-                }
-        );
-        // 设置代理服务器
-        Proxy proxy = new Proxy(Proxy.Type.HTTP, new InetSocketAddress("l901.kdltps.com", 15818));
-        HttpResponse response = HttpRequest.get(url)
-                .header("authority", "haokan.baidu.com")
-                .header("accept", "*/*")
-                .header("accept-language", "zh,en;q=0.9,zh-CN;q=0.8")
-                .header("cookie", "BIDUPSID=" + base64String)
-                .header("user-agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/122.0.0.0 Safari/537.36 Edg/122.0.0.0") // 假用户代理
-                .header("x-requested-with", "xmlhttprequest")
-                .timeout(120000) // 设置超时时间
-//                .setProxy(proxy)
-                .form(params)
-                .execute();
-
-        List<JSONObject> resultList = new ArrayList<>();
+    public static List<JSONObject> hkspSearch(String key, List<String> sensitiveWords, String traceId) {
         try {
+            long timestampMilliseconds = System.currentTimeMillis();
+            String url = "https://haokan.baidu.com/haokan/ui-search/pc/search/video";
+            String encodedKey = URLEncoder.encode(key, "UTF-8");
+            String strings = String.format("%d_%s_%d_%d_%d", 1, encodedKey, 10, timestampMilliseconds, 1);
+            String sign = md5(strings);
+
+            JSONObject params = new JSONObject();
+            params.put("pn", 1);
+            params.put("rn", 10);
+            params.put("type", "video");
+            params.put("query", key);
+            params.put("sign", sign);
+            params.put("version", 1);
+            params.put("timestamp", timestampMilliseconds);
+
+            String base64String = Base64.getEncoder().encodeToString(UUID.randomUUID().toString().getBytes());
+            // 这行代码是身份验证的关键配置,不然身份验证不起作用
+            System.setProperty("jdk.http.auth.tunneling.disabledSchemes", "");
+            // 身份验证
+            Authenticator.setDefault(
+                    new Authenticator() {
+                        public PasswordAuthentication getPasswordAuthentication() {
+                            return new PasswordAuthentication(
+                                    "t11983523373311", "mtuhdr2z".toCharArray());
+                        }
+                    }
+            );
+            HttpResponse response = HttpRequest.get(url)
+                    .header("authority", "haokan.baidu.com")
+                    .header("accept", "*/*")
+                    .header("accept-language", "zh,en;q=0.9,zh-CN;q=0.8")
+                    .header("cookie", "BIDUPSID=" + base64String)
+                    .header("user-agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/122.0.0.0 Safari/537.36 Edg/122.0.0.0") // 假用户代理
+                    .header("x-requested-with", "xmlhttprequest")
+                    .timeout(120000) // 设置超时时间
+                    .setProxy(new Proxy(Proxy.Type.HTTP, new InetSocketAddress("l901.kdltps.com", 15818)))
+                    .form(params)
+                    .execute();
+
+            List<JSONObject> resultList = new ArrayList<>();
             System.out.println(response.body());
             JSONObject jsonResponse = JSONUtil.parseObj(response.body());
             List<JSONObject> dataList = jsonResponse.getByPath("data.list", List.class);
@@ -93,10 +79,8 @@ public class HkspSearch {
                 }
             }
 
-            logging(traceId, key, dataList.size(), resultList.size());
             return resultList;
         } catch (Exception e) {
-            logging(traceId, key, e.getMessage());
             return new ArrayList<>();
         }
     }
@@ -120,19 +104,11 @@ public class HkspSearch {
         }
     }
 
-    private static boolean sensitiveFlag(String sensitiveWords, String title) {
+    private static boolean sensitiveFlag(List<String> sensitiveWords, String title) {
         // 实现敏感词检查逻辑
         return true; // 示例
     }
 
-    private static void logging(String traceId, String key, int searchCount, int usefulCount) {
-        // 实现日志记录逻辑
-    }
-
-    private static void logging(String traceId, String key, String message) {
-        // 实现日志记录逻辑
-    }
-
     public static JSONObject getVideoDetail(String videoId) {
 
 
@@ -142,8 +118,18 @@ public class HkspSearch {
         params.put("_format", "json");
 
         String base64String = Base64.getEncoder().encodeToString(UUID.randomUUID().toString().getBytes());
-        HttpRequest proxyHttpRequest = getProxyHttpRequest(url);
-        HttpResponse response = proxyHttpRequest
+        // 这行代码是身份验证的关键配置,不然身份验证不起作用
+        System.setProperty("jdk.http.auth.tunneling.disabledSchemes", "");
+        // 身份验证
+        Authenticator.setDefault(
+                new Authenticator() {
+                    public PasswordAuthentication getPasswordAuthentication() {
+                        return new PasswordAuthentication(
+                                "t11983523373311", "mtuhdr2z".toCharArray());
+                    }
+                }
+        );
+        HttpResponse response = HttpRequest.get(url)
                 .header("Accept", "*/*")
                 .header("cookie", "BIDUPSID=" + base64String)
                 .header("Accept-Language", "en,zh;q=0.9,zh-CN;q=0.8")
@@ -152,32 +138,10 @@ public class HkspSearch {
                 .header("Content-Type", "application/x-www-form-urlencoded")
                 .header("Referer", "https://haokan.baidu.com")
                 .form(params)
-
                 .setProxy(new Proxy(Proxy.Type.HTTP, new InetSocketAddress("l901.kdltps.com", 15818)))
-                .basicProxyAuth("t11983523373311", "mtuhdr2z")
                 .execute();
 
         return JSONUtil.parseObj(response.body()).getByPath("data.apiData.curVideoMeta", JSONObject.class);
     }
 
-    public static HttpRequest getProxyHttpRequest(String url) {
-
-        // 代理的地址和端口
-        String proxyHost = "l901.kdltps.com";
-        int proxyPort = 15818;
-
-        // 用户名和密码
-        String username = "t11983523373311"; // 替换为你的用户名
-        String password = "mtuhdr2z"; // 替换为你的密码
-
-        // 创建代理请求
-        String proxyUrl = String.format("https://%s:%s@%s:%d", username, password, proxyHost, proxyPort);
-
-        // 发送请求
-        HttpRequest httpRequest = HttpRequest.get(url) // 替换为你要请求的 URL
-                .proxyAuth(proxyUrl);
-        return httpRequest;
-    }
-
-
 }

+ 90 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/HttpClientUtil.java

@@ -0,0 +1,90 @@
+package com.tzld.piaoquan.longarticle.utils;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.concurrent.locks.Lock;
+import java.util.concurrent.locks.ReentrantLock;
+
+/**
+ * http util
+ *
+ * @author xueyiming
+ */
+public class HttpClientUtil {
+
+    private static final String DEFAULT_SHARED_KEY = "DEFAULT_SHARED_KEY";
+
+    /**
+     * 链接建立的超时时间 ms
+     */
+    private static final int DEFAULT_CONNECTION_TIMEOUT = 3000;
+    /**
+     * 响应超时时间 ms
+     */
+    private static final int DEFAULT_SOCKET_TIMEOUT = 3000;
+
+    /**
+     * 每个路由的最大连接数
+     */
+    private static final int DEFAULT_DEFAULT_MAX_PER_ROUTE = 50;
+
+    /**
+     * 最大连接数
+     */
+    private static final int DEFAULT_DEFAULT_MAX_TOTAL = 200;
+
+    /**
+     * 重试次数,默认0
+     */
+    private static final int DEFAULT_RETRY_COUNT = 5;
+
+    /**
+     * 从connection pool中获得一个connection的超时时间 ms
+     */
+    private static final int DEFAULT_CONNECTION_WAIT_TIMEOUT = 300;
+
+    private static final Map<String, HttpPoolClientUtil> CREATED_HTTP_CLIENTS = new HashMap<>();
+
+    private static final Lock LOCK = new ReentrantLock();
+
+    private HttpClientUtil() {
+    }
+
+    public static HttpPoolClientUtil useDefault() {
+        return createCached(DEFAULT_SHARED_KEY);
+    }
+
+
+    public static HttpPoolClientUtil createCached(String cachedKey) {
+        HttpPoolClientUtil httpPoolClientUtil = CREATED_HTTP_CLIENTS.get(cachedKey);
+        if (httpPoolClientUtil != null) {
+            return httpPoolClientUtil;
+        }
+        LOCK.lock();
+        try {
+            httpPoolClientUtil = CREATED_HTTP_CLIENTS.get(cachedKey);
+            if (httpPoolClientUtil == null) {
+                httpPoolClientUtil = create(DEFAULT_CONNECTION_TIMEOUT, DEFAULT_SOCKET_TIMEOUT, DEFAULT_DEFAULT_MAX_PER_ROUTE, DEFAULT_DEFAULT_MAX_TOTAL, DEFAULT_RETRY_COUNT, DEFAULT_CONNECTION_WAIT_TIMEOUT);
+                CREATED_HTTP_CLIENTS.put(cachedKey, httpPoolClientUtil);
+            }
+        } finally {
+            LOCK.unlock();
+        }
+        return httpPoolClientUtil;
+    }
+
+    /**
+     * 创建httpclient
+     *
+     * @param connectTimeout        连接超时时间 ms
+     * @param socketTimeout         读超时时间(等待数据超时时间)ms
+     * @param maxPerRoute           每个路由的最大连接数
+     * @param maxTotal              最大连接数
+     * @param retryCount            重试次数
+     * @param connectionWaitTimeout 连接等待超市时间 ms
+     * @return httpclient instance
+     */
+    public static HttpPoolClientUtil create(int connectTimeout, int socketTimeout, int maxPerRoute, int maxTotal, int retryCount, int connectionWaitTimeout) {
+        return HttpPoolClientUtil.create(connectTimeout, socketTimeout, maxPerRoute, maxTotal, retryCount, connectionWaitTimeout);
+    }
+}

+ 193 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/HttpPoolClientUtil.java

@@ -0,0 +1,193 @@
+package com.tzld.piaoquan.longarticle.utils;
+
+import com.google.common.collect.Lists;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.concurrent.BasicThreadFactory;
+import org.apache.http.HttpEntity;
+import org.apache.http.HttpRequestInterceptor;
+import org.apache.http.HttpStatus;
+import org.apache.http.client.config.RequestConfig;
+import org.apache.http.client.methods.*;
+import org.apache.http.config.Registry;
+import org.apache.http.config.RegistryBuilder;
+import org.apache.http.conn.HttpClientConnectionManager;
+import org.apache.http.conn.socket.ConnectionSocketFactory;
+import org.apache.http.conn.socket.PlainConnectionSocketFactory;
+import org.apache.http.conn.ssl.NoopHostnameVerifier;
+import org.apache.http.conn.ssl.SSLConnectionSocketFactory;
+import org.apache.http.entity.StringEntity;
+import org.apache.http.entity.mime.MultipartEntityBuilder;
+import org.apache.http.impl.client.CloseableHttpClient;
+import org.apache.http.impl.client.DefaultHttpRequestRetryHandler;
+import org.apache.http.impl.client.HttpClientBuilder;
+import org.apache.http.impl.conn.PoolingHttpClientConnectionManager;
+import org.apache.http.ssl.SSLContexts;
+import org.apache.http.util.EntityUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.slf4j.MDC;
+
+import javax.net.ssl.SSLContext;
+import java.io.File;
+import java.io.IOException;
+import java.net.SocketTimeoutException;
+import java.nio.charset.StandardCharsets;
+import java.security.KeyManagementException;
+import java.security.KeyStoreException;
+import java.security.NoSuchAlgorithmException;
+import java.util.List;
+import java.util.concurrent.ScheduledExecutorService;
+import java.util.concurrent.ScheduledThreadPoolExecutor;
+import java.util.concurrent.TimeUnit;
+
+/**
+ * http client
+ *
+ * @author xueyiming
+ */
+public class HttpPoolClientUtil {
+
+    private static final Logger LOGGER = LoggerFactory.getLogger(HttpPoolClientUtil.class);
+
+    private static final ScheduledExecutorService SCHEDULED_CLOSED_EXECUTOR = new ScheduledThreadPoolExecutor(1,
+            new BasicThreadFactory.Builder().namingPattern("http conn-closed-thread-%s").priority(Thread.NORM_PRIORITY).daemon(false).build(), (r, e) -> LOGGER.error(" monitor push reject task error={}", e.toString()));
+
+    private static final List<HttpClientConnectionManager> HTTP_CLIENT_CONNECTION_MANAGERS = Lists.newArrayList();
+
+    static {
+        SCHEDULED_CLOSED_EXECUTOR.schedule(() -> HTTP_CLIENT_CONNECTION_MANAGERS.forEach(HttpClientConnectionManager::closeExpiredConnections), 5, TimeUnit.SECONDS);
+    }
+
+    private CloseableHttpClient closeableHttpClient;
+
+    private HttpPoolClientUtil(CloseableHttpClient closeableHttpClient) {
+        this.closeableHttpClient = closeableHttpClient;
+    }
+
+    private static HttpRequestInterceptor getInterceptor() {
+        HttpRequestInterceptor requestInterceptor = (request, context) -> {
+            try {
+                String missSpanId = MDC.get("missSpanId");
+                String missTraceId = MDC.get("request-id");
+                if (missTraceId != null && !"".equals(missTraceId.trim())) {
+                    request.setHeader("request-id", missTraceId);
+                }
+                if (missSpanId != null && !"".equals(missSpanId.trim())) {
+                    request.setHeader("missSpanId", missSpanId);
+                }
+            } catch (Exception e) {
+                LOGGER.error(e.getMessage(), e);
+            }
+        };
+        return requestInterceptor;
+    }
+
+
+    public String get(String url) throws IOException {
+        HttpGet httpGet = new HttpGet(url);
+        return request(httpGet);
+    }
+
+    public String post(String url) throws IOException {
+        HttpPost httpPost = new HttpPost(url);
+        return request(httpPost);
+    }
+
+
+    public String post(String url, String json) throws IOException {
+        HttpPost httpPost = new HttpPost(url);
+        if (StringUtils.isBlank(json)) {
+            return request(httpPost);
+        }
+        StringEntity entity = new StringEntity(json, StandardCharsets.UTF_8);
+        entity.setContentEncoding("UTF-8");
+        entity.setContentType("application/json");
+        httpPost.setEntity(entity);
+        return request(httpPost);
+    }
+
+    public String post(String url, File file) throws IOException {
+        HttpPost uploadFile = new HttpPost(url);
+        MultipartEntityBuilder builder = MultipartEntityBuilder.create();
+        builder.addBinaryBody("media", file);
+        uploadFile.setEntity(builder.build());
+        return request(uploadFile);
+    }
+
+    public String request(HttpRequestBase request) throws IOException {
+
+        if (LOGGER.isDebugEnabled()) {
+            String path = request.getURI().toString();
+            LOGGER.debug("http request url = {} ", path);
+        }
+        HttpEntity entity = null;
+        CloseableHttpResponse response = request((HttpUriRequest) request);
+        if (response == null) {
+            throw new RuntimeException("call api exception no response");
+        }
+        entity = response.getEntity();
+        String content = null;
+        if (entity != null) {
+            content = EntityUtils.toString(entity, "UTF-8");
+        }
+        int httpStatus = response.getStatusLine().getStatusCode();
+        if (httpStatus == HttpStatus.SC_OK) {
+            return content;
+        }
+        String path = request.getURI().toString();
+        LOGGER.error("http call api {} fail response status {} content {}", path, httpStatus, content);
+//            throw new HttpServiceException(httpStatus, content);
+        return null;
+    }
+
+
+    public CloseableHttpResponse request(HttpUriRequest request) {
+        try {
+            CloseableHttpResponse execute = closeableHttpClient.execute(request);
+            return execute;
+        } catch (Exception e) {
+            String path = request.getURI().toString();
+            if (e instanceof SocketTimeoutException) {
+                LOGGER.error(String.format("http timeout request url = %s .", path));
+//                throw new TimeoutException();
+            } else {
+            }
+            throw new RuntimeException(String.format("http exception request url = %s ", path), e);
+        }
+    }
+
+    /**
+     * @param connectTimeout 连接超时时间 ms
+     * @param socketTimeout  读超时时间(等待数据超时时间)ms
+     * @param maxPerRoute    每个路由的最大连接数
+     * @param maxTotal       最大连接数
+     * @param retryCount     重试次数
+     * @return httpclient instance
+     */
+    protected static HttpPoolClientUtil create(int connectTimeout, int socketTimeout, int maxPerRoute, int maxTotal, int retryCount, int connectionWaitTimeout) {
+        try {
+            RequestConfig requestConfig = RequestConfig.custom().setConnectTimeout(connectTimeout).setSocketTimeout(socketTimeout).setConnectionRequestTimeout(connectionWaitTimeout).build();
+            CloseableHttpClient client = HttpClientBuilder.create()
+                    .setDefaultRequestConfig(requestConfig)
+                    .setConnectionManager(createConnectionManager(maxPerRoute, maxTotal))
+                    .setRetryHandler(new DefaultHttpRequestRetryHandler(retryCount, false)).addInterceptorFirst(getInterceptor()).build();
+            return new HttpPoolClientUtil(client);
+        } catch (Throwable e) {
+            LOGGER.error("create HttpPoolClient exception", e);
+            throw new RuntimeException("create HttpPoolClient exception");
+        }
+    }
+
+    private static PoolingHttpClientConnectionManager createConnectionManager(int maxPerRoute, int maxTotal) throws NoSuchAlgorithmException, KeyStoreException, KeyManagementException {
+        SSLContext sslContext = SSLContexts.custom().loadTrustMaterial((chain, authType) -> true).build();
+        Registry<ConnectionSocketFactory> registry = RegistryBuilder.<ConnectionSocketFactory>create()
+                .register("http", PlainConnectionSocketFactory.getSocketFactory())
+                .register("https", new SSLConnectionSocketFactory(sslContext, NoopHostnameVerifier.INSTANCE)).build();
+        PoolingHttpClientConnectionManager cm = new PoolingHttpClientConnectionManager(registry);
+        cm.setDefaultMaxPerRoute(maxPerRoute);
+        cm.setMaxTotal(maxTotal);
+        HTTP_CLIENT_CONNECTION_MANAGERS.add(cm);
+        return cm;
+    }
+
+}

+ 37 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/OSSUploader.java

@@ -0,0 +1,37 @@
+package com.tzld.piaoquan.longarticle.utils;
+
+import com.aliyun.oss.OSS;
+import com.aliyun.oss.OSSClientBuilder;
+import com.aliyun.oss.model.PutObjectRequest;
+
+import java.io.File;
+import java.util.UUID;
+
+public class OSSUploader {
+
+    private static final String ACCESS_KEY_ID = "LTAIP6x1l3DXfSxm"; // 填写您的 Access Key ID
+    private static final String ACCESS_KEY_SECRET = "KbTaM9ars4OX3PMS6Xm7rtxGr1FLon"; // 填写您的 Access Key Secret
+    private static final String ENDPOINT = "oss-cn-hangzhou.aliyuncs.com"; // OSS 访问域名
+    private static final String BUCKET_NAME = "art-pubbucket"; // 存储空间名称
+
+    public static String uploadToOSS(String localVideoPath, String downloadType) {
+        String ossVideoKey = String.format("long_articles/%s/%s", downloadType, UUID.randomUUID().toString());
+
+        // 创建 OSSClient 实例
+        OSS ossClient = new OSSClientBuilder().build(ENDPOINT, ACCESS_KEY_ID, ACCESS_KEY_SECRET);
+
+        try {
+            // 创建上传请求
+            PutObjectRequest putObjectRequest = new PutObjectRequest(BUCKET_NAME, ossVideoKey, new File(localVideoPath));
+            // 上传文件
+            ossClient.putObject(putObjectRequest);
+            return ossVideoKey;
+        } catch (Exception e) {
+            e.printStackTrace();
+            return null;
+        } finally {
+            // 关闭 OSSClient
+            ossClient.shutdown();
+        }
+    }
+}

+ 55 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/SortUtil.java

@@ -0,0 +1,55 @@
+package com.tzld.piaoquan.longarticle.utils;
+
+
+import cn.hutool.json.JSONObject;
+
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
+public class SortUtil {
+
+    private static double jcdTitleSimilarity(String oriTitle, String searchTitle) {
+        Set<Character> set1 = new HashSet<>();
+        for (char c : oriTitle.toCharArray()) {
+            set1.add(c);
+        }
+
+        Set<Character> set2 = new HashSet<>();
+        for (char c : searchTitle.toCharArray()) {
+            set2.add(c);
+        }
+
+        Set<Character> intersection = new HashSet<>(set1);
+        intersection.retainAll(set2);
+
+        Set<Character> union = new HashSet<>(set1);
+        union.addAll(set2);
+
+        return (double) intersection.size() / union.size();
+    }
+
+    public static List<JSONObject> titleSimilarityRank(String contentTitle, List<JSONObject> recallList) {
+        List<JSONObject> includeTitleList = new ArrayList<>();
+        for (JSONObject videoInfo : recallList) {
+            String platform = (String) videoInfo.get("platform");
+            String title = "";
+
+            if (platform.equals("dy_search") || platform.equals("baidu_search")) {
+                title = (String) videoInfo.get("title");
+            } else if (platform.equals("xg_search")) {
+                title = (String) videoInfo.get("video_title");
+            } else {
+                continue;
+            }
+
+            videoInfo.put("title", title);
+            videoInfo.put("score", jcdTitleSimilarity(contentTitle, title));
+            includeTitleList.add(videoInfo);
+        }
+
+        includeTitleList.sort((a, b) -> Double.compare((double) b.get("score"), (double) a.get("score")));
+        return includeTitleList;
+    }
+}

+ 219 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/TimeZoneUtil.java

@@ -0,0 +1,219 @@
+package com.tzld.piaoquan.longarticle.utils;
+
+import lombok.Getter;
+
+import java.time.*;
+import java.time.format.DateTimeFormatter;
+import java.time.temporal.ChronoUnit;
+import java.util.ArrayList;
+import java.util.List;
+
+public class TimeZoneUtil {
+
+    @Getter
+    public enum Timezone {
+        china("Asia/Shanghai", "中国"),
+        america("America/New_York", "美国");
+        private final String val;
+        private final String description;
+
+        Timezone(String val, String description) {
+            this.val = val;
+            this.description = description;
+        }
+    }
+
+    private TimeZoneUtil() {
+    }
+
+    public static int toExcelSerialNumber(String dateStr) {
+        // 定义日期格式
+        DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
+        // 解析输入日期
+        LocalDate date = LocalDate.parse(dateStr, formatter);
+        // Excel的基准日期
+        LocalDate baseDate = LocalDate.of(1900, 1, 1);
+        // 计算天数差
+        long daysBetween = ChronoUnit.DAYS.between(baseDate, date);
+        // Excel将1900年2月29日(不存在的日期)算作有效日期,因此需要加1
+        return (int) daysBetween + 2;
+    }
+
+    public static LocalTime currentTime(Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        return LocalTime.now(zoneId);
+    }
+
+
+    public static long todayMinTimestamp(Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate currentDate = LocalDate.now(zoneId);
+        LocalDateTime maxDateTime = LocalDateTime.of(currentDate, LocalTime.MIN);
+        return maxDateTime.atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static long dayBeforeTimestamp(Timezone timezone, int dayNum) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDateTime now = LocalDateTime.now(zoneId);
+        return now.minusDays(dayNum).atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static LocalDateTime parseDate(String dateStr, DateTimeFormatter dateTimeFormatter) {
+        return LocalDateTime.parse(dateStr, dateTimeFormatter);
+    }
+
+    public static long dateToTimestamp(Timezone timezone, LocalDateTime localDateTime) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        return localDateTime.atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static long hourBeforeTimestamp(Timezone timezone, int hourNUm) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDateTime now = LocalDateTime.now(zoneId);
+        return now.minusHours(hourNUm).atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static String todayYMD(Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate today = LocalDate.now(zoneId);
+        return today.format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
+    }
+
+    public static String getDateStr(Timezone timezone, int days) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate day = LocalDate.now(zoneId).plusDays(days);
+        return day.format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
+    }
+
+    public static String nowTime(Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalTime now = LocalTime.now(zoneId);
+        return now.format(DateTimeFormatter.ofPattern("HH:mm:ss"));
+    }
+
+    public static String yesterdayYMD(Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate yesterday = LocalDate.now(zoneId).minusDays(1);
+        return yesterday.format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
+    }
+
+    public static String beforeDayYMD(Timezone timezone, Integer dayNum) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate yesterday = LocalDate.now(zoneId).minusDays(dayNum);
+        return yesterday.format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
+    }
+
+    public static String beforeDay(Timezone timezone, Integer dayNum, DateTimeFormatter dateTimeFormatter) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate yesterday = LocalDate.now(zoneId).minusDays(dayNum);
+        return yesterday.format(dateTimeFormatter);
+    }
+
+    public static String toDay(Long epochMilli, Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        Instant instant = Instant.ofEpochMilli(epochMilli);
+        return LocalDateTime.ofInstant(instant, zoneId).format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
+    }
+
+    public static String toDayTime(Long epochMilli, Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        Instant instant = Instant.ofEpochMilli(epochMilli);
+        return LocalDateTime.ofInstant(instant, zoneId).format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"));
+    }
+
+
+    public static long todayMaxTimestamp(Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate currentDate = LocalDate.now(zoneId);
+        LocalDateTime maxDateTime = LocalDateTime.of(currentDate, LocalTime.MAX);
+        return maxDateTime.atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static long getDateMinTimestamp(String dateStr, Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate localdate = LocalDate.parse(dateStr);
+        LocalDateTime dateTime = LocalDateTime.of(localdate, LocalTime.MIN);
+        return dateTime.atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static long getDateMaxTimestamp(String dateStr, Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate localdate = LocalDate.parse(dateStr);
+        LocalDateTime dateTime = LocalDateTime.of(localdate, LocalTime.MAX);
+        return dateTime.atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static int getTodayDayOfWeek(Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        LocalDate currentDate = LocalDate.now(zoneId);
+        return currentDate.getDayOfWeek().getValue();
+    }
+
+    public static String format(Timezone timezone, Long epochMilli, DateTimeFormatter dateTimeFormatter) {
+        return Instant.ofEpochMilli(epochMilli).atZone(ZoneId.of(timezone.val)).format(dateTimeFormatter);
+    }
+
+    public static Long getNearestHalfHourTimestamp(Timezone timezone) {
+        LocalDateTime now = LocalDateTime.now(ZoneId.of(timezone.val));
+        LocalDateTime nearestHalfHour = now.withMinute(now.getMinute() > 30 ? 30 : 0).withSecond(0);
+        return nearestHalfHour.atZone(ZoneId.of(timezone.val)).toEpochSecond() * 1000;
+    }
+
+    public static Integer getDateInterval(String dateStr, Timezone timezone) {
+        Long start = getDateMinTimestamp(dateStr, timezone);
+        Long end = todayMinTimestamp(timezone);
+        return (int) Math.floor((end - start) / (24 * 3600 * 1000));
+    }
+
+    public static String toYMD(Long timestamp, Timezone timezone) {
+        return Instant.ofEpochMilli(timestamp).atZone(ZoneId.of(timezone.val)).format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
+    }
+
+    public static String toYMDT(Long timestamp) {
+
+        // 将时间戳转换为Instant对象
+        Instant instant = Instant.ofEpochMilli(timestamp);
+
+        // 将Instant对象转换为ZonedDateTime对象,指定时区为UTC
+        ZonedDateTime zdt = instant.atZone(ZoneOffset.UTC);
+
+        // 定义ISO 8601格式的DateTimeFormatter
+        DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'");
+
+        // 将ZonedDateTime对象格式化为字符串
+        return zdt.format(formatter);
+    }
+
+    public static long getDateStrTimestamp(String dateTimeString, Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        // 定义日期时间格式
+        DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm");
+
+        // 解析字符串为 LocalDateTime 对象
+        LocalDateTime localDateTime = LocalDateTime.parse(dateTimeString, formatter);
+
+        // 将 LocalDateTime 转换为时间戳
+        return localDateTime.atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static long getDateStrTimestamp(String dateTimeString, String pattern, Timezone timezone) {
+        ZoneId zoneId = ZoneId.of(timezone.val);
+        // 定义日期时间格式
+        DateTimeFormatter formatter = DateTimeFormatter.ofPattern(pattern);
+
+        // 解析字符串为 LocalDateTime 对象
+        LocalDateTime localDateTime = LocalDateTime.parse(dateTimeString, formatter);
+
+        // 将 LocalDateTime 转换为时间戳
+        return localDateTime.atZone(zoneId).toInstant().toEpochMilli();
+    }
+
+    public static List<String> getBeforeDaysStr(String dateStr, int beforeDayNum) {
+        List<String> result = new ArrayList<>();
+        LocalDate localDate = LocalDate.parse(dateStr, DateTimeFormatter.ofPattern("yyyy-MM-dd"));
+        for (int i = 0; i < beforeDayNum; i++) {
+            result.add(localDate.minusDays(i + 1).format(DateTimeFormatter.ofPattern("yyyy-MM-dd")));
+        }
+        return result;
+    }
+}

+ 161 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/VideoDownloader.java

@@ -0,0 +1,161 @@
+package com.tzld.piaoquan.longarticle.utils;
+
+import org.apache.commons.codec.digest.DigestUtils;
+import org.apache.http.HttpResponse;
+import org.apache.http.client.methods.HttpGet;
+import org.apache.http.impl.client.CloseableHttpClient;
+import org.apache.http.impl.client.HttpClients;
+import org.apache.http.message.BasicHeader;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.Objects;
+import java.util.UUID;
+
+public class VideoDownloader {
+
+    public static String downloadCover(String filePath, String platform, String coverUrl) {
+        try {
+            HttpResponse response = sendRequest(platform, coverUrl, "cover");
+            if (response.getStatusLine().getStatusCode() != 200) {
+                return null;
+            }
+
+            try (InputStream inputStream = response.getEntity().getContent();
+                 FileOutputStream outputStream = new FileOutputStream(new File(filePath))) {
+                byte[] buffer = new byte[1024];
+                int bytesRead;
+                while ((bytesRead = inputStream.read(buffer)) != -1) {
+                    outputStream.write(buffer, 0, bytesRead);
+                }
+            }
+            return filePath;
+        } catch (Exception e) {
+
+        }
+        return "";
+    }
+
+    public static HttpResponse sendRequest(String platform, String url, String downloadType) throws IOException {
+        CloseableHttpClient httpClient = HttpClients.createDefault();
+        HttpGet request = new HttpGet(url);
+        request.setHeaders(requestHeader(platform, url, downloadType));
+        return httpClient.execute(request);
+    }
+
+    public static org.apache.http.Header[] requestHeader(String platform, String url, String downloadType) {
+        switch (platform) {
+            case "xg_search":
+                // 根据 URL 设置不同的请求头
+                if (url.contains("v9-xg-web-pc.ixigua.com")) {
+                    return new org.apache.http.Header[]{
+                            new BasicHeader("Accept", "*/*"),
+                            new BasicHeader("Accept-Language", "zh-CN,zh;q=0.9"),
+                            new BasicHeader("Host", "v9-xg-web-pc.ixigua.com"),
+                            new BasicHeader("User-Agent", "Mozilla/5.0"),
+                            new BasicHeader("Origin", "https://www.ixigua.com/"),
+                            new BasicHeader("Referer", "https://www.ixigua.com/")
+                    };
+                } else if (url.contains("v3-xg-web-pc.ixigua.com")) {
+                    return new org.apache.http.Header[]{
+                            new BasicHeader("Accept", "*/*"),
+                            new BasicHeader("Accept-Language", "zh-CN,zh;q=0.9"),
+                            new BasicHeader("Host", "v3-xg-web-pc.ixigua.com"),
+                            new BasicHeader("User-Agent", "Mozilla/5.0"),
+                            new BasicHeader("Origin", "https://www.ixigua.com/"),
+                            new BasicHeader("Referer", "https://www.ixigua.com/")
+                    };
+                } else if (Objects.equals(downloadType, "cover")) {
+                    return new org.apache.http.Header[]{
+                            new BasicHeader("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7"),
+                            new BasicHeader("Accept-Language", "en,zh;q=0.9,zh-CN;q=0.8"),
+                            new BasicHeader("Cache-Control", "max-age=0"),
+                            new BasicHeader("Proxy-Connection", "keep-alive"),
+                            new BasicHeader("Upgrade-Insecure-Requests", "1"),
+                            new BasicHeader("User-Agent", "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36")
+                    };
+                }
+                // 其他 headers 根据 downloadType 处理
+                break;
+            case "baidu_search":
+                return new org.apache.http.Header[]{
+                        new BasicHeader("Accept", "*/*"),
+                        new BasicHeader("Accept-Language", "zh-CN,zh;q=0.9"),
+                        new BasicHeader("User-Agent", "Mozilla/5.0")
+                };
+            case "wx_search":
+                return new org.apache.http.Header[]{
+                        new BasicHeader("Accept", "*/*"),
+                        new BasicHeader("Accept-Language", "zh-CN,zh;q=0.9"),
+                        new BasicHeader("User-Agent", "Mozilla/5.0"),
+                        new BasicHeader("Origin", "https://mp.weixin.qq.com"),
+                        new BasicHeader("Referer", "https://mp.weixin.qq.com")
+                };
+            case "dy_search":
+                return new org.apache.http.Header[]{
+                        new BasicHeader("accept", "*/*"),
+                        new BasicHeader("accept-language", "en,zh;q=0.9,zh-CN;q=0.8"),
+                        new BasicHeader("priority", "i"),
+                        new BasicHeader("referer", "https://v11-coldf.douyinvod.com/"),
+                        new BasicHeader("user-agent", "Mozilla/5.0")
+                };
+            default:
+                return new org.apache.http.Header[]{};
+        }
+        return new org.apache.http.Header[]{};
+    }
+
+    public static String downloadVideo(String filePath, String platform, String videoUrl, String downloadType) {
+        try {
+            HttpResponse response = sendRequest(platform, videoUrl, downloadType);
+            if (response.getStatusLine().getStatusCode() != 200 && response.getStatusLine().getStatusCode() != 206) {
+                System.out.println("Error: " + response.getStatusLine().getStatusCode());
+                return null;
+            }
+
+            try (InputStream inputStream = response.getEntity().getContent();
+                 FileOutputStream outputStream = new FileOutputStream(new File(filePath))) {
+                byte[] buffer = new byte[1024 * 1024];
+                int bytesRead;
+                while ((bytesRead = inputStream.read(buffer)) != -1) {
+                    outputStream.write(buffer, 0, bytesRead);
+                }
+            }
+            return filePath;
+        } catch (Exception e) {
+            System.out.println(e.getMessage());
+        }
+        return "";
+    }
+
+    public static String generateVideoPath(String platform, String videoId) {
+        String index = String.format("%s-%s-%s", platform, videoId, UUID.randomUUID());
+        String md5Hash = DigestUtils.md5Hex(index);
+        String fileName = String.format("%s.mp4", md5Hash);
+        String filePath = String.join(File.separator, System.getProperty("user.dir"), fileName);
+        return filePath; // 返回文件路径和封面路径
+    }
+
+    public static String generateCoverPath(String platform, String videoId) {
+        String index = String.format("%s-%s-%s", platform, videoId, UUID.randomUUID());
+        String md5Hash = DigestUtils.md5Hex(index);
+        String coverName = String.format("%s.png", md5Hash);
+        String coverPath = String.join(File.separator, System.getProperty("user.dir"), coverName);
+        return coverPath; // 返回文件路径和封面路径
+    }
+
+    public static void main(String[] args) {
+        // 示例用法
+        String coverUrl = "https://example.com/cover.jpg";
+        String filePath = "path/to/cover.png";
+        downloadCover(filePath, "xg_search", coverUrl);
+        String videoUrl = "https://example.com/video.mp4";
+        String videoFilePath = "path/to/video.mp4";
+        downloadVideo(videoFilePath, "xg_search", videoUrl, "video");
+        String paths = generateVideoPath("xg_search", "videoId");
+        System.out.println("Generated paths: " + paths);
+
+    }
+}

+ 207 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/XiGuaUtils.java

@@ -0,0 +1,207 @@
+package com.tzld.piaoquan.longarticle.utils;
+
+import cn.hutool.http.HttpRequest;
+import cn.hutool.http.HttpResponse;
+import com.alibaba.fastjson.JSONArray;
+import com.alibaba.fastjson.JSONObject;
+import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import org.jsoup.Jsoup;
+import org.jsoup.nodes.Document;
+import org.jsoup.select.Elements;
+
+import javax.crypto.Cipher;
+import javax.crypto.spec.IvParameterSpec;
+import javax.crypto.spec.SecretKeySpec;
+import java.net.URLEncoder;
+import java.nio.charset.StandardCharsets;
+import java.util.*;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+public class XiGuaUtils {
+
+    public static List<JSONObject> xiguaSearchV2(String keyword, List<String> sensitiveWords) {
+        String url = "https://www.ixigua.com/api/searchv2/complex/" + URLEncoder.encode(keyword, StandardCharsets.UTF_8) + "/10";
+        Map<String, String> headers = new HashMap<>();
+        headers.put("accept", "application/json, text/plain, */*");
+        headers.put("accept-language", "en,zh;q=0.9,zh-CN;q=0.8");
+        headers.put("cookie", "_tea_utm_cache_2285=undefined;");
+        headers.put("priority", "u=1, i");
+        headers.put("referer", "https://www.ixigua.com/search/" + URLEncoder.encode(keyword, StandardCharsets.UTF_8));
+        headers.put("user-agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3");
+
+        HttpResponse response = HttpRequest.get(url)
+                .addHeaders(headers)
+                .execute();
+
+        try {
+            JSONObject jsonResponse = JSONObject.parseObject(response.body());
+            JSONArray recallList = jsonResponse.getJSONObject("data").getJSONArray("data");
+
+            if (recallList != null) {
+                for (int i = 0; i < recallList.size(); i++) {
+                    JSONObject videoObj = recallList.getJSONObject(i);
+                    if ("video".equals(videoObj.getString("type"))) {
+                        String title = videoObj.getJSONObject("data").getString("title");
+                        String groupId = videoObj.getJSONObject("data").getString("group_id");
+                        int duration = videoObj.getJSONObject("data").getInteger("video_time");
+
+                        // 假设 sensitiveFlag 是一个方法用于检查敏感词
+                        if (sensitiveFlag(sensitiveWords, title) && duration <= 300) {
+                            System.out.println(groupId);
+                            JSONObject videoInfo = getVideoInfo(groupId);
+                            if (videoInfo != null) {
+                                return List.of(videoInfo);
+                            }
+                        }
+                    }
+                }
+            }
+            return List.of();
+        } catch (Exception e) {
+            e.printStackTrace();
+            return List.of();
+        }
+    }
+
+    public static JSONObject getVideoInfo(String itemId) {
+        String url = "https://www.ixigua.com/" + itemId;
+
+        // 设置请求头
+        HttpRequest request = HttpRequest.get(url)
+                .header("accept-language", "zh-CN,zh-Hans;q=0.9")
+                .header("cookie", "UIFID=73355a799e41c2edb6d004baa6cda0116425031dff9117e11075ec8bf266082874fe897f43e66be83a0501afe4a08cfc7e1066ab88423af122641493c7af9f0a745eb85c50fddb096de5cc77cd5ff05503312d84d36ab2681c6e6d930bbe68edaebf8fae03b04eb669359965e01c266b;"
+                        + "__ac_nonce=0666fd1a00053bf535b9f;"
+                        + "__ac_signature=_02B4Z6wo00f01u8PTiQAAIDBvfBuP-YjUQbvL0qAAN25bWfWXQrzRNCBKvFYKS5wAOYPXg5XV1Ck9JEroeWeWKijH2v3i4lxXM37JogiJJfEtYD.8sbXul2-4v.VRRta4xa07ignRnGj5Voh83;"
+                        + "ttwid=1%7C9b5sTIuwZxZKt0wFsvE-2t5OoFxH_Q5VIpVNWEREbAo%7C1718605316%7C9dfc9322350e713e6109ed46a7047ed31c0ab5a724e84de0bb766c195043207c")
+                .header("user-agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3")
+                .header("referer", "https://www.ixigua.com/" + itemId);
+
+        // 发送请求
+        HttpResponse response = request.execute();
+
+        // 解析响应
+        String responseBody = response.body();
+        System.out.println(responseBody);
+        return extractInfoByRegex(responseBody);
+    }
+
+    public static JSONObject extractInfoByRegex(String text) {
+        JSONObject result = extractVideoUrl(text);
+
+        // 标题
+        String titleContent = extractTitle(text);
+        result.put("video_title", titleContent);
+
+        return result;
+    }
+
+    private static String extractTitle(String text) {
+        Pattern pattern = Pattern.compile("<title[^>]*>(.*?)</title>");
+        Matcher matcher = pattern.matcher(text);
+        if (matcher.find()) {
+            String title = matcher.group(1);
+            // 处理标题内容
+            String[] parts = title.split(" - ");
+            String titleContent = parts[0];
+
+            // 尝试将标题内容转换为 UTF-8
+            try {
+                return new String(titleContent.getBytes(StandardCharsets.ISO_8859_1), StandardCharsets.UTF_8);
+            } catch (Exception e) {
+                e.printStackTrace();
+            }
+            return titleContent;
+        }
+        return "";
+    }
+
+    public static JSONObject extractVideoUrl(String text) {
+        Document document = Jsoup.parse(text);
+        Elements scriptElements = document.select("script#SSR_HYDRATED_DATA");
+        String str2 = Objects.requireNonNull(scriptElements.first()).html();
+        String json2 = str2.substring(str2.indexOf('{'), str2.lastIndexOf('}') + 1);
+        String[] irregulars = {"null", "undefined", "=false", "=true", "false", "true"};
+
+        // 处理不规则定义
+        for (String i : irregulars) {
+            if ("=false".equals(i) || "=true".equals(i)) {
+                json2 = json2.replace(i, "=" + Character.toUpperCase(i.charAt(1)) + i.substring(2));
+            } else {
+                json2 = json2.replace(i, "12");
+            }
+        }
+
+        try {
+            ObjectMapper objectMapper = new ObjectMapper();
+            JsonNode dict2 = objectMapper.readTree(json2).path("anyVideo").path("gidInformation").path("packerData").path("video");
+
+            long duration = dict2.path("video_duration").asLong();
+            long playCnt = dict2.path("video_watch_count").asLong();
+            long publishTime = dict2.path("video_publish_time").asLong();
+            long likeCnt = dict2.path("video_like_count").asLong();
+            String videoTitle = dict2.path("title").asText();
+            String videoId = dict2.path("vid").asText();
+            JsonNode videoRes = dict2.path("videoResource");
+            String coverUrl = dict2.path("poster_url").asText().replace("\\u002F", "/");
+
+            String realVideoUrl;
+            if (videoRes.path("dash").asInt() == 12) {
+                JsonNode obj = videoRes.path("normal");
+                String ptk = obj.path("ptk").asText();
+                JsonNode videoList = obj.path("video_list");
+                String mainUrl = videoList.fields().next().getValue().path("main_url").asText();
+                realVideoUrl = aesDecrypt(mainUrl, ptk);
+            } else {
+                JsonNode obj = videoRes.path("dash");
+                String ptk = obj.path("ptk").asText();
+                String videoUrl = obj.path("dynamic_video").path("main_url").asText();
+                realVideoUrl = aesDecrypt(videoUrl, ptk);
+            }
+
+            JSONObject result = new JSONObject();
+            result.put("video_url", realVideoUrl);
+            result.put("cover_url", coverUrl);
+            result.put("video_id", videoId);
+            result.put("video_title", videoTitle);
+            result.put("like_cnt", likeCnt);
+            result.put("play_cnt", playCnt);
+            result.put("publish_time", publishTime);
+            result.put("duration", duration);
+            return result;
+
+        } catch (Exception e) {
+            e.printStackTrace();
+            return new JSONObject();
+        }
+    }
+
+    private static String aesDecrypt(String data, String key) {
+        try {
+            byte[] keyBytes = key.getBytes(StandardCharsets.UTF_8);
+            SecretKeySpec secretKey = new SecretKeySpec(keyBytes, "AES");
+            Cipher cipher = Cipher.getInstance("AES/CBC/PKCS5Padding");
+            IvParameterSpec ivParams = new IvParameterSpec(keyBytes, 0, 16);
+            cipher.init(Cipher.DECRYPT_MODE, secretKey, ivParams);
+            byte[] decryptedBytes = cipher.doFinal(Base64.getDecoder().decode(data));
+            return new String(decryptedBytes, StandardCharsets.UTF_8);
+        } catch (Exception e) {
+            e.printStackTrace();
+            return null;
+        }
+    }
+
+
+    // 假设 sensitiveFlag 方法的实现
+    private static boolean sensitiveFlag(List<String> sensitiveWords, String title) {
+        return true;
+    }
+
+    public static void main(String[] args) {
+        String keyword = "测试";  // 替换为实际关键词
+        List<String> sensitiveWords = List.of("敏感词1", "敏感词2");  // 替换为实际敏感词
+        List<JSONObject> results = xiguaSearchV2(keyword, sensitiveWords);
+        results.forEach(System.out::println);
+    }
+}

+ 108 - 0
long-article-server/src/main/java/com/tzld/piaoquan/longarticle/utils/page/Page.java

@@ -0,0 +1,108 @@
+package com.tzld.piaoquan.longarticle.utils.page;
+
+import java.util.List;
+
+public class Page<T> {
+
+    public static final String DEFAULT_PAGE_SIZE = "20";
+    public static final String DEFAULT_CURRENT_PAGE = "1";
+
+    private int currentPage = Integer.valueOf(DEFAULT_CURRENT_PAGE);
+    private int totalSize;
+    private int pageSize = Integer.valueOf(DEFAULT_PAGE_SIZE);
+
+    private List<T> objs;
+
+    private T obj;
+
+    public Page() {
+    }
+
+    public Page(int currentPage) {
+        this.currentPage = currentPage;
+    }
+
+    public Page(int currentPage, int pageSize) {
+        setCurrentPage(currentPage);
+        setPageSize(pageSize);
+    }
+
+    public int getNextPage() {
+        return currentPage == getTotalPage() ? currentPage : currentPage + 1;
+    }
+
+    public int getPrePage() {
+        return currentPage > 1 ? currentPage - 1 : 1;
+    }
+
+    public int getOffset() {
+        return getCurPageFirstRecNum() - 1;
+    }
+
+    public int getCurPageFirstRecNum() {
+        return (getCurrentPage() - 1) * pageSize + 1;
+    }
+
+    public int getCurPageLastRecNum() {
+        return getCurrentPage() * pageSize;
+    }
+
+    public int getTotalPage() {
+        int t = totalSize % pageSize > 0 ? totalSize / pageSize + 1 : totalSize / pageSize;
+        if (t <= 0) {
+            t = 1;
+        }
+        return t;
+    }
+
+    public void setObjs(List<T> objs) {
+        this.objs = objs;
+    }
+
+    public List<T> getObjs() {
+        return objs;
+    }
+
+    public int getCurrentPage() {
+        return currentPage;
+    }
+
+    public void setCurrentPage(int currentPage) {
+        this.currentPage = currentPage;
+    }
+
+    public int getTotalSize() {
+        return totalSize;
+    }
+
+    public void setTotalSize(int totalSize) {
+        this.totalSize = totalSize;
+    }
+
+    public int getPageSize() {
+        return pageSize;
+    }
+
+    public void setPageSize(int pageSize) {
+        if (pageSize > 0) {
+            this.pageSize = pageSize;
+        }
+    }
+
+    public boolean containData() {
+        return getTotalSize() > 0;
+    }
+    @Override
+    public String toString() {
+        return "Page [currentPage=" + getCurrentPage() + ", totalSize=" + getTotalSize() + ", pageSize=" + getPageSize()
+                + "]";
+    }
+
+    public T getObj() {
+        return obj;
+    }
+
+    public void setObj(T obj) {
+        this.obj = obj;
+    }
+}

+ 8 - 0
long-article-server/src/main/resources/application-test.properties

@@ -0,0 +1,8 @@
+server.port=8080
+
+spring.datasource.username=changwen_admin
+spring.datasource.password=changwen@123456
+spring.datasource.url=jdbc:mysql://rm-bp14529nwwcw75yr1ko.mysql.rds.aliyuncs.com:3306/long_articles?useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowMultiQueries=true
+
+
+apollo.meta: https://apolloconfig-internal.piaoquantv.com

+ 27 - 0
long-article-server/src/main/resources/application.properties

@@ -0,0 +1,27 @@
+spring.profiles.active=test
+spring.application.name=long-article-server
+
+spring.datasource.driver-class-name=com.mysql.jdbc.Driver
+spring.datasource.type=com.alibaba.druid.pool.DruidDataSource
+spring.datasource.initialSize=5
+spring.datasource.maxActive=20
+spring.datasource.maxWait=60000
+spring.datasource.timeBetweenEvictionRunsMillis=60000
+spring.datasource.minEvictableIdleTimeMillis=300000
+spring.datasource.validationQuery=SELECT 1 FROM DUAL
+spring.datasource.testWhileIdle=true
+spring.datasource.testOnBorrow=false
+spring.datasource.testOnReturn=false
+spring.datasource.poolPreparedStatements=true
+
+
+app.id=LongArticlesMatchServer
+apollo.bootstrap.enabled=true
+apollo.bootstrap.namespaces=application
+apollo.cacheDir=/datalog/apollo-cache-dir
+
+
+
+
+
+

+ 505 - 0
long-article-server/src/main/resources/mapper/CrawlerVideoMapper.xml

@@ -0,0 +1,505 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.tzld.piaoquan.longarticle.dao.mapper.CrawlerVideoMapper">
+  <resultMap id="BaseResultMap" type="com.tzld.piaoquan.longarticle.model.po.CrawlerVideo">
+    <id column="id" jdbcType="INTEGER" property="id" />
+    <result column="content_id" jdbcType="VARCHAR" property="contentId" />
+    <result column="out_video_id" jdbcType="VARCHAR" property="outVideoId" />
+    <result column="platform" jdbcType="VARCHAR" property="platform" />
+    <result column="video_title" jdbcType="VARCHAR" property="videoTitle" />
+    <result column="play_count" jdbcType="INTEGER" property="playCount" />
+    <result column="like_count" jdbcType="INTEGER" property="likeCount" />
+    <result column="share_count" jdbcType="INTEGER" property="shareCount" />
+    <result column="publish_time" jdbcType="TIMESTAMP" property="publishTime" />
+    <result column="crawler_time" jdbcType="TIMESTAMP" property="crawlerTime" />
+    <result column="duration" jdbcType="INTEGER" property="duration" />
+    <result column="download_status" jdbcType="INTEGER" property="downloadStatus" />
+    <result column="video_oss_path" jdbcType="VARCHAR" property="videoOssPath" />
+    <result column="cover_oss_path" jdbcType="VARCHAR" property="coverOssPath" />
+    <result column="user_id" jdbcType="VARCHAR" property="userId" />
+    <result column="trace_id" jdbcType="VARCHAR" property="traceId" />
+    <result column="score" jdbcType="REAL" property="score" />
+  </resultMap>
+  <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.tzld.piaoquan.longarticle.model.po.CrawlerVideo">
+    <result column="video_url" jdbcType="LONGVARCHAR" property="videoUrl" />
+    <result column="cover_url" jdbcType="LONGVARCHAR" property="coverUrl" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    id, content_id, out_video_id, platform, video_title, play_count, like_count, share_count, 
+    publish_time, crawler_time, duration, download_status, video_oss_path, cover_oss_path, 
+    user_id, trace_id, score
+  </sql>
+  <sql id="Blob_Column_List">
+    video_url, cover_url
+  </sql>
+  <select id="selectByExampleWithBLOBs" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideoExample" resultMap="ResultMapWithBLOBs">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from long_articles_crawler_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideoExample" resultMap="BaseResultMap">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from long_articles_crawler_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="ResultMapWithBLOBs">
+    select 
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from long_articles_crawler_videos
+    where id = #{id,jdbcType=INTEGER}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
+    delete from long_articles_crawler_videos
+    where id = #{id,jdbcType=INTEGER}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideoExample">
+    delete from long_articles_crawler_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideo">
+    insert into long_articles_crawler_videos (id, content_id, out_video_id, 
+      platform, video_title, play_count, 
+      like_count, share_count, publish_time, 
+      crawler_time, duration, download_status, 
+      video_oss_path, cover_oss_path, user_id, 
+      trace_id, score, video_url, 
+      cover_url)
+    values (#{id,jdbcType=INTEGER}, #{contentId,jdbcType=VARCHAR}, #{outVideoId,jdbcType=VARCHAR}, 
+      #{platform,jdbcType=VARCHAR}, #{videoTitle,jdbcType=VARCHAR}, #{playCount,jdbcType=INTEGER}, 
+      #{likeCount,jdbcType=INTEGER}, #{shareCount,jdbcType=INTEGER}, #{publishTime,jdbcType=TIMESTAMP}, 
+      #{crawlerTime,jdbcType=TIMESTAMP}, #{duration,jdbcType=INTEGER}, #{downloadStatus,jdbcType=INTEGER}, 
+      #{videoOssPath,jdbcType=VARCHAR}, #{coverOssPath,jdbcType=VARCHAR}, #{userId,jdbcType=VARCHAR}, 
+      #{traceId,jdbcType=VARCHAR}, #{score,jdbcType=REAL}, #{videoUrl,jdbcType=LONGVARCHAR}, 
+      #{coverUrl,jdbcType=LONGVARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideo">
+    insert into long_articles_crawler_videos
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        id,
+      </if>
+      <if test="contentId != null">
+        content_id,
+      </if>
+      <if test="outVideoId != null">
+        out_video_id,
+      </if>
+      <if test="platform != null">
+        platform,
+      </if>
+      <if test="videoTitle != null">
+        video_title,
+      </if>
+      <if test="playCount != null">
+        play_count,
+      </if>
+      <if test="likeCount != null">
+        like_count,
+      </if>
+      <if test="shareCount != null">
+        share_count,
+      </if>
+      <if test="publishTime != null">
+        publish_time,
+      </if>
+      <if test="crawlerTime != null">
+        crawler_time,
+      </if>
+      <if test="duration != null">
+        duration,
+      </if>
+      <if test="downloadStatus != null">
+        download_status,
+      </if>
+      <if test="videoOssPath != null">
+        video_oss_path,
+      </if>
+      <if test="coverOssPath != null">
+        cover_oss_path,
+      </if>
+      <if test="userId != null">
+        user_id,
+      </if>
+      <if test="traceId != null">
+        trace_id,
+      </if>
+      <if test="score != null">
+        score,
+      </if>
+      <if test="videoUrl != null">
+        video_url,
+      </if>
+      <if test="coverUrl != null">
+        cover_url,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=INTEGER},
+      </if>
+      <if test="contentId != null">
+        #{contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="outVideoId != null">
+        #{outVideoId,jdbcType=VARCHAR},
+      </if>
+      <if test="platform != null">
+        #{platform,jdbcType=VARCHAR},
+      </if>
+      <if test="videoTitle != null">
+        #{videoTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="playCount != null">
+        #{playCount,jdbcType=INTEGER},
+      </if>
+      <if test="likeCount != null">
+        #{likeCount,jdbcType=INTEGER},
+      </if>
+      <if test="shareCount != null">
+        #{shareCount,jdbcType=INTEGER},
+      </if>
+      <if test="publishTime != null">
+        #{publishTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="crawlerTime != null">
+        #{crawlerTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="duration != null">
+        #{duration,jdbcType=INTEGER},
+      </if>
+      <if test="downloadStatus != null">
+        #{downloadStatus,jdbcType=INTEGER},
+      </if>
+      <if test="videoOssPath != null">
+        #{videoOssPath,jdbcType=VARCHAR},
+      </if>
+      <if test="coverOssPath != null">
+        #{coverOssPath,jdbcType=VARCHAR},
+      </if>
+      <if test="userId != null">
+        #{userId,jdbcType=VARCHAR},
+      </if>
+      <if test="traceId != null">
+        #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="score != null">
+        #{score,jdbcType=REAL},
+      </if>
+      <if test="videoUrl != null">
+        #{videoUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="coverUrl != null">
+        #{coverUrl,jdbcType=LONGVARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideoExample" resultType="java.lang.Long">
+    select count(*) from long_articles_crawler_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    update long_articles_crawler_videos
+    <set>
+      <if test="record.id != null">
+        id = #{record.id,jdbcType=INTEGER},
+      </if>
+      <if test="record.contentId != null">
+        content_id = #{record.contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.outVideoId != null">
+        out_video_id = #{record.outVideoId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.platform != null">
+        platform = #{record.platform,jdbcType=VARCHAR},
+      </if>
+      <if test="record.videoTitle != null">
+        video_title = #{record.videoTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="record.playCount != null">
+        play_count = #{record.playCount,jdbcType=INTEGER},
+      </if>
+      <if test="record.likeCount != null">
+        like_count = #{record.likeCount,jdbcType=INTEGER},
+      </if>
+      <if test="record.shareCount != null">
+        share_count = #{record.shareCount,jdbcType=INTEGER},
+      </if>
+      <if test="record.publishTime != null">
+        publish_time = #{record.publishTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.crawlerTime != null">
+        crawler_time = #{record.crawlerTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.duration != null">
+        duration = #{record.duration,jdbcType=INTEGER},
+      </if>
+      <if test="record.downloadStatus != null">
+        download_status = #{record.downloadStatus,jdbcType=INTEGER},
+      </if>
+      <if test="record.videoOssPath != null">
+        video_oss_path = #{record.videoOssPath,jdbcType=VARCHAR},
+      </if>
+      <if test="record.coverOssPath != null">
+        cover_oss_path = #{record.coverOssPath,jdbcType=VARCHAR},
+      </if>
+      <if test="record.userId != null">
+        user_id = #{record.userId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.traceId != null">
+        trace_id = #{record.traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.score != null">
+        score = #{record.score,jdbcType=REAL},
+      </if>
+      <if test="record.videoUrl != null">
+        video_url = #{record.videoUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="record.coverUrl != null">
+        cover_url = #{record.coverUrl,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExampleWithBLOBs" parameterType="map">
+    update long_articles_crawler_videos
+    set id = #{record.id,jdbcType=INTEGER},
+      content_id = #{record.contentId,jdbcType=VARCHAR},
+      out_video_id = #{record.outVideoId,jdbcType=VARCHAR},
+      platform = #{record.platform,jdbcType=VARCHAR},
+      video_title = #{record.videoTitle,jdbcType=VARCHAR},
+      play_count = #{record.playCount,jdbcType=INTEGER},
+      like_count = #{record.likeCount,jdbcType=INTEGER},
+      share_count = #{record.shareCount,jdbcType=INTEGER},
+      publish_time = #{record.publishTime,jdbcType=TIMESTAMP},
+      crawler_time = #{record.crawlerTime,jdbcType=TIMESTAMP},
+      duration = #{record.duration,jdbcType=INTEGER},
+      download_status = #{record.downloadStatus,jdbcType=INTEGER},
+      video_oss_path = #{record.videoOssPath,jdbcType=VARCHAR},
+      cover_oss_path = #{record.coverOssPath,jdbcType=VARCHAR},
+      user_id = #{record.userId,jdbcType=VARCHAR},
+      trace_id = #{record.traceId,jdbcType=VARCHAR},
+      score = #{record.score,jdbcType=REAL},
+      video_url = #{record.videoUrl,jdbcType=LONGVARCHAR},
+      cover_url = #{record.coverUrl,jdbcType=LONGVARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    update long_articles_crawler_videos
+    set id = #{record.id,jdbcType=INTEGER},
+      content_id = #{record.contentId,jdbcType=VARCHAR},
+      out_video_id = #{record.outVideoId,jdbcType=VARCHAR},
+      platform = #{record.platform,jdbcType=VARCHAR},
+      video_title = #{record.videoTitle,jdbcType=VARCHAR},
+      play_count = #{record.playCount,jdbcType=INTEGER},
+      like_count = #{record.likeCount,jdbcType=INTEGER},
+      share_count = #{record.shareCount,jdbcType=INTEGER},
+      publish_time = #{record.publishTime,jdbcType=TIMESTAMP},
+      crawler_time = #{record.crawlerTime,jdbcType=TIMESTAMP},
+      duration = #{record.duration,jdbcType=INTEGER},
+      download_status = #{record.downloadStatus,jdbcType=INTEGER},
+      video_oss_path = #{record.videoOssPath,jdbcType=VARCHAR},
+      cover_oss_path = #{record.coverOssPath,jdbcType=VARCHAR},
+      user_id = #{record.userId,jdbcType=VARCHAR},
+      trace_id = #{record.traceId,jdbcType=VARCHAR},
+      score = #{record.score,jdbcType=REAL}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideo">
+    update long_articles_crawler_videos
+    <set>
+      <if test="contentId != null">
+        content_id = #{contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="outVideoId != null">
+        out_video_id = #{outVideoId,jdbcType=VARCHAR},
+      </if>
+      <if test="platform != null">
+        platform = #{platform,jdbcType=VARCHAR},
+      </if>
+      <if test="videoTitle != null">
+        video_title = #{videoTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="playCount != null">
+        play_count = #{playCount,jdbcType=INTEGER},
+      </if>
+      <if test="likeCount != null">
+        like_count = #{likeCount,jdbcType=INTEGER},
+      </if>
+      <if test="shareCount != null">
+        share_count = #{shareCount,jdbcType=INTEGER},
+      </if>
+      <if test="publishTime != null">
+        publish_time = #{publishTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="crawlerTime != null">
+        crawler_time = #{crawlerTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="duration != null">
+        duration = #{duration,jdbcType=INTEGER},
+      </if>
+      <if test="downloadStatus != null">
+        download_status = #{downloadStatus,jdbcType=INTEGER},
+      </if>
+      <if test="videoOssPath != null">
+        video_oss_path = #{videoOssPath,jdbcType=VARCHAR},
+      </if>
+      <if test="coverOssPath != null">
+        cover_oss_path = #{coverOssPath,jdbcType=VARCHAR},
+      </if>
+      <if test="userId != null">
+        user_id = #{userId,jdbcType=VARCHAR},
+      </if>
+      <if test="traceId != null">
+        trace_id = #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="score != null">
+        score = #{score,jdbcType=REAL},
+      </if>
+      <if test="videoUrl != null">
+        video_url = #{videoUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="coverUrl != null">
+        cover_url = #{coverUrl,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKeyWithBLOBs" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideo">
+    update long_articles_crawler_videos
+    set content_id = #{contentId,jdbcType=VARCHAR},
+      out_video_id = #{outVideoId,jdbcType=VARCHAR},
+      platform = #{platform,jdbcType=VARCHAR},
+      video_title = #{videoTitle,jdbcType=VARCHAR},
+      play_count = #{playCount,jdbcType=INTEGER},
+      like_count = #{likeCount,jdbcType=INTEGER},
+      share_count = #{shareCount,jdbcType=INTEGER},
+      publish_time = #{publishTime,jdbcType=TIMESTAMP},
+      crawler_time = #{crawlerTime,jdbcType=TIMESTAMP},
+      duration = #{duration,jdbcType=INTEGER},
+      download_status = #{downloadStatus,jdbcType=INTEGER},
+      video_oss_path = #{videoOssPath,jdbcType=VARCHAR},
+      cover_oss_path = #{coverOssPath,jdbcType=VARCHAR},
+      user_id = #{userId,jdbcType=VARCHAR},
+      trace_id = #{traceId,jdbcType=VARCHAR},
+      score = #{score,jdbcType=REAL},
+      video_url = #{videoUrl,jdbcType=LONGVARCHAR},
+      cover_url = #{coverUrl,jdbcType=LONGVARCHAR}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.tzld.piaoquan.longarticle.model.po.CrawlerVideo">
+    update long_articles_crawler_videos
+    set content_id = #{contentId,jdbcType=VARCHAR},
+      out_video_id = #{outVideoId,jdbcType=VARCHAR},
+      platform = #{platform,jdbcType=VARCHAR},
+      video_title = #{videoTitle,jdbcType=VARCHAR},
+      play_count = #{playCount,jdbcType=INTEGER},
+      like_count = #{likeCount,jdbcType=INTEGER},
+      share_count = #{shareCount,jdbcType=INTEGER},
+      publish_time = #{publishTime,jdbcType=TIMESTAMP},
+      crawler_time = #{crawlerTime,jdbcType=TIMESTAMP},
+      duration = #{duration,jdbcType=INTEGER},
+      download_status = #{downloadStatus,jdbcType=INTEGER},
+      video_oss_path = #{videoOssPath,jdbcType=VARCHAR},
+      cover_oss_path = #{coverOssPath,jdbcType=VARCHAR},
+      user_id = #{userId,jdbcType=VARCHAR},
+      trace_id = #{traceId,jdbcType=VARCHAR},
+      score = #{score,jdbcType=REAL}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+</mapper>

+ 293 - 0
long-article-server/src/main/resources/mapper/LongArticlesTextMapper.xml

@@ -0,0 +1,293 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.tzld.piaoquan.longarticle.dao.mapper.LongArticlesTextMapper">
+  <resultMap id="BaseResultMap" type="com.tzld.piaoquan.longarticle.model.po.LongArticlesText">
+    <id column="content_id" jdbcType="VARCHAR" property="contentId" />
+    <result column="article_title" jdbcType="VARCHAR" property="articleTitle" />
+    <result column="kimi_title" jdbcType="VARCHAR" property="kimiTitle" />
+    <result column="kimi_summary" jdbcType="VARCHAR" property="kimiSummary" />
+    <result column="kimi_keys" jdbcType="VARCHAR" property="kimiKeys" />
+    <result column="kimi_status" jdbcType="INTEGER" property="kimiStatus" />
+  </resultMap>
+  <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.tzld.piaoquan.longarticle.model.po.LongArticlesText">
+    <result column="article_text" jdbcType="LONGVARCHAR" property="articleText" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    content_id, article_title, kimi_title, kimi_summary, kimi_keys, kimi_status
+  </sql>
+  <sql id="Blob_Column_List">
+    article_text
+  </sql>
+  <select id="selectByExampleWithBLOBs" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesTextExample" resultMap="ResultMapWithBLOBs">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from long_articles_text
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesTextExample" resultMap="BaseResultMap">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from long_articles_text
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="ResultMapWithBLOBs">
+    select 
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from long_articles_text
+    where content_id = #{contentId,jdbcType=VARCHAR}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    delete from long_articles_text
+    where content_id = #{contentId,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesTextExample">
+    delete from long_articles_text
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesText">
+    insert into long_articles_text (content_id, article_title, kimi_title, 
+      kimi_summary, kimi_keys, kimi_status, 
+      article_text)
+    values (#{contentId,jdbcType=VARCHAR}, #{articleTitle,jdbcType=VARCHAR}, #{kimiTitle,jdbcType=VARCHAR}, 
+      #{kimiSummary,jdbcType=VARCHAR}, #{kimiKeys,jdbcType=VARCHAR}, #{kimiStatus,jdbcType=INTEGER}, 
+      #{articleText,jdbcType=LONGVARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesText">
+    insert into long_articles_text
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="contentId != null">
+        content_id,
+      </if>
+      <if test="articleTitle != null">
+        article_title,
+      </if>
+      <if test="kimiTitle != null">
+        kimi_title,
+      </if>
+      <if test="kimiSummary != null">
+        kimi_summary,
+      </if>
+      <if test="kimiKeys != null">
+        kimi_keys,
+      </if>
+      <if test="kimiStatus != null">
+        kimi_status,
+      </if>
+      <if test="articleText != null">
+        article_text,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="contentId != null">
+        #{contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="articleTitle != null">
+        #{articleTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiTitle != null">
+        #{kimiTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiSummary != null">
+        #{kimiSummary,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiKeys != null">
+        #{kimiKeys,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiStatus != null">
+        #{kimiStatus,jdbcType=INTEGER},
+      </if>
+      <if test="articleText != null">
+        #{articleText,jdbcType=LONGVARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesTextExample" resultType="java.lang.Long">
+    select count(*) from long_articles_text
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    update long_articles_text
+    <set>
+      <if test="record.contentId != null">
+        content_id = #{record.contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.articleTitle != null">
+        article_title = #{record.articleTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="record.kimiTitle != null">
+        kimi_title = #{record.kimiTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="record.kimiSummary != null">
+        kimi_summary = #{record.kimiSummary,jdbcType=VARCHAR},
+      </if>
+      <if test="record.kimiKeys != null">
+        kimi_keys = #{record.kimiKeys,jdbcType=VARCHAR},
+      </if>
+      <if test="record.kimiStatus != null">
+        kimi_status = #{record.kimiStatus,jdbcType=INTEGER},
+      </if>
+      <if test="record.articleText != null">
+        article_text = #{record.articleText,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExampleWithBLOBs" parameterType="map">
+    update long_articles_text
+    set content_id = #{record.contentId,jdbcType=VARCHAR},
+      article_title = #{record.articleTitle,jdbcType=VARCHAR},
+      kimi_title = #{record.kimiTitle,jdbcType=VARCHAR},
+      kimi_summary = #{record.kimiSummary,jdbcType=VARCHAR},
+      kimi_keys = #{record.kimiKeys,jdbcType=VARCHAR},
+      kimi_status = #{record.kimiStatus,jdbcType=INTEGER},
+      article_text = #{record.articleText,jdbcType=LONGVARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    update long_articles_text
+    set content_id = #{record.contentId,jdbcType=VARCHAR},
+      article_title = #{record.articleTitle,jdbcType=VARCHAR},
+      kimi_title = #{record.kimiTitle,jdbcType=VARCHAR},
+      kimi_summary = #{record.kimiSummary,jdbcType=VARCHAR},
+      kimi_keys = #{record.kimiKeys,jdbcType=VARCHAR},
+      kimi_status = #{record.kimiStatus,jdbcType=INTEGER}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesText">
+    update long_articles_text
+    <set>
+      <if test="articleTitle != null">
+        article_title = #{articleTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiTitle != null">
+        kimi_title = #{kimiTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiSummary != null">
+        kimi_summary = #{kimiSummary,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiKeys != null">
+        kimi_keys = #{kimiKeys,jdbcType=VARCHAR},
+      </if>
+      <if test="kimiStatus != null">
+        kimi_status = #{kimiStatus,jdbcType=INTEGER},
+      </if>
+      <if test="articleText != null">
+        article_text = #{articleText,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    where content_id = #{contentId,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKeyWithBLOBs" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesText">
+    update long_articles_text
+    set article_title = #{articleTitle,jdbcType=VARCHAR},
+      kimi_title = #{kimiTitle,jdbcType=VARCHAR},
+      kimi_summary = #{kimiSummary,jdbcType=VARCHAR},
+      kimi_keys = #{kimiKeys,jdbcType=VARCHAR},
+      kimi_status = #{kimiStatus,jdbcType=INTEGER},
+      article_text = #{articleText,jdbcType=LONGVARCHAR}
+    where content_id = #{contentId,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.tzld.piaoquan.longarticle.model.po.LongArticlesText">
+    update long_articles_text
+    set article_title = #{articleTitle,jdbcType=VARCHAR},
+      kimi_title = #{kimiTitle,jdbcType=VARCHAR},
+      kimi_summary = #{kimiSummary,jdbcType=VARCHAR},
+      kimi_keys = #{kimiKeys,jdbcType=VARCHAR},
+      kimi_status = #{kimiStatus,jdbcType=INTEGER}
+    where content_id = #{contentId,jdbcType=VARCHAR}
+  </update>
+</mapper>

+ 400 - 0
long-article-server/src/main/resources/mapper/MatchVideoMapper.xml

@@ -0,0 +1,400 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.tzld.piaoquan.longarticle.dao.mapper.MatchVideoMapper">
+  <resultMap id="BaseResultMap" type="com.tzld.piaoquan.longarticle.model.po.MatchVideo">
+    <id column="id" jdbcType="INTEGER" property="id" />
+    <result column="trace_id" jdbcType="VARCHAR" property="traceId" />
+    <result column="content_id" jdbcType="VARCHAR" property="contentId" />
+    <result column="flow_pool_level" jdbcType="VARCHAR" property="flowPoolLevel" />
+    <result column="gh_id" jdbcType="VARCHAR" property="ghId" />
+    <result column="account_name" jdbcType="VARCHAR" property="accountName" />
+    <result column="content_status" jdbcType="INTEGER" property="contentStatus" />
+    <result column="content_status_update_time" jdbcType="INTEGER" property="contentStatusUpdateTime" />
+    <result column="success_status" jdbcType="INTEGER" property="successStatus" />
+    <result column="request_timestamp" jdbcType="INTEGER" property="requestTimestamp" />
+    <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
+    <result column="process_times" jdbcType="INTEGER" property="processTimes" />
+  </resultMap>
+  <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.tzld.piaoquan.longarticle.model.po.MatchVideo">
+    <result column="response" jdbcType="LONGVARCHAR" property="response" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    id, trace_id, content_id, flow_pool_level, gh_id, account_name, content_status, content_status_update_time, 
+    success_status, request_timestamp, update_time, process_times
+  </sql>
+  <sql id="Blob_Column_List">
+    response
+  </sql>
+  <select id="selectByExampleWithBLOBs" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideoExample" resultMap="ResultMapWithBLOBs">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from long_articles_match_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideoExample" resultMap="BaseResultMap">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from long_articles_match_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="ResultMapWithBLOBs">
+    select 
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from long_articles_match_videos
+    where id = #{id,jdbcType=INTEGER}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
+    delete from long_articles_match_videos
+    where id = #{id,jdbcType=INTEGER}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideoExample">
+    delete from long_articles_match_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideo">
+    insert into long_articles_match_videos (id, trace_id, content_id, 
+      flow_pool_level, gh_id, account_name, 
+      content_status, content_status_update_time, 
+      success_status, request_timestamp, update_time, 
+      process_times, response)
+    values (#{id,jdbcType=INTEGER}, #{traceId,jdbcType=VARCHAR}, #{contentId,jdbcType=VARCHAR}, 
+      #{flowPoolLevel,jdbcType=VARCHAR}, #{ghId,jdbcType=VARCHAR}, #{accountName,jdbcType=VARCHAR}, 
+      #{contentStatus,jdbcType=INTEGER}, #{contentStatusUpdateTime,jdbcType=INTEGER}, 
+      #{successStatus,jdbcType=INTEGER}, #{requestTimestamp,jdbcType=INTEGER}, #{updateTime,jdbcType=TIMESTAMP}, 
+      #{processTimes,jdbcType=INTEGER}, #{response,jdbcType=LONGVARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideo">
+    insert into long_articles_match_videos
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        id,
+      </if>
+      <if test="traceId != null">
+        trace_id,
+      </if>
+      <if test="contentId != null">
+        content_id,
+      </if>
+      <if test="flowPoolLevel != null">
+        flow_pool_level,
+      </if>
+      <if test="ghId != null">
+        gh_id,
+      </if>
+      <if test="accountName != null">
+        account_name,
+      </if>
+      <if test="contentStatus != null">
+        content_status,
+      </if>
+      <if test="contentStatusUpdateTime != null">
+        content_status_update_time,
+      </if>
+      <if test="successStatus != null">
+        success_status,
+      </if>
+      <if test="requestTimestamp != null">
+        request_timestamp,
+      </if>
+      <if test="updateTime != null">
+        update_time,
+      </if>
+      <if test="processTimes != null">
+        process_times,
+      </if>
+      <if test="response != null">
+        response,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=INTEGER},
+      </if>
+      <if test="traceId != null">
+        #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="contentId != null">
+        #{contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="flowPoolLevel != null">
+        #{flowPoolLevel,jdbcType=VARCHAR},
+      </if>
+      <if test="ghId != null">
+        #{ghId,jdbcType=VARCHAR},
+      </if>
+      <if test="accountName != null">
+        #{accountName,jdbcType=VARCHAR},
+      </if>
+      <if test="contentStatus != null">
+        #{contentStatus,jdbcType=INTEGER},
+      </if>
+      <if test="contentStatusUpdateTime != null">
+        #{contentStatusUpdateTime,jdbcType=INTEGER},
+      </if>
+      <if test="successStatus != null">
+        #{successStatus,jdbcType=INTEGER},
+      </if>
+      <if test="requestTimestamp != null">
+        #{requestTimestamp,jdbcType=INTEGER},
+      </if>
+      <if test="updateTime != null">
+        #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="processTimes != null">
+        #{processTimes,jdbcType=INTEGER},
+      </if>
+      <if test="response != null">
+        #{response,jdbcType=LONGVARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideoExample" resultType="java.lang.Long">
+    select count(*) from long_articles_match_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    update long_articles_match_videos
+    <set>
+      <if test="record.id != null">
+        id = #{record.id,jdbcType=INTEGER},
+      </if>
+      <if test="record.traceId != null">
+        trace_id = #{record.traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.contentId != null">
+        content_id = #{record.contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.flowPoolLevel != null">
+        flow_pool_level = #{record.flowPoolLevel,jdbcType=VARCHAR},
+      </if>
+      <if test="record.ghId != null">
+        gh_id = #{record.ghId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.accountName != null">
+        account_name = #{record.accountName,jdbcType=VARCHAR},
+      </if>
+      <if test="record.contentStatus != null">
+        content_status = #{record.contentStatus,jdbcType=INTEGER},
+      </if>
+      <if test="record.contentStatusUpdateTime != null">
+        content_status_update_time = #{record.contentStatusUpdateTime,jdbcType=INTEGER},
+      </if>
+      <if test="record.successStatus != null">
+        success_status = #{record.successStatus,jdbcType=INTEGER},
+      </if>
+      <if test="record.requestTimestamp != null">
+        request_timestamp = #{record.requestTimestamp,jdbcType=INTEGER},
+      </if>
+      <if test="record.updateTime != null">
+        update_time = #{record.updateTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.processTimes != null">
+        process_times = #{record.processTimes,jdbcType=INTEGER},
+      </if>
+      <if test="record.response != null">
+        response = #{record.response,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExampleWithBLOBs" parameterType="map">
+    update long_articles_match_videos
+    set id = #{record.id,jdbcType=INTEGER},
+      trace_id = #{record.traceId,jdbcType=VARCHAR},
+      content_id = #{record.contentId,jdbcType=VARCHAR},
+      flow_pool_level = #{record.flowPoolLevel,jdbcType=VARCHAR},
+      gh_id = #{record.ghId,jdbcType=VARCHAR},
+      account_name = #{record.accountName,jdbcType=VARCHAR},
+      content_status = #{record.contentStatus,jdbcType=INTEGER},
+      content_status_update_time = #{record.contentStatusUpdateTime,jdbcType=INTEGER},
+      success_status = #{record.successStatus,jdbcType=INTEGER},
+      request_timestamp = #{record.requestTimestamp,jdbcType=INTEGER},
+      update_time = #{record.updateTime,jdbcType=TIMESTAMP},
+      process_times = #{record.processTimes,jdbcType=INTEGER},
+      response = #{record.response,jdbcType=LONGVARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    update long_articles_match_videos
+    set id = #{record.id,jdbcType=INTEGER},
+      trace_id = #{record.traceId,jdbcType=VARCHAR},
+      content_id = #{record.contentId,jdbcType=VARCHAR},
+      flow_pool_level = #{record.flowPoolLevel,jdbcType=VARCHAR},
+      gh_id = #{record.ghId,jdbcType=VARCHAR},
+      account_name = #{record.accountName,jdbcType=VARCHAR},
+      content_status = #{record.contentStatus,jdbcType=INTEGER},
+      content_status_update_time = #{record.contentStatusUpdateTime,jdbcType=INTEGER},
+      success_status = #{record.successStatus,jdbcType=INTEGER},
+      request_timestamp = #{record.requestTimestamp,jdbcType=INTEGER},
+      update_time = #{record.updateTime,jdbcType=TIMESTAMP},
+      process_times = #{record.processTimes,jdbcType=INTEGER}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideo">
+    update long_articles_match_videos
+    <set>
+      <if test="traceId != null">
+        trace_id = #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="contentId != null">
+        content_id = #{contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="flowPoolLevel != null">
+        flow_pool_level = #{flowPoolLevel,jdbcType=VARCHAR},
+      </if>
+      <if test="ghId != null">
+        gh_id = #{ghId,jdbcType=VARCHAR},
+      </if>
+      <if test="accountName != null">
+        account_name = #{accountName,jdbcType=VARCHAR},
+      </if>
+      <if test="contentStatus != null">
+        content_status = #{contentStatus,jdbcType=INTEGER},
+      </if>
+      <if test="contentStatusUpdateTime != null">
+        content_status_update_time = #{contentStatusUpdateTime,jdbcType=INTEGER},
+      </if>
+      <if test="successStatus != null">
+        success_status = #{successStatus,jdbcType=INTEGER},
+      </if>
+      <if test="requestTimestamp != null">
+        request_timestamp = #{requestTimestamp,jdbcType=INTEGER},
+      </if>
+      <if test="updateTime != null">
+        update_time = #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="processTimes != null">
+        process_times = #{processTimes,jdbcType=INTEGER},
+      </if>
+      <if test="response != null">
+        response = #{response,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKeyWithBLOBs" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideo">
+    update long_articles_match_videos
+    set trace_id = #{traceId,jdbcType=VARCHAR},
+      content_id = #{contentId,jdbcType=VARCHAR},
+      flow_pool_level = #{flowPoolLevel,jdbcType=VARCHAR},
+      gh_id = #{ghId,jdbcType=VARCHAR},
+      account_name = #{accountName,jdbcType=VARCHAR},
+      content_status = #{contentStatus,jdbcType=INTEGER},
+      content_status_update_time = #{contentStatusUpdateTime,jdbcType=INTEGER},
+      success_status = #{successStatus,jdbcType=INTEGER},
+      request_timestamp = #{requestTimestamp,jdbcType=INTEGER},
+      update_time = #{updateTime,jdbcType=TIMESTAMP},
+      process_times = #{processTimes,jdbcType=INTEGER},
+      response = #{response,jdbcType=LONGVARCHAR}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.tzld.piaoquan.longarticle.model.po.MatchVideo">
+    update long_articles_match_videos
+    set trace_id = #{traceId,jdbcType=VARCHAR},
+      content_id = #{contentId,jdbcType=VARCHAR},
+      flow_pool_level = #{flowPoolLevel,jdbcType=VARCHAR},
+      gh_id = #{ghId,jdbcType=VARCHAR},
+      account_name = #{accountName,jdbcType=VARCHAR},
+      content_status = #{contentStatus,jdbcType=INTEGER},
+      content_status_update_time = #{contentStatusUpdateTime,jdbcType=INTEGER},
+      success_status = #{successStatus,jdbcType=INTEGER},
+      request_timestamp = #{requestTimestamp,jdbcType=INTEGER},
+      update_time = #{updateTime,jdbcType=TIMESTAMP},
+      process_times = #{processTimes,jdbcType=INTEGER}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+</mapper>

+ 231 - 0
long-article-server/src/main/resources/mapper/OffVideoMapper.xml

@@ -0,0 +1,231 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.tzld.piaoquan.longarticle.dao.mapper.OffVideoMapper">
+  <resultMap id="BaseResultMap" type="com.tzld.piaoquan.longarticle.model.po.OffVideo">
+    <id column="video_id" jdbcType="BIGINT" property="videoId" />
+    <result column="publish_time" jdbcType="BIGINT" property="publishTime" />
+    <result column="video_status" jdbcType="INTEGER" property="videoStatus" />
+    <result column="trace_id" jdbcType="VARCHAR" property="traceId" />
+    <result column="get_off_time" jdbcType="BIGINT" property="getOffTime" />
+    <result column="check_status" jdbcType="INTEGER" property="checkStatus" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    video_id, publish_time, video_status, trace_id, get_off_time, check_status
+  </sql>
+  <select id="selectByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.OffVideoExample" resultMap="BaseResultMap">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from get_off_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
+    select 
+    <include refid="Base_Column_List" />
+    from get_off_videos
+    where video_id = #{videoId,jdbcType=BIGINT}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
+    delete from get_off_videos
+    where video_id = #{videoId,jdbcType=BIGINT}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.OffVideoExample">
+    delete from get_off_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.tzld.piaoquan.longarticle.model.po.OffVideo">
+    insert into get_off_videos (video_id, publish_time, video_status, 
+      trace_id, get_off_time, check_status
+      )
+    values (#{videoId,jdbcType=BIGINT}, #{publishTime,jdbcType=BIGINT}, #{videoStatus,jdbcType=INTEGER}, 
+      #{traceId,jdbcType=VARCHAR}, #{getOffTime,jdbcType=BIGINT}, #{checkStatus,jdbcType=INTEGER}
+      )
+  </insert>
+  <insert id="insertSelective" parameterType="com.tzld.piaoquan.longarticle.model.po.OffVideo">
+    insert into get_off_videos
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="videoId != null">
+        video_id,
+      </if>
+      <if test="publishTime != null">
+        publish_time,
+      </if>
+      <if test="videoStatus != null">
+        video_status,
+      </if>
+      <if test="traceId != null">
+        trace_id,
+      </if>
+      <if test="getOffTime != null">
+        get_off_time,
+      </if>
+      <if test="checkStatus != null">
+        check_status,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="videoId != null">
+        #{videoId,jdbcType=BIGINT},
+      </if>
+      <if test="publishTime != null">
+        #{publishTime,jdbcType=BIGINT},
+      </if>
+      <if test="videoStatus != null">
+        #{videoStatus,jdbcType=INTEGER},
+      </if>
+      <if test="traceId != null">
+        #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="getOffTime != null">
+        #{getOffTime,jdbcType=BIGINT},
+      </if>
+      <if test="checkStatus != null">
+        #{checkStatus,jdbcType=INTEGER},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.OffVideoExample" resultType="java.lang.Long">
+    select count(*) from get_off_videos
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    update get_off_videos
+    <set>
+      <if test="record.videoId != null">
+        video_id = #{record.videoId,jdbcType=BIGINT},
+      </if>
+      <if test="record.publishTime != null">
+        publish_time = #{record.publishTime,jdbcType=BIGINT},
+      </if>
+      <if test="record.videoStatus != null">
+        video_status = #{record.videoStatus,jdbcType=INTEGER},
+      </if>
+      <if test="record.traceId != null">
+        trace_id = #{record.traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.getOffTime != null">
+        get_off_time = #{record.getOffTime,jdbcType=BIGINT},
+      </if>
+      <if test="record.checkStatus != null">
+        check_status = #{record.checkStatus,jdbcType=INTEGER},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    update get_off_videos
+    set video_id = #{record.videoId,jdbcType=BIGINT},
+      publish_time = #{record.publishTime,jdbcType=BIGINT},
+      video_status = #{record.videoStatus,jdbcType=INTEGER},
+      trace_id = #{record.traceId,jdbcType=VARCHAR},
+      get_off_time = #{record.getOffTime,jdbcType=BIGINT},
+      check_status = #{record.checkStatus,jdbcType=INTEGER}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.tzld.piaoquan.longarticle.model.po.OffVideo">
+    update get_off_videos
+    <set>
+      <if test="publishTime != null">
+        publish_time = #{publishTime,jdbcType=BIGINT},
+      </if>
+      <if test="videoStatus != null">
+        video_status = #{videoStatus,jdbcType=INTEGER},
+      </if>
+      <if test="traceId != null">
+        trace_id = #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="getOffTime != null">
+        get_off_time = #{getOffTime,jdbcType=BIGINT},
+      </if>
+      <if test="checkStatus != null">
+        check_status = #{checkStatus,jdbcType=INTEGER},
+      </if>
+    </set>
+    where video_id = #{videoId,jdbcType=BIGINT}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.tzld.piaoquan.longarticle.model.po.OffVideo">
+    update get_off_videos
+    set publish_time = #{publishTime,jdbcType=BIGINT},
+      video_status = #{videoStatus,jdbcType=INTEGER},
+      trace_id = #{traceId,jdbcType=VARCHAR},
+      get_off_time = #{getOffTime,jdbcType=BIGINT},
+      check_status = #{checkStatus,jdbcType=INTEGER}
+    where video_id = #{videoId,jdbcType=BIGINT}
+  </update>
+</mapper>

+ 294 - 0
long-article-server/src/main/resources/mapper/RootSourceMapper.xml

@@ -0,0 +1,294 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.tzld.piaoquan.longarticle.dao.mapper.RootSourceMapper">
+  <resultMap id="BaseResultMap" type="com.tzld.piaoquan.longarticle.model.po.RootSource">
+    <id column="root_source_id" jdbcType="VARCHAR" property="rootSourceId" />
+    <result column="account_name" jdbcType="VARCHAR" property="accountName" />
+    <result column="gh_id" jdbcType="VARCHAR" property="ghId" />
+    <result column="article_title" jdbcType="VARCHAR" property="articleTitle" />
+    <result column="request_time" jdbcType="INTEGER" property="requestTime" />
+    <result column="trace_id" jdbcType="VARCHAR" property="traceId" />
+    <result column="push_type" jdbcType="INTEGER" property="pushType" />
+    <result column="video_id" jdbcType="BIGINT" property="videoId" />
+    <result column="content_id" jdbcType="VARCHAR" property="contentId" />
+    <result column="oss_name" jdbcType="VARCHAR" property="ossName" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    root_source_id, account_name, gh_id, article_title, request_time, trace_id, push_type, 
+    video_id, content_id, oss_name
+  </sql>
+  <select id="selectByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.RootSourceExample" resultMap="BaseResultMap">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from long_articles_root_source_id
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="page != null">
+      limit #{page.offset} , #{page.pageSize}
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
+    select 
+    <include refid="Base_Column_List" />
+    from long_articles_root_source_id
+    where root_source_id = #{rootSourceId,jdbcType=VARCHAR}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    delete from long_articles_root_source_id
+    where root_source_id = #{rootSourceId,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.RootSourceExample">
+    delete from long_articles_root_source_id
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.tzld.piaoquan.longarticle.model.po.RootSource">
+    insert into long_articles_root_source_id (root_source_id, account_name, gh_id, 
+      article_title, request_time, trace_id, 
+      push_type, video_id, content_id, 
+      oss_name)
+    values (#{rootSourceId,jdbcType=VARCHAR}, #{accountName,jdbcType=VARCHAR}, #{ghId,jdbcType=VARCHAR}, 
+      #{articleTitle,jdbcType=VARCHAR}, #{requestTime,jdbcType=INTEGER}, #{traceId,jdbcType=VARCHAR}, 
+      #{pushType,jdbcType=INTEGER}, #{videoId,jdbcType=BIGINT}, #{contentId,jdbcType=VARCHAR}, 
+      #{ossName,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.tzld.piaoquan.longarticle.model.po.RootSource">
+    insert into long_articles_root_source_id
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="rootSourceId != null">
+        root_source_id,
+      </if>
+      <if test="accountName != null">
+        account_name,
+      </if>
+      <if test="ghId != null">
+        gh_id,
+      </if>
+      <if test="articleTitle != null">
+        article_title,
+      </if>
+      <if test="requestTime != null">
+        request_time,
+      </if>
+      <if test="traceId != null">
+        trace_id,
+      </if>
+      <if test="pushType != null">
+        push_type,
+      </if>
+      <if test="videoId != null">
+        video_id,
+      </if>
+      <if test="contentId != null">
+        content_id,
+      </if>
+      <if test="ossName != null">
+        oss_name,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="rootSourceId != null">
+        #{rootSourceId,jdbcType=VARCHAR},
+      </if>
+      <if test="accountName != null">
+        #{accountName,jdbcType=VARCHAR},
+      </if>
+      <if test="ghId != null">
+        #{ghId,jdbcType=VARCHAR},
+      </if>
+      <if test="articleTitle != null">
+        #{articleTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="requestTime != null">
+        #{requestTime,jdbcType=INTEGER},
+      </if>
+      <if test="traceId != null">
+        #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="pushType != null">
+        #{pushType,jdbcType=INTEGER},
+      </if>
+      <if test="videoId != null">
+        #{videoId,jdbcType=BIGINT},
+      </if>
+      <if test="contentId != null">
+        #{contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="ossName != null">
+        #{ossName,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.tzld.piaoquan.longarticle.model.po.RootSourceExample" resultType="java.lang.Long">
+    select count(*) from long_articles_root_source_id
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    update long_articles_root_source_id
+    <set>
+      <if test="record.rootSourceId != null">
+        root_source_id = #{record.rootSourceId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.accountName != null">
+        account_name = #{record.accountName,jdbcType=VARCHAR},
+      </if>
+      <if test="record.ghId != null">
+        gh_id = #{record.ghId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.articleTitle != null">
+        article_title = #{record.articleTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="record.requestTime != null">
+        request_time = #{record.requestTime,jdbcType=INTEGER},
+      </if>
+      <if test="record.traceId != null">
+        trace_id = #{record.traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.pushType != null">
+        push_type = #{record.pushType,jdbcType=INTEGER},
+      </if>
+      <if test="record.videoId != null">
+        video_id = #{record.videoId,jdbcType=BIGINT},
+      </if>
+      <if test="record.contentId != null">
+        content_id = #{record.contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.ossName != null">
+        oss_name = #{record.ossName,jdbcType=VARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    update long_articles_root_source_id
+    set root_source_id = #{record.rootSourceId,jdbcType=VARCHAR},
+      account_name = #{record.accountName,jdbcType=VARCHAR},
+      gh_id = #{record.ghId,jdbcType=VARCHAR},
+      article_title = #{record.articleTitle,jdbcType=VARCHAR},
+      request_time = #{record.requestTime,jdbcType=INTEGER},
+      trace_id = #{record.traceId,jdbcType=VARCHAR},
+      push_type = #{record.pushType,jdbcType=INTEGER},
+      video_id = #{record.videoId,jdbcType=BIGINT},
+      content_id = #{record.contentId,jdbcType=VARCHAR},
+      oss_name = #{record.ossName,jdbcType=VARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.tzld.piaoquan.longarticle.model.po.RootSource">
+    update long_articles_root_source_id
+    <set>
+      <if test="accountName != null">
+        account_name = #{accountName,jdbcType=VARCHAR},
+      </if>
+      <if test="ghId != null">
+        gh_id = #{ghId,jdbcType=VARCHAR},
+      </if>
+      <if test="articleTitle != null">
+        article_title = #{articleTitle,jdbcType=VARCHAR},
+      </if>
+      <if test="requestTime != null">
+        request_time = #{requestTime,jdbcType=INTEGER},
+      </if>
+      <if test="traceId != null">
+        trace_id = #{traceId,jdbcType=VARCHAR},
+      </if>
+      <if test="pushType != null">
+        push_type = #{pushType,jdbcType=INTEGER},
+      </if>
+      <if test="videoId != null">
+        video_id = #{videoId,jdbcType=BIGINT},
+      </if>
+      <if test="contentId != null">
+        content_id = #{contentId,jdbcType=VARCHAR},
+      </if>
+      <if test="ossName != null">
+        oss_name = #{ossName,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where root_source_id = #{rootSourceId,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.tzld.piaoquan.longarticle.model.po.RootSource">
+    update long_articles_root_source_id
+    set account_name = #{accountName,jdbcType=VARCHAR},
+      gh_id = #{ghId,jdbcType=VARCHAR},
+      article_title = #{articleTitle,jdbcType=VARCHAR},
+      request_time = #{requestTime,jdbcType=INTEGER},
+      trace_id = #{traceId,jdbcType=VARCHAR},
+      push_type = #{pushType,jdbcType=INTEGER},
+      video_id = #{videoId,jdbcType=BIGINT},
+      content_id = #{contentId,jdbcType=VARCHAR},
+      oss_name = #{ossName,jdbcType=VARCHAR}
+    where root_source_id = #{rootSourceId,jdbcType=VARCHAR}
+  </update>
+</mapper>

+ 13 - 0
long-article-server/src/main/resources/mybatis-config.xml

@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-config.dtd">
+<configuration>
+    <properties>
+        <property name="dialect" value="mysql"/>
+    </properties>
+    <settings>
+        <!--<setting name="logImpl" value="LOG4J"/>-->
+        <setting name="mapUnderscoreToCamelCase" value="true" />
+        <!--<setting name="logImpl" value="STDOUT_LOGGING" />-->
+    </settings>
+</configuration>

+ 67 - 0
long-article-server/src/main/resources/mybatis-generator-config.xml

@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE generatorConfiguration
+        PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
+        "http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd">
+<!-- 配置生成器 -->
+<generatorConfiguration>
+    <context id="mysql" defaultModelType="flat">
+        <property name="autoDelimitKeywords" value="true"/>
+        <!-- 生成的Java文件的编码 -->
+        <property name="javaFileEncoding" value="UTF-8"/>
+        <!-- 格式化java代码 -->
+        <property name="javaFormatter" value="org.mybatis.generator.api.dom.DefaultJavaFormatter"/>
+        <!-- 格式化XML代码 -->
+        <property name="xmlFormatter" value="org.mybatis.generator.api.dom.DefaultXmlFormatter"/>
+        <!-- beginningDelimiter和endingDelimiter:指明数据库的用于标记数据库对象名的符号,比如ORACLE就是双引号,MYSQL默认是`反引号; -->
+        <property name="beginningDelimiter" value="`"/>
+        <property name="endingDelimiter" value="`"/>
+
+        <plugin type="org.mybatis.generator.plugins.ToStringPlugin"/>
+        <plugin type="org.mybatis.generator.plugins.UnmergeableXmlMappersPlugin"/>
+        <plugin type="com.tzld.piaoquan.longarticle.dao.generator.PaginationPlugin"/>
+
+        <commentGenerator>
+<!--            <property name="addRemarkComments" value="true"/>-->
+            <property name="suppressDate" value="true"/>
+            <property name="suppressAllComments" value="true"/>
+        </commentGenerator>
+
+        <jdbcConnection driverClass="com.mysql.jdbc.Driver"
+                        connectionURL="jdbc:mysql://rm-bp17q95335a99272b.mysql.rds.aliyuncs.com:3306/growth?useUnicode=true&amp;characterEncoding=utf-8&amp;zeroDateTimeBehavior=convertToNull&amp;useSSL=false"
+                        userId="crawler" password="crawler123456@">
+        </jdbcConnection>
+
+        <javaTypeResolver type="org.mybatis.generator.internal.types.JavaTypeResolverDefaultImpl">
+            <property name="forceBigDecimals" value="false"/>
+        </javaTypeResolver>
+
+        <javaModelGenerator targetPackage="com.tzld.piaoquan.longarticle.model.po" targetProject="/Users/shimeng/Desktop/project/long-article-manage/long-article-server/src/main/java">
+            <property name="constructorBased" value="false"/>
+            <property name="enableSubPackages" value="true"/>
+            <property name="immutable" value="false"/>
+        </javaModelGenerator>
+
+        <sqlMapGenerator targetPackage="mapper" targetProject="/Users/shimeng/Desktop/project/long-article-manage/long-article-server/src/main/resources">
+            <property name="enableSubPackages" value="true"/>
+        </sqlMapGenerator>
+
+        <javaClientGenerator targetPackage="com.tzld.piaoquan.longarticle.dao.mapper" type="XMLMAPPER"
+                             targetProject="/Users/shimeng/Desktop/project/long-article-manage/long-article-server/src/main/java">
+            <property name="enableSubPackages" value="true"/>
+        </javaClientGenerator>
+        <table tableName="long_articles_match_videos" domainObjectName="MatchVideo" alias="">
+            <columnOverride column="response" javaType="java.lang.String" jdbcType="LONGVARCHAR" />
+        </table>
+        <table tableName="long_articles_text" domainObjectName="LongArticlesText" alias="">
+            <columnOverride column="article_text" javaType="java.lang.String" jdbcType="LONGVARCHAR" />
+        </table>
+        <table tableName="long_articles_crawler_videos" domainObjectName="CrawlerVideo" alias="">
+            <columnOverride column="video_url" javaType="java.lang.String" jdbcType="LONGVARCHAR" />
+            <columnOverride column="cover_url" javaType="java.lang.String" jdbcType="LONGVARCHAR" />
+        </table>
+        <table tableName="long_articles_root_source_id" domainObjectName="RootSource" alias=""/>
+        <table tableName="get_off_videos" domainObjectName="OffVideo" alias=""/>
+
+    </context>
+
+</generatorConfiguration>

+ 18 - 0
pom.xml

@@ -179,7 +179,25 @@
             <version>5.8.33</version>
         </dependency>
 
+        <!-- https://mvnrepository.com/artifact/org.jsoup/jsoup -->
+        <dependency>
+            <groupId>org.jsoup</groupId>
+            <artifactId>jsoup</artifactId>
+            <version>1.18.1</version>
+        </dependency>
 
+        <dependency>
+            <groupId>com.aliyun.oss</groupId>
+            <artifactId>aliyun-sdk-oss</artifactId>
+            <version>3.17.0</version> <!-- 请根据需要选择版本 -->
+        </dependency>
+
+        <!-- https://mvnrepository.com/artifact/com.ctrip.framework.apollo/apollo-client -->
+        <dependency>
+            <groupId>com.ctrip.framework.apollo</groupId>
+            <artifactId>apollo-client</artifactId>
+            <version>2.3.0</version>
+        </dependency>
 
     </dependencies>
 </project>