-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
yong.teng
committed
Nov 12, 2023
1 parent
50a1b9e
commit 523064a
Showing
22 changed files
with
402 additions
and
273 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,10 +21,26 @@ | |
* | Author: Yong.Teng <[email protected]> | | ||
* | Copyright @ 2013-2023 Buession.com Inc. | | ||
* +-------------------------------------------------------------------------------------------------------+ | ||
*/package com.buession.canal.client;/** | ||
* | ||
*/ | ||
package com.buession.canal.client; | ||
|
||
import com.buession.canal.client.adapter.AdapterClient; | ||
|
||
import java.util.Set; | ||
|
||
/** | ||
* Canal 上下文 | ||
* | ||
* @author Yong.Teng | ||
* @since 0.0.1 | ||
*/public interface CanalContext { | ||
*/ | ||
public interface CanalContext { | ||
|
||
/** | ||
* 返回所有 Canal 适配器 | ||
* | ||
* @return 所有 Canal 适配器 | ||
*/ | ||
Set<AdapterClient> getAdapterClients(); | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,10 +21,39 @@ | |
* | Author: Yong.Teng <[email protected]> | | ||
* | Copyright @ 2013-2023 Buession.com Inc. | | ||
* +-------------------------------------------------------------------------------------------------------+ | ||
*/package com.buession.canal.client;/** | ||
* | ||
*/ | ||
package com.buession.canal.client; | ||
|
||
import com.buession.canal.client.adapter.AdapterClient; | ||
|
||
import java.util.Set; | ||
|
||
/** | ||
* Canal 上下文 | ||
* | ||
* @author Yong.Teng | ||
* @since 0.0.1 | ||
*/public class DefaultCanalContext { | ||
*/ | ||
public class DefaultCanalContext implements CanalContext { | ||
|
||
/** | ||
* Canal 适配器 | ||
*/ | ||
private final Set<AdapterClient> adapterClients; | ||
|
||
/** | ||
* 构造函数 | ||
* | ||
* @param adapterClients | ||
* Canal 适配器 | ||
*/ | ||
public DefaultCanalContext(final Set<AdapterClient> adapterClients) { | ||
this.adapterClients = adapterClients; | ||
} | ||
|
||
@Override | ||
public Set<AdapterClient> getAdapterClients() { | ||
return adapterClients; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.