Repository: camel
Updated Branches:
  refs/heads/master 358f45fd7 -> 47a50bcd2


http://git-wip-us.apache.org/repos/asf/camel/blob/1a3e4412/components/camel-mybatis/src/main/docs/mybatis-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-mybatis/src/main/docs/mybatis-component.adoc 
b/components/camel-mybatis/src/main/docs/mybatis-component.adoc
index ea66e90..28aaa0f 100644
--- a/components/camel-mybatis/src/main/docs/mybatis-component.adoc
+++ b/components/camel-mybatis/src/main/docs/mybatis-component.adoc
@@ -70,7 +70,7 @@ The MyBatis component supports 2 options which are listed 
below.
 
 
 // endpoint options: START
-The MyBatis component supports 29 endpoint options which are listed below:
+The MyBatis component supports 30 endpoint options which are listed below:
 
 {% raw %}
 [width="100%",cols="2,1,1m,1m,5",options="header"]
@@ -89,6 +89,7 @@ The MyBatis component supports 29 endpoint options which are 
listed below:
 | exceptionHandler | consumer (advanced) |  | ExceptionHandler | To let the 
consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler 
is enabled then this options is not in use. By default the consumer will deal 
with exceptions that will be logged at WARN/ERROR level and ignored.
 | exchangePattern | consumer (advanced) |  | ExchangePattern | Sets the 
exchange pattern when the consumer creates an exchange.
 | pollStrategy | consumer (advanced) |  | PollingConsumerPollStrategy | A 
pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to 
provide your custom implementation to control error handling usually occurred 
during the poll operation before an Exchange have been created and being routed 
in Camel.
+| processingStrategy | consumer (advanced) |  | MyBatisProcessingStrategy | To 
use a custom MyBatisProcessingStrategy
 | executorType | producer | SIMPLE | ExecutorType | The executor type to be 
used while executing statements. simple - executor does nothing special. reuse 
- executor reuses prepared statements. batch - executor reuses statements and 
batches updates.
 | statementType | producer |  | StatementType | Mandatory to specify for the 
producer to control which kind of operation to invoke.
 | synchronous | advanced | false | boolean | Sets whether synchronous 
processing should be strictly used or Camel is allowed to use asynchronous 
processing (if supported).

http://git-wip-us.apache.org/repos/asf/camel/blob/1a3e4412/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisComponent.java
----------------------------------------------------------------------
diff --git 
a/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisComponent.java
 
b/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisComponent.java
index fa9ec7f..1635ea7 100644
--- 
a/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisComponent.java
+++ 
b/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisComponent.java
@@ -22,6 +22,7 @@ import java.util.Map;
 
 import org.apache.camel.Endpoint;
 import org.apache.camel.impl.UriEndpointComponent;
+import org.apache.camel.spi.Metadata;
 import org.apache.camel.util.IOHelper;
 import org.apache.camel.util.ObjectHelper;
 import org.apache.camel.util.ResourceHelper;
@@ -33,7 +34,9 @@ import org.apache.ibatis.session.SqlSessionFactoryBuilder;
  */
 public class MyBatisComponent extends UriEndpointComponent {
 
+    @Metadata(label = "advanced")
     private SqlSessionFactory sqlSessionFactory;
+    @Metadata(defaultValue = "SqlMapConfig.xml")
     private String configurationUri = "SqlMapConfig.xml";
 
     public MyBatisComponent() {

http://git-wip-us.apache.org/repos/asf/camel/blob/1a3e4412/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisEndpoint.java
----------------------------------------------------------------------
diff --git 
a/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisEndpoint.java
 
b/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisEndpoint.java
index d8ccac4..c0d364d 100644
--- 
a/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisEndpoint.java
+++ 
b/components/camel-mybatis/src/main/java/org/apache/camel/component/mybatis/MyBatisEndpoint.java
@@ -37,7 +37,6 @@ import org.apache.ibatis.session.SqlSessionFactory;
 @UriEndpoint(scheme = "mybatis", title = "MyBatis", syntax = 
"mybatis:statement", consumerClass =  MyBatisConsumer.class, label = 
"database,sql")
 public class MyBatisEndpoint extends DefaultPollingEndpoint {
 
-    private MyBatisProcessingStrategy processingStrategy = new 
DefaultMyBatisProcessingStrategy();
     @UriPath @Metadata(required = "true")
     private String statement;
     @UriParam(label = "producer")
@@ -57,6 +56,8 @@ public class MyBatisEndpoint extends DefaultPollingEndpoint {
     private boolean useIterator = true;
     @UriParam(label = "consumer", optionalPrefix = "consumer.")
     private boolean routeEmptyResultSet;
+    @UriParam(label = "consumer,advanced")
+    private MyBatisProcessingStrategy processingStrategy = new 
DefaultMyBatisProcessingStrategy();
     @UriParam(label = "producer", defaultValue = "SIMPLE")
     private ExecutorType executorType;
 
@@ -156,6 +157,9 @@ public class MyBatisEndpoint extends DefaultPollingEndpoint 
{
         return processingStrategy;
     }
 
+    /**
+     * To use a custom MyBatisProcessingStrategy
+     */
     public void setProcessingStrategy(MyBatisProcessingStrategy 
processingStrategy) {
         this.processingStrategy = processingStrategy;
     }

Reply via email to