Package org.apache.camel.component.drill
Class DrillEndpoint
- java.lang.Object
-
- org.apache.camel.support.service.BaseService
-
- org.apache.camel.support.service.ServiceSupport
-
- org.apache.camel.support.DefaultEndpoint
-
- org.apache.camel.support.ScheduledPollEndpoint
-
- org.apache.camel.support.DefaultPollingEndpoint
-
- org.apache.camel.component.drill.DrillEndpoint
-
- All Implemented Interfaces:
AutoCloseable,org.apache.camel.CamelContextAware,org.apache.camel.Endpoint,org.apache.camel.IsSingleton,org.apache.camel.Service,org.apache.camel.ShutdownableService,org.apache.camel.spi.HasId,org.apache.camel.StatefulService,org.apache.camel.SuspendableService
@UriEndpoint(firstVersion="2.19.0", scheme="drill", title="Drill", syntax="drill:host", producerOnly=true, category={DATABASE,SQL}) public class DrillEndpoint extends org.apache.camel.support.DefaultPollingEndpointPerform queries against an Apache Drill cluster.
-
-
Constructor Summary
Constructors Constructor Description DrillEndpoint(String uri, DrillComponent component)creates a drill endpoint
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.camel.ConsumercreateConsumer(org.apache.camel.Processor processor)org.apache.camel.ProducercreateProducer()StringgetClusterId()StringgetDirectory()StringgetHost()DrillConnectionModegetMode()Connection mode: zk: Zookeeper drillbit: Drillbit direct connection https://drill.apache.org/docs/using-the-jdbc-driver/IntegergetPort()List<?>queryForList(ResultSet rs)voidsetClusterId(String clusterId)Cluster ID https://drill.apache.org/docs/using-the-jdbc-driver/#determining-the-cluster-idvoidsetDirectory(String directory)Drill directory in ZooKeepervoidsetHost(String host)ZooKeeper host name or IP address.voidsetMode(DrillConnectionMode mode)voidsetPort(Integer port)ZooKeeper port numberStringtoJDBCUri()-
Methods inherited from class org.apache.camel.support.ScheduledPollEndpoint
configureConsumer, configureProperties, configureScheduledPollConsumerProperties, doConfigureConsumer, doStart, doStop, getBackoffErrorThreshold, getBackoffIdleThreshold, getBackoffMultiplier, getDefaultDelay, getDelay, getInitialDelay, getPollStrategy, getRepeatCount, getRunLoggingLevel, getScheduledExecutorService, getScheduler, getSchedulerProperties, getTimeUnit, isGreedy, isSendEmptyMessageWhenIdle, isStartScheduler, isUseFixedDelay, setBackoffErrorThreshold, setBackoffIdleThreshold, setBackoffMultiplier, setDelay, setGreedy, setInitialDelay, setPollStrategy, setRepeatCount, setRunLoggingLevel, setScheduledExecutorService, setScheduler, setSchedulerProperties, setSendEmptyMessageWhenIdle, setStartScheduler, setTimeUnit, setUseFixedDelay
-
Methods inherited from class org.apache.camel.support.DefaultEndpoint
configureExchange, configurePollingConsumer, createAsyncProducer, createEndpointUri, createExchange, createExchange, createPollingConsumer, doInit, equals, getCamelContext, getComponent, getEndpointKey, getEndpointUri, getExceptionHandler, getExchangePattern, getId, getPollingConsumerBlockTimeout, getPollingConsumerQueueSize, hashCode, isAutowiredEnabled, isBridgeErrorHandler, isLazyStartProducer, isLenientProperties, isPollingConsumerBlockWhenFull, isPollingConsumerCopy, isSingleton, setAutowiredEnabled, setBridgeErrorHandler, setCamelContext, setComponent, setEndpointUri, setEndpointUriIfNotSpecified, setExceptionHandler, setExchangePattern, setLazyStartProducer, setPollingConsumerBlockTimeout, setPollingConsumerBlockWhenFull, setPollingConsumerCopy, setPollingConsumerQueueSize, setProperties, toString
-
Methods inherited from class org.apache.camel.support.service.BaseService
build, doBuild, doFail, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspend
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Constructor Detail
-
DrillEndpoint
public DrillEndpoint(String uri, DrillComponent component)
creates a drill endpoint- Parameters:
uri- the endpoint uricomponent- the component
-
-
Method Detail
-
createConsumer
public org.apache.camel.Consumer createConsumer(org.apache.camel.Processor processor) throws Exception- Specified by:
createConsumerin interfaceorg.apache.camel.Endpoint- Overrides:
createConsumerin classorg.apache.camel.support.DefaultPollingEndpoint- Throws:
Exception
-
toJDBCUri
public String toJDBCUri()
-
queryForList
public List<?> queryForList(ResultSet rs) throws SQLException
- Throws:
SQLException
-
getHost
public String getHost()
-
setHost
public void setHost(String host)
ZooKeeper host name or IP address. Use local instead of a host name or IP address to connect to the local Drillbit- Parameters:
host-
-
getPort
public Integer getPort()
-
setPort
public void setPort(Integer port)
ZooKeeper port number- Parameters:
port-
-
getDirectory
public String getDirectory()
-
setDirectory
public void setDirectory(String directory)
Drill directory in ZooKeeper- Parameters:
directory-
-
getClusterId
public String getClusterId()
-
setClusterId
public void setClusterId(String clusterId)
Cluster ID https://drill.apache.org/docs/using-the-jdbc-driver/#determining-the-cluster-id- Parameters:
clusterId-
-
getMode
public DrillConnectionMode getMode()
Connection mode: zk: Zookeeper drillbit: Drillbit direct connection https://drill.apache.org/docs/using-the-jdbc-driver/- Returns:
-
setMode
public void setMode(DrillConnectionMode mode)
-
-