[ISSUE #21] Implement Connection related code (#22)

* fixes #21

ADD:
connection related code:
Connection/Client/Connector: Mapper,Entity
Connection: ConnectionService,ConnectionDataService
others:
eventmesh-dashboard.sql
test resources

MODIFY:
pom file: remove dependency of junit, spring-boot-starter-test contains it.
pom file: let service module depend on core module.

* [ISSUE #23] Integrate Checkstyle into Build and CI process (#24)

* integrate checkstyle

* fix import order & remove excessive try-catch

* [ISSUE #23] Integrate Checkstyle into Build and CI process (#24)

* integrate checkstyle

* fix import order & remove excessive try-catch

* fixes #21

fixed according to PR#22 conversation
Database schema definition modified

* fix checkstyle for ConnectorMapper

* fix: add StatusEnum
add enum support for entity class.

* fix: rename KubernetesPodStatus

* fix checkstyle

---------

Co-authored-by: Pil0tXia <xiatian@apache.org>
diff --git a/eventmesh-dashboard-common/pom.xml b/eventmesh-dashboard-common/pom.xml
index f79bd00..52255b0 100644
--- a/eventmesh-dashboard-common/pom.xml
+++ b/eventmesh-dashboard-common/pom.xml
@@ -21,10 +21,6 @@
 
     <dependencies>
         <dependency>
-            <groupId>junit</groupId>
-            <artifactId>junit</artifactId>
-        </dependency>
-        <dependency>
             <groupId>org.projectlombok</groupId>
             <artifactId>lombok</artifactId>
         </dependency>
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/EventmeshConsoleApplication.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/EventMeshDashboardApplication.java
similarity index 80%
rename from eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/EventmeshConsoleApplication.java
rename to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/EventMeshDashboardApplication.java
index a048f24..79fc03d 100644
--- a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/EventmeshConsoleApplication.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/EventMeshDashboardApplication.java
@@ -20,16 +20,18 @@
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
 import org.springframework.context.annotation.ComponentScan;
+import org.springframework.scheduling.annotation.EnableScheduling;
 
 import lombok.extern.slf4j.Slf4j;
 
 @Slf4j
 @SpringBootApplication
+@EnableScheduling
 @ComponentScan({"org.apache.eventmesh.dashboard.service", "org.apache.eventmesh.dashboard.console"})
-public class EventmeshConsoleApplication {
+public class EventMeshDashboardApplication {
 
     public static void main(String[] args) {
-        SpringApplication.run(EventmeshConsoleApplication.class, args);
-        log.info("{} Successfully booted.", EventmeshConsoleApplication.class.getSimpleName());
+        SpringApplication.run(EventMeshDashboardApplication.class, args);
+        log.info("{} Successfully booted.", EventMeshDashboardApplication.class.getSimpleName());
     }
 }
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/config/SchedulerConfig.java
similarity index 62%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/config/SchedulerConfig.java
index 673282d..aba415a 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/config/SchedulerConfig.java
@@ -15,9 +15,19 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.config;
 
-public class Main {
-    public static void main(String[] args) {
+import org.springframework.context.annotation.Bean;
+import org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler;
+import org.springframework.stereotype.Component;
+
+@Component
+public class SchedulerConfig {
+
+    @Bean
+    public ThreadPoolTaskScheduler taskScheduler() {
+        ThreadPoolTaskScheduler taskScheduler = new ThreadPoolTaskScheduler();
+        taskScheduler.setPoolSize(5);
+        return taskScheduler;
     }
-}
\ No newline at end of file
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/config/SpringDocConfig.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/config/SpringDocConfig.java
new file mode 100644
index 0000000..12d33c8
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/config/SpringDocConfig.java
@@ -0,0 +1,42 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.config;
+
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
+
+import io.swagger.v3.oas.models.OpenAPI;
+import io.swagger.v3.oas.models.info.Info;
+import io.swagger.v3.oas.models.info.License;
+
+@Configuration
+public class SpringDocConfig {
+
+    @Bean
+    public OpenAPI eventmeshDashboardConsoleOpenAPI() {
+        return new OpenAPI()
+            .info(new Info()
+                .title("Eventmesh Dashboard Console API")
+                .version("v1")
+                .license(new License()
+                    .name("License: Apache 2.0")
+                    .url("http://www.apache.org/licenses/LICENSE-2.0")
+                )
+            );
+    }
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/constant/ApiPrefix.java
similarity index 77%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/constant/ApiPrefix.java
index 673282d..e2107cb 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/constant/ApiPrefix.java
@@ -15,9 +15,10 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.constant;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+public class ApiPrefix {
+    public static final String API_PREFIX = "/eventmesh-dashboard/";
+
+    public static final String API_V1_PREFIX = API_PREFIX + "v1/";
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/controller/connection/ConnectionController.java
similarity index 80%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/controller/connection/ConnectionController.java
index 673282d..72d407e 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/controller/connection/ConnectionController.java
@@ -15,9 +15,11 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.controller.connection;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+import org.springframework.web.bind.annotation.RestController;
+
+@RestController
+public class ConnectionController {
+
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/dto/ConnectionResponse.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/dto/ConnectionResponse.java
new file mode 100644
index 0000000..d4062a6
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/dto/ConnectionResponse.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.dto;
+
+import java.io.Serializable;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+
+public class ConnectionResponse implements Serializable {
+
+    private static final long serialVersionUID = -7317308457824435889L;
+
+    @Schema(name = "id", description = "primary key of table connection")
+    private Long id;
+
+    @Schema(name = "sourceType", defaultValue = "connector", allowableValues = {"connector", "client"})
+    private String sourceType;
+
+    @Schema(name = "sourceId", description = "connectorId or clientId")
+    private Long sourceId;
+
+    @Schema(name = "sourceStatus", defaultValue = "0", allowableValues = {"0", "1"}, description = "0:not active, 1:active")
+    private Integer sourceStatus;
+
+    //    @Schema(name = "sourceConfigList", description = "source config list")
+    //    private List<ConfigEntity> sourceConfigList;
+
+    @Schema(name = "sinkType", defaultValue = "connector", allowableValues = {"connector", "client"})
+    private String sinkType;
+
+    @Schema(name = "sinkId", description = "connectorId or clientId")
+    private Long sinkId;
+
+    @Schema(name = "sinkStatus", defaultValue = "0", allowableValues = {"0", "1"}, description = "0:not active, 1:active")
+    private Integer sinkStatus;
+
+    //    @Schema(name = "sinkConfigList", description = "sink config list")
+    //    private List<ConfigEntity> sinkConfigList;
+
+    private Long runtimeId;
+
+    @Schema(name = "status", defaultValue = "0", allowableValues = {"0", "1"}, description = "0:not active, 1:active")
+    private Integer status;
+
+    @Schema(name = "topic", description = "related topic name from storage")
+    private String topic;
+
+    private Long groupId;
+
+    private String groupName;
+
+    private String description;
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/base/BaseEntity.java
similarity index 62%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/base/BaseEntity.java
index 673282d..14192fa 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/base/BaseEntity.java
@@ -15,9 +15,24 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.entity.base;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+import java.io.Serializable;
+import java.sql.Timestamp;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import lombok.Data;
+
+@Data
+@Schema(name = "BaseEntity", description = "Base entity")
+public class BaseEntity implements Serializable {
+
+    private static final long serialVersionUID = -2697805837923579585L;
+
+    private Long clusterId;
+
+    protected Timestamp createTime;
+
+    protected Timestamp updateTime;
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/client/ClientEntity.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/client/ClientEntity.java
new file mode 100644
index 0000000..4da4dad
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/client/ClientEntity.java
@@ -0,0 +1,95 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.entity.client;
+
+import org.apache.eventmesh.dashboard.console.entity.base.BaseEntity;
+import org.apache.eventmesh.dashboard.console.enums.StatusEnum;
+
+import java.sql.Timestamp;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+@Data
+@NoArgsConstructor
+@AllArgsConstructor
+public class ClientEntity extends BaseEntity {
+
+    private static final long serialVersionUID = 8204133370609215856L;
+
+    /**
+     * Primary key
+     */
+    @Schema(name = "id", description = "primary key")
+    private Long id;
+
+    private String name;
+
+    private String platform;
+
+    /**
+     * programing language of client
+     */
+    @Schema(name = "language", example = "java")
+    private String language;
+
+    /**
+     * process id
+     */
+    @Schema(name = "pid", description = "process id")
+    private Long pid;
+
+    private String host;
+
+    private Integer port;
+
+    /**
+     * protocol used to connect to runtime.
+     */
+    @Schema(name = "protocol", example = "http", allowableValues = {"http", "grpc", "tcp"})
+    private String protocol;
+
+    /**
+     * 0: not active, 1: active
+     * @see StatusEnum
+     */
+    @Schema(name = "status", defaultValue = "0", allowableValues = {"0", "1"}, description = "0:not active, 1:active")
+    private Integer status;
+
+    /**
+     * csv format config id list.<br>
+     * Example value: 1,2,7<br>
+     * This field is updated when the configuration is modified via the web API, but is not used during the configuration retrieval process.
+     */
+    private String configIds;
+
+    private String description;
+
+    /**
+     * The time when the client is terminated.
+     */
+    private Timestamp endTime;
+
+    public void setStatusEntity(StatusEnum status) {
+        this.status = status.getNumber();
+    }
+}
+    
\ No newline at end of file
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/connection/ConnectionEntity.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/connection/ConnectionEntity.java
new file mode 100644
index 0000000..d4d21c5
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/connection/ConnectionEntity.java
@@ -0,0 +1,108 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.entity.connection;
+
+import org.apache.eventmesh.dashboard.console.entity.base.BaseEntity;
+import org.apache.eventmesh.dashboard.console.enums.StatusEnum;
+
+import java.sql.Timestamp;
+import java.util.Objects;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import lombok.Data;
+
+
+/**
+ * A Connection is a link from a source to a sink.
+ */
+@Data
+public class ConnectionEntity extends BaseEntity {
+
+    private static final long serialVersionUID = 6565578252656944905L;
+
+    /**
+     * Primary key
+     */
+    @Schema(name = "id", description = "primary key")
+    private Long id;
+
+    /**
+     * The type of source. Possible values are "connector" or "client".
+     */
+    @Schema(name = "sourceType", defaultValue = "connector", allowableValues = {"connector", "client"})
+    private String sourceType;
+
+    /**
+     * The id of the source.<br>
+     * It can be connectorId or clientId according to the sourceType.
+     */
+    @Schema(name = "sourceId", description = "connectorId or clientId")
+    private Long sourceId;
+
+    /**
+     * The type of sink. Possible values are "connector" or "client".
+     */
+    @Schema(name = "sinkType", defaultValue = "connector", allowableValues = {"connector", "client"})
+    private String sinkType;
+
+    /**
+     * The id of the sink.<br>
+     * It can be connectorId or clientId according to the sinkType.
+     */
+    @Schema(name = "sinkId", description = "connectorId or clientId")
+    private Long sinkId;
+
+    private Long runtimeId;
+
+    @Schema(name = "status", defaultValue = "0", allowableValues = {"0", "1"}, description = "0:inactive, 1:active")
+    private Integer status;
+
+    private String topic;
+
+    private Long groupId;
+
+    private Timestamp endTime;
+
+    private String description;
+
+    public void setStatusEnum(StatusEnum statusEnum) {
+        this.status = statusEnum.getNumber();
+    }
+
+    @Override
+    public boolean equals(Object o) {
+        if (this == o) {
+            return true;
+        }
+        if (o == null || getClass() != o.getClass()) {
+            return false;
+        }
+        ConnectionEntity that = (ConnectionEntity) o;
+        return Objects.equals(sourceType, that.sourceType)
+            && Objects.equals(sourceId, that.sourceId)
+
+            && Objects.equals(sinkType, that.sinkType)
+            && Objects.equals(sinkId, that.sinkId)
+
+            && Objects.equals(runtimeId, that.runtimeId)
+            && Objects.equals(status, that.status)
+
+            && Objects.equals(description, that.description);
+    }
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/connector/ConnectorEntity.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/connector/ConnectorEntity.java
new file mode 100644
index 0000000..1e7cb07
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/connector/ConnectorEntity.java
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.entity.connector;
+
+import org.apache.eventmesh.dashboard.console.entity.base.BaseEntity;
+import org.apache.eventmesh.dashboard.console.enums.KubernetesPodStatus;
+import org.apache.eventmesh.dashboard.console.enums.StatusEnum;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+@Data
+@NoArgsConstructor
+@AllArgsConstructor
+public class ConnectorEntity extends BaseEntity {
+
+    private static final long serialVersionUID = -8226303660232951326L;
+
+    @Schema(name = "id", description = "primary key")
+    private Long id;
+
+    private String name;
+
+    private String className;
+
+    private String type;
+
+    /**
+     * 0: not active, 1: active
+     *
+     * @see StatusEnum
+     */
+    @Schema(name = "status", defaultValue = "0", allowableValues = {"0", "1"}, description = "0:inactive, 1:active")
+    private Integer status;
+
+    /**
+     * @see KubernetesPodStatus
+     */
+    @Schema(name = "podState", defaultValue = "0", allowableValues = {"0", "1", "2", "3", "4", "5",
+        "6"}, description = "0:Pending, 1:Running, 2:Succeeded, 3:Failed, 4:Unknown, 5:Terminating, 6:Terminated")
+    private Integer podState;
+
+    /**
+     * csv format config id list.<br> Example value: 1,2,7<br> This field is updated when the configuration is modified via the web API, but is not
+     * used during the configuration retrieval process.
+     */
+    private String configIds;
+
+    public void setStatusEnum(StatusEnum statusEnum) {
+        this.status = statusEnum.getNumber();
+    }
+
+    public void setKubernetesPodStatusEnum(KubernetesPodStatus kubernetesPodStatusEnum) {
+        this.podState = kubernetesPodStatusEnum.getNumber();
+    }
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/meta/MetaEntity.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/meta/MetaEntity.java
new file mode 100644
index 0000000..2c32e28
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/entity/meta/MetaEntity.java
@@ -0,0 +1,70 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.entity.meta;
+
+import org.apache.eventmesh.dashboard.console.entity.base.BaseEntity;
+import org.apache.eventmesh.dashboard.console.enums.StatusEnum;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+@Data
+@NoArgsConstructor
+@AllArgsConstructor
+public class MetaEntity extends BaseEntity {
+
+    private static final long serialVersionUID = 7176263169716424469L;
+
+    /**
+     * Primary key
+     */
+    @Schema(name = "id", description = "Primary key")
+    private Long id;
+
+    private String name;
+
+    private String type;
+
+    private String version;
+
+    private Long clusterId;
+
+    private String host;
+
+    private Integer port;
+
+    private String role;
+
+    private String username;
+
+    private String params;
+
+    /**
+     * 0: not active, 1: active
+     * @see StatusEnum
+     */
+    @Schema(name = "status", defaultValue = "0", allowableValues = {"0", "1"}, description = "0:inactive, 1:active")
+    private Integer status;
+
+    public void setStatusEnum(StatusEnum statusEnum) {
+        this.status = statusEnum.getNumber();
+    }
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/enums/KubernetesPodStatus.java
similarity index 63%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/enums/KubernetesPodStatus.java
index 673282d..4650316 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/enums/KubernetesPodStatus.java
@@ -15,9 +15,22 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.enums;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+import lombok.AllArgsConstructor;
+import lombok.Getter;
+
+@Getter
+@AllArgsConstructor
+public enum KubernetesPodStatus {
+    PENDING(0, "Pending"),
+    RUNNING(1, "Running"),
+    SUCCEEDED(2, "Succeeded"),
+    FAILED(3, "Failed"),
+    UNKNOWN(4, "Unknown"),
+    TERMINATING(5, "Terminating"),
+    TERMINATED(6, "Terminated");
+
+    private final Integer number;
+    private final String name;
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/enums/StatusEnum.java
similarity index 73%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/enums/StatusEnum.java
index 673282d..271e3f2 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/enums/StatusEnum.java
@@ -15,9 +15,17 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.enums;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+import lombok.AllArgsConstructor;
+import lombok.Getter;
+
+@Getter
+@AllArgsConstructor
+public enum StatusEnum {
+    INACTIVE(0, "Inactive"),
+    ACTIVE(1, "Active");
+
+    private final Integer number;
+    private final String name;
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/client/ClientMapper.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/client/ClientMapper.java
new file mode 100644
index 0000000..671bd81
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/client/ClientMapper.java
@@ -0,0 +1,59 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.mapper.client;
+
+import org.apache.eventmesh.dashboard.console.entity.client.ClientEntity;
+
+import org.apache.ibatis.annotations.Delete;
+import org.apache.ibatis.annotations.Insert;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Options;
+import org.apache.ibatis.annotations.Select;
+import org.apache.ibatis.annotations.Update;
+
+/**
+ * Mybatis Mapper for the table of client.
+ */
+@Mapper
+public interface ClientMapper {
+
+    @Select("SELECT * FROM `client` WHERE `id` = #{id}")
+    ClientEntity selectById(Long id);
+
+    @Select("SELECT * FROM `client` WHERE `cluster_id` = #{clusterId}")
+    ClientEntity selectByClusterId(Long clusterId);
+
+    @Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
+    @Insert(
+        "INSERT INTO `client` (`cluster_id`, `name`, `platform`,"
+            + " `language`, `pid`, `host`, `port`, `protocol`,"
+            + " `status`, `config_ids`, `description`, `end_time`) "
+            + "VALUES (#{clusterId}, #{name}, #{platform},"
+            + " #{language}, #{pid}, #{host}, #{port}, #{protocol},"
+            + " #{status}, #{configIds}, #{description}, #{endTime})")
+    void insert(ClientEntity clientEntity);
+
+    @Update("UPDATE `client` SET status = #{status}, end_time = NOW() WHERE id = #{id}")
+    void deActive(ClientEntity clientEntity);
+
+    @Update("UPDATE `client` SET status = #{status} WHERE id = #{id}")
+    void updateStatus(ClientEntity clientEntity);
+
+    @Delete("DELETE FROM `client` WHERE id = #{id}")
+    void deleteById(Long id);
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/connection/ConnectionMapper.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/connection/ConnectionMapper.java
new file mode 100644
index 0000000..af0a2ac
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/connection/ConnectionMapper.java
@@ -0,0 +1,84 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.mapper.connection;
+
+import org.apache.eventmesh.dashboard.console.entity.connection.ConnectionEntity;
+
+import org.apache.ibatis.annotations.Delete;
+import org.apache.ibatis.annotations.Insert;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Options;
+import org.apache.ibatis.annotations.Select;
+import org.apache.ibatis.annotations.Update;
+
+import java.util.List;
+
+/**
+ * Mybatis Mapper for the table of connection.
+ */
+@Mapper
+public interface ConnectionMapper {
+
+    @Select("SELECT * FROM connection WHERE id = #{id}")
+    ConnectionEntity selectById(ConnectionEntity connectionEntity);
+
+    @Select("SELECT * FROM connection")
+    List<ConnectionEntity> selectAll();
+
+    @Select("SELECT * FROM connection WHERE cluster_id = #{clusterId}")
+    List<ConnectionEntity> selectByClusterId(ConnectionEntity connectionEntity);
+
+    @Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
+    @Insert("INSERT INTO connection (cluster_id, source_type, source_id,"
+        + " sink_type, sink_id, runtime_id, status, topic, group_id, description)"
+        + " VALUES ( #{clusterId}, #{sourceType}, #{sourceId}, "
+        + " #{sinkType}, #{sinkId},  #{runtimeId}, #{status}, #{topic}, #{groupId}, #{description})")
+    void insert(ConnectionEntity connectionEntity);
+
+    @Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
+    @Insert("<script>"
+        + "INSERT INTO connection (cluster_id, source_type, source_id,"
+        + " sink_type, sink_id, runtime_id, status,"
+        + " topic, group_id, description) VALUES "
+        +
+        "<foreach collection='list' item='connectionEntity' index='index' separator=','>"
+        + "(#{connectionEntity.clusterId}, #{connectionEntity.sourceType}, #{connectionEntity.sourceId},"
+        + " #{connectionEntity.sinkType}, #{connectionEntity.sinkId}, #{connectionEntity.runtimeId}, #{connectionEntity.status},"
+        + " #{connectionEntity.topic}, #{connectionEntity.groupId}, #{connectionEntity.description})"
+        + "</foreach>"
+        + "</script>")
+    void batchInsert(List<ConnectionEntity> connectionEntityList);
+
+    @Update("UPDATE connection SET status = #{status}, end_time = NOW() WHERE id = #{id}")
+    void endConnectionById(ConnectionEntity connectionEntity);
+
+    @Delete("DELETE FROM connection WHERE cluster_id = #{clusterId}")
+    void deleteAllByClusterId(ConnectionEntity connectionEntity);
+
+    @Delete("DELETE FROM connection WHERE id = #{id}")
+    void deleteById(ConnectionEntity connectionEntity);
+
+    @Delete("<script>"
+        + "DELETE FROM connection WHERE id IN "
+        + "<foreach item='item' index='index' collection='list' open='(' separator=',' close=')'>"
+        + "#{item.id}"
+        + "</foreach>"
+        + "</script>")
+    void batchDelete(List<ConnectionEntity> connectionEntityList);
+
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/connector/ConnectorMapper.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/connector/ConnectorMapper.java
new file mode 100644
index 0000000..0791327
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/connector/ConnectorMapper.java
@@ -0,0 +1,82 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.mapper.connector;
+
+import org.apache.eventmesh.dashboard.console.entity.connector.ConnectorEntity;
+
+import org.apache.ibatis.annotations.Delete;
+import org.apache.ibatis.annotations.Insert;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Options;
+import org.apache.ibatis.annotations.Select;
+import org.apache.ibatis.annotations.Update;
+
+import java.util.List;
+
+/**
+ * Mybatis Mapper for the table of connector.
+ */
+@Mapper
+public interface ConnectorMapper {
+
+    @Select("SELECT * FROM connector WHERE id = #{id}")
+    ConnectorEntity selectById(ConnectorEntity connectorEntity);
+
+    @Select("SELECT * FROM connector WHERE cluster_id = #{clusterId}")
+    ConnectorEntity selectByClusterId(ConnectorEntity connectorEntity);
+
+    @Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
+    @Insert("INSERT INTO connector (cluster_id, name, class_name, type, status, pod_state, config_ids) "
+        + "VALUES (#{connectClusterId}, #{name}, #{className}, #{type}, #{status}, #{podState}, #{configIds})")
+    void insert(ConnectorEntity connectorEntity);
+
+    @Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
+    @Insert("<script>"
+        + "INSERT INTO connector (cluster_id, name, class_name, type, status, pod_state, config_ids) VALUES "
+        +
+        "<foreach collection='list' item='connectorEntity' index='index' separator=','>"
+        + "(#{connectorEntity.connectClusterId}, #{connectorEntity.name}, #{connectorEntity.className},"
+        + " #{connectorEntity.type}, #{connectorEntity.status}, #{connectorEntity.podState}, #{connectorEntity.configIds})"
+        + "</foreach>"
+        + "</script>")
+    void batchInsert(List<ConnectorEntity> connectorEntityList);
+
+    @Update("UPDATE connector SET status = #{status} WHERE id = #{id}")
+    void updateStatus(ConnectorEntity connectorEntity);
+
+    @Update("UPDATE connector SET pod_state = #{podState} WHERE id = #{id}")
+    void updatePodState(ConnectorEntity connectorEntity);
+
+    @Update("UPDATE connector SET config_ids = #{configIds} WHERE id = #{id}")
+    void updateConfigIds(ConnectorEntity connectorEntity);
+
+    @Delete("DELETE FROM connector WHERE id = #{id}")
+    void deleteById(ConnectorEntity connectorEntity);
+
+    @Delete("DELETE FROM connector WHERE cluster_id = #{clusterId}")
+    void deleteByClusterId(ConnectorEntity connectorEntity);
+
+    @Delete("<script>"
+        + "DELETE FROM connector WHERE id IN "
+        +
+        "<foreach collection='list' item='connectorEntity' index='index' open='(' separator=',' close=')'>"
+        + "#{connectorEntity.id}"
+        + "</foreach>"
+        + "</script>")
+    void batchDelete(List<ConnectorEntity> connectorEntities);
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/meta/MetaMapper.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/meta/MetaMapper.java
new file mode 100644
index 0000000..f22bf74
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/mapper/meta/MetaMapper.java
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.mapper.meta;
+
+import org.apache.eventmesh.dashboard.console.entity.meta.MetaEntity;
+
+import org.apache.ibatis.annotations.Delete;
+import org.apache.ibatis.annotations.Insert;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Options;
+import org.apache.ibatis.annotations.Select;
+import org.apache.ibatis.annotations.Update;
+
+/**
+ * Mybatis Mapper for the table of meta.
+ */
+@Mapper
+public interface MetaMapper {
+    @Select("SELECT * FROM meta WHERE id = #{id}")
+    MetaEntity selectById(MetaEntity metaEntity);
+
+    @Select("SELECT * FROM meta WHERE cluster_id = #{clusterId}")
+    MetaEntity selectByClusterId(MetaEntity metaEntity);
+
+    @Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
+    @Insert("INSERT INTO meta (name, type, version, cluster_id, host, port, role, username, params, status)"
+        + " VALUES ( #{name}, #{type}, #{version}, #{clusterId}, #{host}, #{port}, #{role}, #{username}, #{params}, #{status})")
+    void insert(MetaEntity metaEntity);
+
+    @Update("UPDATE meta SET status = #{status} WHERE id = #{id}")
+    void update(MetaEntity metaEntity);
+
+    @Delete("DELETE FROM meta WHERE id = #{id}")
+    void deleteById(MetaEntity metaEntity);
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/scheduler/health/HealthCheckScheduler.java
similarity index 78%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/scheduler/health/HealthCheckScheduler.java
index 673282d..7263f7c 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/scheduler/health/HealthCheckScheduler.java
@@ -15,9 +15,14 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.scheduler.health;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+import org.springframework.stereotype.Component;
+
+import lombok.extern.slf4j.Slf4j;
+
+@Slf4j
+@Component
+public class HealthCheckScheduler {
+
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/client/ClientDataService.java
similarity index 83%
rename from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
rename to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/client/ClientDataService.java
index 673282d..4daa5ff 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/client/ClientDataService.java
@@ -15,9 +15,11 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.service.client;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+/**
+ * Service providing data of clients.
+ */
+public interface ClientDataService {
+
+}
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/ConnectionDataService.java
similarity index 66%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/ConnectionDataService.java
index 673282d..05361eb 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/ConnectionDataService.java
@@ -15,9 +15,17 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.service.connection;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+import org.apache.eventmesh.dashboard.console.entity.connection.ConnectionEntity;
+
+import java.util.List;
+
+/**
+ * Service providing data of connections.
+ */
+public interface ConnectionDataService {
+    List<ConnectionEntity> getAllConnections();
+
+    void replaceAllConnections(List<ConnectionEntity> connectionEntityList);
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/ConnectionService.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/ConnectionService.java
new file mode 100644
index 0000000..3faedd6
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/ConnectionService.java
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.service.connection;
+
+import org.apache.eventmesh.dashboard.console.entity.connection.ConnectionEntity;
+import org.apache.eventmesh.dashboard.console.service.connection.impl.ConnectionDataServiceDatabaseImpl;
+
+import java.util.List;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import lombok.extern.slf4j.Slf4j;
+
+@Slf4j
+@Service
+public class ConnectionService {
+    @Autowired
+    ConnectionDataService metaConnectionService;
+
+    @Autowired
+    ConnectionDataServiceDatabaseImpl databaseConnectionService;
+
+    public void syncConnection() {
+        try {
+            List<ConnectionEntity> connectionEntityList = metaConnectionService.getAllConnections();
+            databaseConnectionService.replaceAllConnections(connectionEntityList);
+        } catch (Exception e) {
+            log.error("sync connection info from {} to {} failed for reason:{}.",
+                metaConnectionService.getClass().getSimpleName(),
+                databaseConnectionService.getClass().getSimpleName(),
+                e.getMessage());
+        }
+    }
+}
diff --git a/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/impl/ConnectionDataServiceDatabaseImpl.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/impl/ConnectionDataServiceDatabaseImpl.java
new file mode 100644
index 0000000..780ee99
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connection/impl/ConnectionDataServiceDatabaseImpl.java
@@ -0,0 +1,85 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.eventmesh.dashboard.console.service.connection.impl;
+
+import org.apache.eventmesh.dashboard.console.entity.connection.ConnectionEntity;
+import org.apache.eventmesh.dashboard.console.mapper.connection.ConnectionMapper;
+import org.apache.eventmesh.dashboard.console.service.connection.ConnectionDataService;
+
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+
+@Service
+public class ConnectionDataServiceDatabaseImpl implements ConnectionDataService {
+
+    @Autowired
+    private ConnectionMapper connectionMapper;
+
+    public List<ConnectionEntity> getAllConnectionsByClusterId(Long clusterId) {
+        ConnectionEntity connectionEntity = new ConnectionEntity();
+        connectionEntity.setClusterId(clusterId);
+        return connectionMapper.selectByClusterId(connectionEntity);
+    }
+
+
+    @Override
+    public List<ConnectionEntity> getAllConnections() {
+        return connectionMapper.selectAll();
+    }
+
+
+    @Override
+    @Transactional
+    public void replaceAllConnections(List<ConnectionEntity> connectionEntityList) {
+        Map<Long, List<ConnectionEntity>> connectionsGroupedByClusterId = connectionEntityList.stream()
+            .collect(Collectors.groupingBy(ConnectionEntity::getClusterId));
+
+        connectionsGroupedByClusterId.forEach((clusterId, newConnections) -> {
+            ConnectionEntity connectionEntity = new ConnectionEntity();
+            connectionEntity.setClusterId(clusterId);
+            List<ConnectionEntity> existingConnections = connectionMapper.selectByClusterId(connectionEntity);
+
+            // Collect connections that are not in the new list
+            List<ConnectionEntity> connectionsToDelete = existingConnections.stream()
+                .filter(existingConnection -> !newConnections.contains(existingConnection))
+                .collect(Collectors.toList());
+
+            // Collect new connections that are not in the existing list
+            List<ConnectionEntity> connectionsToInsert = newConnections.stream()
+                .filter(connection -> !existingConnections.contains(connection))
+                .collect(Collectors.toList());
+
+            // Delete connections in batch
+            if (!connectionsToDelete.isEmpty()) {
+                connectionMapper.batchDelete(connectionsToDelete);
+            }
+
+            // Insert new connections in batch
+            if (!connectionsToInsert.isEmpty()) {
+                connectionMapper.batchInsert(connectionsToInsert);
+            }
+        });
+    }
+}
+
diff --git a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connector/ConnectorDataService.java
similarity index 82%
copy from eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
copy to eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connector/ConnectorDataService.java
index 673282d..b0b9642 100644
--- a/eventmesh-dashboard-common/src/main/java/org/apache/eventmesh/dashboard/common/Main.java
+++ b/eventmesh-dashboard-console/src/main/java/org/apache/eventmesh/dashboard/console/service/connector/ConnectorDataService.java
@@ -15,9 +15,11 @@
  * limitations under the License.
  */
 
-package org.apache.eventmesh.dashboard.common;
+package org.apache.eventmesh.dashboard.console.service.connector;
 
-public class Main {
-    public static void main(String[] args) {
-    }
-}
\ No newline at end of file
+/**
+ * Service providing data of connectors.
+ */
+public interface ConnectorDataService {
+
+}
diff --git a/eventmesh-dashboard-console/src/main/resources/application-dev.yml b/eventmesh-dashboard-console/src/main/resources/application-dev.yml
index bfe0280..1c5e840 100644
--- a/eventmesh-dashboard-console/src/main/resources/application-dev.yml
+++ b/eventmesh-dashboard-console/src/main/resources/application-dev.yml
@@ -17,8 +17,6 @@
 
 server:
   port: 9898
-  servlet:
-    context-path: "/eventmesh"
 
 spring:
   servlet:
@@ -46,6 +44,9 @@
       test-while-idle: true
       min-evictable-idle-time-millis: 300000
 
-
+# cron job config, use cron expression
+cron:
+    #health check job
+    health: "0/15 * * * * ? *"
 
 
diff --git a/eventmesh-dashboard-console/src/main/resources/eventmesh-dashboard.sql b/eventmesh-dashboard-console/src/main/resources/eventmesh-dashboard.sql
new file mode 100644
index 0000000..8de09e7
--- /dev/null
+++ b/eventmesh-dashboard-console/src/main/resources/eventmesh-dashboard.sql
@@ -0,0 +1,128 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+DROP TABLE IF EXISTS `client`;
+CREATE TABLE `client`
+(
+    `id`             bigint(20)          NOT NULL AUTO_INCREMENT COMMENT 'id',
+    `cluster_id` bigint(20)          NOT NULL DEFAULT '-1' COMMENT '集群ID',
+    `name`           varchar(192)        NOT NULL DEFAULT '' COMMENT '客户端名称',
+    `platform`       varchar(192)        NOT NULL DEFAULT '' COMMENT '客户端平台',
+    `language`       varchar(192)        NOT NULL DEFAULT '' COMMENT '客户端语言',
+    `pid`            bigint(22)          NOT NULL DEFAULT '-1' COMMENT '客户端进程ID',
+    `host`           varchar(128)        NOT NULL DEFAULT '' COMMENT '客户端地址',
+    `port`           int(16)             NOT NULL DEFAULT '-1' COMMENT '客户端端口',
+    `protocol`       varchar(192)        NOT NULL DEFAULT '' COMMENT '协议类型',
+    `status`         tinyint(4) unsigned NOT NULL DEFAULT '0' COMMENT '状态: 1启用,0未启用',
+    `config_ids`     text                NOT NULL DEFAULT '' COMMENT 'csv config id list, like:1,3,7',
+    `description`    text                NOT NULL DEFAULT '' COMMENT '客户端描述',
+    `create_time`    timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
+    `end_time`       timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '结束时间',
+    `update_time`    timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间',
+
+    PRIMARY KEY (`id`),
+    INDEX  `idx_cluster_id` (`cluster_id`)
+) ENGINE = InnoDB
+  DEFAULT CHARSET = utf8 COMMENT ='客户端信息表';
+
+
+
+DROP TABLE IF EXISTS `connector`;
+CREATE TABLE `connector`
+(
+    `id`                 bigint(20) unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
+    `cluster_id`     bigint(20)          NOT NULL DEFAULT '-1' COMMENT '集群ID',
+    `name`               varchar(512)        NOT NULL DEFAULT '' COMMENT 'Connector名称',
+    `class_name`         varchar(512)        NOT NULL DEFAULT '' COMMENT 'Connector类',
+    `type`               varchar(32)         NOT NULL DEFAULT '' COMMENT 'Connector类型',
+    `status`             tinyint(4) unsigned NOT NULL DEFAULT '0' COMMENT '状态: 1启用,0未启用',
+    `pod_state`          tinyint(4) unsigned NOT NULL DEFAULT '0' COMMENT 'k8s pod状态。0: pending;1: running;2: success;3: failed;4: unknown',
+    `config_ids`         text                NOT NULL DEFAULT '' COMMENT 'csv config id list, like:1,3,7',
+    `create_time`        timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
+    `update_time`        timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间',
+    PRIMARY KEY (`id`),
+    INDEX `idx_cluster_id` (`cluster_id`)
+) ENGINE = InnoDB
+  DEFAULT CHARSET = utf8 COMMENT ='Connector信息表';
+
+DROP TABLE IF EXISTS `connection`;
+CREATE TABLE `connection`
+(
+    `id`             bigint(20)          NOT NULL AUTO_INCREMENT COMMENT 'id',
+    `cluster_id` bigint(20)          NOT NULL DEFAULT '-1' COMMENT '集群ID',
+    `source_type`    varchar(64)         NOT NULL DEFAULT '' COMMENT 'source类型,可以为client或source connector',
+    `source_id`      bigint(20)          NOT NULL DEFAULT '-1' COMMENT 'client或source connector ID',
+    `sink_type`      varchar(64)         NOT NULL DEFAULT '' COMMENT 'sink类型,可以为client或sink connector',
+    `sink_id`        bigint(20)          NOT NULL DEFAULT '-1' COMMENT 'client或sink connector ID',
+    `runtime_id`     bigint(20)          NOT NULL DEFAULT '-1' COMMENT '对应runtime id',
+    `status`         tinyint(4) unsigned NOT NULL DEFAULT '0' COMMENT '状态: 1启用,0未启用',
+    `topic`          varchar(192)        NOT NULL DEFAULT '' COMMENT 'topic name',
+    `group_id`       bigint(20)          NOT NULL DEFAULT '-1' COMMENT 'GroupID',
+    `description`    text                NOT NULL DEFAULT '' COMMENT '客户端描述',
+    `create_time`    timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
+    `end_time`       timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '结束时间',
+    `update_time`    timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间',
+
+    PRIMARY KEY (`id`),
+    INDEX `idx_cluster_id` (`cluster_id`),
+    INDEX `idx_group_id` (`group_id`),
+    INDEX `idx_topic` (`topic`),
+    INDEX `idx_source_id` (`source_id`),
+    INDEX `idx_sink_id` (`sink_id`)
+) ENGINE = InnoDB
+  DEFAULT CHARSET = utf8 COMMENT ='client和connector连接关系,这里的client包括runtime';
+
+DROP TABLE IF EXISTS `health_check_result`;
+CREATE TABLE `health_check_result`
+(
+    `id`             bigint(20) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增id',
+    `dimension`      int(11)             NOT NULL DEFAULT '0' COMMENT '检查维度(0:未知,1:Cluster,2:Runtime,3:Topic,4:Group)',
+    `config_name`    varchar(192)        NOT NULL DEFAULT '' COMMENT '配置名',
+    `cluster_id` bigint(20)          NOT NULL DEFAULT '0' COMMENT '集群ID',
+    `res_name`       varchar(192)        NOT NULL DEFAULT '' COMMENT '资源名称',
+    `passed`         tinyint(4)          NOT NULL DEFAULT '0' COMMENT '检查通过(0:未通过,1:通过)',
+    `create_time`    timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
+    `update_time`    timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
+    PRIMARY KEY (`id`),
+    INDEX `idx_cluster_id` (`cluster_id`),
+    UNIQUE KEY `uniq_dimension_config_cluster_res` (`dimension`, `config_name`, `cluster_id`, `res_name`)
+) ENGINE = InnoDB
+  DEFAULT CHARSET = utf8 COMMENT ='健康检查结果';
+
+DROP TABLE IF EXISTS `meta`;
+CREATE TABLE `meta`
+(
+    `id`                   bigint(20) unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
+    `name`                 varchar(192)        NOT NULL DEFAULT '' COMMENT '注册中心名称',
+    `type`                 varchar(192)        NOT NULL DEFAULT '' COMMENT '注册中心类型,nacos,etcd,zookeeper',
+    `version`              varchar(128)        NOT NULL DEFAULT '' COMMENT '注册中心版本',
+    `cluster_id`       bigint(20)          NOT NULL DEFAULT '-1' COMMENT '集群ID',
+    `host`                 varchar(128)        NOT NULL DEFAULT '' COMMENT '注册中心地址',
+    `port`                 int(16)             NOT NULL DEFAULT '-1' COMMENT '注册中心端口',
+    `role`                 varchar(16)         NOT NULL DEFAULT '-1' COMMENT '角色, leader follower observer',
+    `username`             varchar(192)        NOT NULL DEFAULT '' COMMENT '注册中心用户名',
+    `params`               varchar(192)        NOT NULL DEFAULT '' COMMENT '注册中心启动参数',
+    `status`               tinyint(4) unsigned NOT NULL DEFAULT '0' COMMENT '状态: 1启用,0未启用',
+
+    `create_time`          timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
+    `update_time`          timestamp           NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间',
+
+    PRIMARY KEY (`id`),
+    INDEX `idx_cluster_id` (`cluster_id`)
+
+) ENGINE = InnoDB
+  DEFAULT CHARSET = utf8 COMMENT ='注册中心信息表';
\ No newline at end of file
diff --git a/eventmesh-dashboard-console/src/test/resources/application-test.yml b/eventmesh-dashboard-console/src/test/resources/application-test.yml
new file mode 100644
index 0000000..1a903d3
--- /dev/null
+++ b/eventmesh-dashboard-console/src/test/resources/application-test.yml
@@ -0,0 +1,36 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+spring:
+  datasource:
+    name: eventmesh-console
+    type: com.alibaba.druid.pool.DruidDataSource
+    druid:
+      driver-class-name: com.mysql.cj.jdbc.Driver
+      url: jdbc:mysql://localhost:3306/eventmesh-dashboard-test?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true&zeroDateTimeBehavior=convertToNull&allowPublicKeyRetrieval=true
+      username: root
+      password: root
+
+      initial-size: 1
+      max-active: 50
+      min-idle: 5
+      max-wait: 6000
+      validation-query: select 'x'
+      validation-query-timeout: 15
+      test-on-borrow: false
+      test-while-idle: true
+      min-evictable-idle-time-millis: 300000
\ No newline at end of file
diff --git a/eventmesh-dashboard-console/src/test/resources/connectiontest.sql b/eventmesh-dashboard-console/src/test/resources/connectiontest.sql
new file mode 100644
index 0000000..641ea5f
--- /dev/null
+++ b/eventmesh-dashboard-console/src/test/resources/connectiontest.sql
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+DELETE FROM `eventmesh-dashboard-test`.connection WHERE TRUE;
+ALTER TABLE `eventmesh-dashboard-test`.connection AUTO_INCREMENT = 1;
+
+insert into `eventmesh-dashboard-test`.connection (id, cluster_id, source_type, source_id, sink_type, sink_id, runtime_id, status, topic, group_id, description, create_time, end_time, update_time)
+values  (1, 1, 'connector', 1, 'connector', 1, 1, 0, 'test-topic', -1, '', '2024-01-27 11:55:11', '2024-01-27 11:55:11', '2024-01-27 11:55:11'),
+    (2, 1, 'connector', 2, 'connector', 2, 2, 0, 'test-topic', -1, '', '2024-01-27 11:55:11', '2024-01-27 11:55:11', '2024-01-27 11:55:11'),
+    (3, 1, 'connector', 3, 'connector', 3, 3, 0, 'test-topic', -1, '', '2024-01-27 11:55:11', '2024-01-27 11:55:11', '2024-01-27 11:55:11'),
+    (4, 2, 'connector', 1, 'connector', 1, 1, 0, 'test-topic', -1, '', '2024-01-27 11:55:11', '2024-01-27 11:55:11', '2024-01-27 11:55:11'),
+    (5, 2, 'client', 5, 'client', 5, 5, 0, 'test-topic', -1, '', '2024-01-27 11:55:11', '2024-01-27 11:55:11', '2024-01-27 11:55:11'),
+    (6, 3, 'client', 6, 'client', 6, 6, 0, 'test-topic', -1, '', '2024-01-27 11:55:11', '2024-01-27 11:55:11', '2024-01-27 11:55:11');
+
+
diff --git a/eventmesh-dashboard-core/src/test/java/org/apache/eventmesh/dashboard/core/EventMeshDashboardApplicationTest.java b/eventmesh-dashboard-core/src/test/java/org/apache/eventmesh/dashboard/core/EventMeshDashboardApplicationTest.java
index 0007c1d..cde38a4 100644
--- a/eventmesh-dashboard-core/src/test/java/org/apache/eventmesh/dashboard/core/EventMeshDashboardApplicationTest.java
+++ b/eventmesh-dashboard-core/src/test/java/org/apache/eventmesh/dashboard/core/EventMeshDashboardApplicationTest.java
@@ -1,3 +1,20 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
 package org.apache.eventmesh.dashboard.core;
 
 import org.springframework.boot.test.context.SpringBootTest;
diff --git a/pom.xml b/pom.xml
index e8ac69c..59cb187 100644
--- a/pom.xml
+++ b/pom.xml
@@ -104,6 +104,11 @@
         <artifactId>mybatis-spring-boot-starter</artifactId>
         <version>${mybatis-spring-boot.version}</version>
       </dependency>
+      <dependency>
+        <groupId>org.mybatis.spring.boot</groupId>
+        <artifactId>mybatis-spring-boot-starter-test</artifactId>
+        <version>${mybatis-spring-boot.version}</version>
+      </dependency>
     </dependencies>
   </dependencyManagement>