@UriEndpoint(firstVersion="2.10.0",
scheme="hbase",
title="HBase",
syntax="hbase:tableName",
category={BIGDATA,DATABASE,HADOOP})
public class HBaseEndpoint
extends org.apache.camel.support.DefaultEndpoint
| Constructor and Description |
|---|
HBaseEndpoint(String uri,
HBaseComponent component,
String tableName) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.camel.Consumer |
createConsumer(org.apache.camel.Processor processor) |
org.apache.camel.Producer |
createProducer() |
protected void |
doInit() |
protected void |
doStop() |
CellMappingStrategyFactory |
getCellMappingStrategyFactory() |
HBaseComponent |
getComponent() |
List<org.apache.hadoop.hbase.filter.Filter> |
getFilters() |
String |
getMappingStrategyClassName() |
String |
getMappingStrategyName() |
int |
getMaxMessagesPerPoll() |
int |
getMaxResults() |
String |
getOperation() |
HBaseRemoveHandler |
getRemoveHandler() |
Map<String,Object> |
getRowMapping() |
HBaseRow |
getRowModel() |
org.apache.hadoop.hbase.client.Table |
getTable()
Gets connection to the table (secured or not, depends on the object initialization) please remember to close the
table after use
|
org.apache.hadoop.security.UserGroupInformation |
getUserGroupInformation() |
boolean |
isRemove() |
void |
setCellMappingStrategyFactory(CellMappingStrategyFactory cellMappingStrategyFactory)
To use a custom CellMappingStrategyFactory that is responsible for mapping cells.
|
void |
setFilters(List<org.apache.hadoop.hbase.filter.Filter> filters)
A list of filters to use.
|
void |
setMappingStrategyClassName(String mappingStrategyClassName)
The class name of a custom mapping strategy implementation.
|
void |
setMappingStrategyName(String mappingStrategyName)
The strategy to use for mapping Camel messages to HBase columns.
|
void |
setMaxMessagesPerPoll(int maxMessagesPerPoll)
Gets the maximum number of messages as a limit to poll at each polling.
|
void |
setMaxResults(int maxResults)
The maximum number of rows to scan.
|
void |
setOperation(String operation)
The HBase operation to perform
|
void |
setRemove(boolean remove)
If the option is true, Camel HBase Consumer will remove the rows which it processes.
|
void |
setRemoveHandler(HBaseRemoveHandler removeHandler)
To use a custom HBaseRemoveHandler that is executed when a row is to be removed.
|
void |
setRowMapping(Map<String,Object> rowMapping)
To map the key/values from the Map to a
HBaseRow. |
void |
setRowModel(HBaseRow rowModel)
An instance of org.apache.camel.component.hbase.model.HBaseRow which describes how each row should be modeled
|
void |
setUserGroupInformation(org.apache.hadoop.security.UserGroupInformation userGroupInformation)
Defines privileges to communicate with HBase such as using kerberos.
|
configureConsumer, configureExchange, configurePollingConsumer, configureProperties, createAsyncProducer, createEndpointUri, createExchange, createExchange, createPollingConsumer, doStart, equals, getCamelContext, 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, toStringbuild, 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, suspendclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic HBaseEndpoint(String uri, HBaseComponent component, String tableName)
public org.apache.camel.Consumer createConsumer(org.apache.camel.Processor processor)
throws Exception
Exceptionpublic HBaseComponent getComponent()
getComponent in class org.apache.camel.support.DefaultEndpointpublic int getMaxResults()
public void setMaxResults(int maxResults)
public List<org.apache.hadoop.hbase.filter.Filter> getFilters()
public void setFilters(List<org.apache.hadoop.hbase.filter.Filter> filters)
public String getOperation()
public void setOperation(String operation)
public CellMappingStrategyFactory getCellMappingStrategyFactory()
public void setCellMappingStrategyFactory(CellMappingStrategyFactory cellMappingStrategyFactory)
public String getMappingStrategyName()
public void setMappingStrategyName(String mappingStrategyName)
public String getMappingStrategyClassName()
public void setMappingStrategyClassName(String mappingStrategyClassName)
public HBaseRow getRowModel()
public void setRowModel(HBaseRow rowModel)
public boolean isRemove()
public void setRemove(boolean remove)
public HBaseRemoveHandler getRemoveHandler()
public void setRemoveHandler(HBaseRemoveHandler removeHandler)
public int getMaxMessagesPerPoll()
public void setMaxMessagesPerPoll(int maxMessagesPerPoll)
public org.apache.hadoop.security.UserGroupInformation getUserGroupInformation()
public void setUserGroupInformation(org.apache.hadoop.security.UserGroupInformation userGroupInformation)
public void setRowMapping(Map<String,Object> rowMapping)
HBaseRow.
The following keys is supported:
protected void doInit()
throws Exception
doInit in class org.apache.camel.support.DefaultEndpointExceptionprotected void doStop()
throws Exception
doStop in class org.apache.camel.support.DefaultEndpointExceptionpublic org.apache.hadoop.hbase.client.Table getTable()
throws IOException
IOExceptionApache Camel