@Configuration @EnableConfigurationProperties(value=CanalSimpleProperties.class) @ConditionalOnBean(value=cn.harveychan.canal.client.handler.EntryHandler.class) @ConditionalOnProperty(value="canal.mode", havingValue="zk") @Import(value=ThreadPoolAutoConfiguration.class) public class ZookeeperClientAutoConfiguration extends Object
| 构造器和说明 |
|---|
ZookeeperClientAutoConfiguration(CanalSimpleProperties canalSimpleProperties) |
| 限定符和类型 | 方法和说明 |
|---|---|
MessageHandler |
messageHandler(RowDataHandler<com.alibaba.otter.canal.protocol.CanalEntry.RowData> rowDataHandler,
List<EntryHandler> entryHandlers) |
MessageHandler |
messageHandler(RowDataHandler<com.alibaba.otter.canal.protocol.CanalEntry.RowData> rowDataHandler,
List<EntryHandler> entryHandlers,
ExecutorService executorService) |
RowDataHandler<com.alibaba.otter.canal.protocol.CanalEntry.RowData> |
rowDataHandler() |
ZookeeperClusterCanalClient |
zookeeperClusterCanalClient(MessageHandler messageHandler) |
public ZookeeperClientAutoConfiguration(CanalSimpleProperties canalSimpleProperties)
@Bean public RowDataHandler<com.alibaba.otter.canal.protocol.CanalEntry.RowData> rowDataHandler()
@Bean
@ConditionalOnProperty(value="canal.async",
havingValue="true",
matchIfMissing=true)
public MessageHandler messageHandler(RowDataHandler<com.alibaba.otter.canal.protocol.CanalEntry.RowData> rowDataHandler,
List<EntryHandler> entryHandlers,
ExecutorService executorService)
@Bean
@ConditionalOnProperty(value="canal.async",
havingValue="false")
public MessageHandler messageHandler(RowDataHandler<com.alibaba.otter.canal.protocol.CanalEntry.RowData> rowDataHandler,
List<EntryHandler> entryHandlers)
@Bean(initMethod="start",
destroyMethod="stop")
public ZookeeperClusterCanalClient zookeeperClusterCanalClient(MessageHandler messageHandler)
Copyright © 2021. All rights reserved.