Browse Source

Merge branch 'master' into feature/mcy

# Conflicts:
#	client-adapter/launcher/src/main/resources/application-sample.yml
#	client-adapter/launcher/src/main/resources/application.yml
mcy 6 years ago
parent
commit
9d113dbc13

+ 14 - 4
client-adapter/launcher/pom.xml

@@ -1,5 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <?xml version="1.0" encoding="UTF-8"?>
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
     <parent>
     <parent>
         <artifactId>canal.client-adapter</artifactId>
         <artifactId>canal.client-adapter</artifactId>
         <groupId>com.alibaba.otter</groupId>
         <groupId>com.alibaba.otter</groupId>
@@ -151,12 +152,13 @@
                             <tasks>
                             <tasks>
                                 <copy todir="${project.basedir}/target/config" overwrite="true">
                                 <copy todir="${project.basedir}/target/config" overwrite="true">
                                     <fileset dir="${project.basedir}/src/main/resources" erroronmissingdir="true">
                                     <fileset dir="${project.basedir}/src/main/resources" erroronmissingdir="true">
-                                        <include name="*.yml" />
+                                        <include name="*.yml"/>
                                     </fileset>
                                     </fileset>
                                 </copy>
                                 </copy>
                                 <copy todir="${project.basedir}/target/config/hbase" overwrite="true">
                                 <copy todir="${project.basedir}/target/config/hbase" overwrite="true">
-                                    <fileset dir="${project.basedir}/../hbase/src/main/resources/hbase" erroronmissingdir="true">
-                                        <include name="*.yml" />
+                                    <fileset dir="${project.basedir}/../hbase/src/main/resources/hbase"
+                                             erroronmissingdir="true">
+                                        <include name="*.yml"/>
                                     </fileset>
                                     </fileset>
                                 </copy>
                                 </copy>
                                 <copy todir="${project.basedir}/target/config/es" overwrite="true">
                                 <copy todir="${project.basedir}/target/config/es" overwrite="true">
@@ -223,6 +225,14 @@
                         </executions>
                         </executions>
                     </plugin>
                     </plugin>
                 </plugins>
                 </plugins>
+                <resources>
+                    <resource>
+                        <directory>src/main/resources</directory>
+                        <excludes>
+                            <exclude>application.yml</exclude>
+                        </excludes>
+                    </resource>
+                </resources>
             </build>
             </build>
         </profile>
         </profile>
     </profiles>
     </profiles>

+ 0 - 53
client-adapter/launcher/src/main/resources/application-sample.yml

@@ -1,53 +0,0 @@
-server:
-  port: 8081
-logging:
-  level:
-    com.alibaba.otter.canal.client.adapter.hbase: DEBUG
-spring:
-  jackson:
-    date-format: yyyy-MM-dd HH:mm:ss
-    time-zone: GMT+8
-    default-property-inclusion: non_null
-
-canal.conf:
-  canalServerHost: 127.0.0.1:11111
-#  zookeeperHosts: slave1:2181
-#  bootstrapServers: slave1:6667 #or rocketmq
-#  flatMessage: true
-  canalInstances:
-  - instance: example
-    groups:
-    - outAdapters:
-#      - name: es
-#        hosts: 127.0.0.1:9300
-#        properties:
-#          cluster.name: elasticsearch
-      - name: logger
-#      - name: hbase
-#        properties:
-#          hbase.zookeeper.quorum: 127.0.0.1
-#          hbase.zookeeper.property.clientPort: 2181
-#          zookeeper.znode.parent: /hbase
-#  mqTopics:
-#  - mqMode: kafka
-#    topic: example
-#    groups:
-#    - groupId: g2
-#      outAdapters:
-#      - name: logger
-#  mqTopics:
-#  - mqMode: rocketmq
-#    topic: example
-#    groups:
-#    - groupId: g2
-#      outAdapters:
-#      - name: logger
-#
-adapter.conf:
-  datasourceConfigs:
-    defaultDS:
-      url: jdbc:mysql://127.0.0.1:3306/mytest?useUnicode=true
-      username: root
-      password: 121212
-  adapterConfigs:
-  - hbase/mytest_person2.yml

+ 39 - 2
client-adapter/launcher/src/main/resources/application.yml

@@ -8,5 +8,42 @@ spring:
     date-format: yyyy-MM-dd HH:mm:ss
     date-format: yyyy-MM-dd HH:mm:ss
     time-zone: GMT+8
     time-zone: GMT+8
     default-property-inclusion: non_null
     default-property-inclusion: non_null
-  profiles:
-    active: sample
+
+#canal.conf:
+#  canalServerHost: 127.0.0.1:11111
+#  zookeeperHosts: slave1:2181
+#  bootstrapServers: slave1:6667 #or rocketmq
+#  flatMessage: true
+#  canalInstances:
+#  - instance: example
+#    groups:
+#    - outAdapters:
+#      - name: logger
+#      - name: hbase
+#        properties:
+#          hbase.zookeeper.quorum: 127.0.0.1
+#          hbase.zookeeper.property.clientPort: 2181
+#          zookeeper.znode.parent: /hbase
+#  mqTopics:
+#  - mqMode: kafka
+#    topic: example
+#    groups:
+#    - groupId: g2
+#      outAdapters:
+#      - name: logger
+#  mqTopics:
+#  - mqMode: rocketmq
+#    topic: example
+#    groups:
+#    - groupId: g2
+#      outAdapters:
+#      - name: logger
+#
+#adapter.conf:
+#  datasourceConfigs:
+#    defaultDS:
+#      url: jdbc:mysql://127.0.0.1:3306/mytest?useUnicode=true
+#      username: root
+#      password: 121212
+#  adapterConfigs:
+#  - hbase/mytest_person2.yml