You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ja...@apache.org on 2020/11/12 14:32:41 UTC

[camel] branch master updated: CAMEL-15845: Add events consumer to GitHub component

This is an automated email from the ASF dual-hosted git repository.

jamesnetherton pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/master by this push:
     new 45af1c5  CAMEL-15845: Add events consumer to GitHub component
45af1c5 is described below

commit 45af1c538feffa2afb1b42c341eb30cd75ecf461
Author: James Netherton <ja...@gmail.com>
AuthorDate: Thu Nov 12 09:06:21 2020 +0000

    CAMEL-15845: Add events consumer to GitHub component
---
 .../apache/camel/catalog/components/github.json    |   3 +-
 .../camel/catalog/docs/github-component.adoc       |   5 +-
 .../component/github/GitHubEndpointConfigurer.java |   6 ++
 .../component/github/GitHubEndpointUriFactory.java |   3 +-
 .../org/apache/camel/component/github/github.json  |   3 +-
 .../src/main/docs/github-component.adoc            |   5 +-
 .../camel/component/github/GitHubConstants.java    |   2 +
 .../camel/component/github/GitHubEndpoint.java     |  17 ++++
 .../apache/camel/component/github/GitHubType.java  |   4 +-
 .../component/github/consumer/EventsConsumer.java  | 105 +++++++++++++++++++++
 .../github/event/GitHubEventFetchStrategy.java     |  38 ++++++++
 .../component/github/GitHubComponentTestBase.java  |   3 +
 .../github/consumer/EventConsumerTest.java         |  61 ++++++++++++
 .../consumer/EventConsumerWithStrategyTest.java    |  82 ++++++++++++++++
 .../github/services/MockEventService.java          |  69 ++++++++++++++
 .../github/services/MockRepositoryService.java     |   5 +
 .../builder/endpoint/StaticEndpointBuilders.java   |   8 +-
 .../endpoint/dsl/GitHubEndpointBuilderFactory.java |  36 ++++++-
 .../modules/ROOT/pages/github-component.adoc       |   5 +-
 19 files changed, 441 insertions(+), 19 deletions(-)

diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/github.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/github.json
index ec31a44..4287f87 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/github.json
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/github.json
@@ -27,7 +27,7 @@
     "basicPropertyBinding": { "kind": "property", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": true, "secret": false, "defaultValue": false, "description": "Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" }
   },
   "properties": {
-    "type": { "kind": "path", "displayName": "Type", "group": "common", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.github.GitHubType", "enum": [ "CLOSEPULLREQUEST", "PULLREQUESTCOMMENT", "COMMIT", "PULLREQUEST", "TAG", "PULLREQUESTSTATE", "PULLREQUESTFILES", "GETCOMMITFILE", "CREATEISSUE" ], "deprecated": false, "deprecationNote": "", "secret": false, "description": "What git operation to execute" },
+    "type": { "kind": "path", "displayName": "Type", "group": "common", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.github.GitHubType", "enum": [ "CLOSEPULLREQUEST", "PULLREQUESTCOMMENT", "COMMIT", "PULLREQUEST", "TAG", "PULLREQUESTSTATE", "PULLREQUESTFILES", "GETCOMMITFILE", "CREATEISSUE", "EVENT" ], "deprecated": false, "deprecationNote": "", "secret": false, "description": "What git operation to execute" },
     "branchName": { "kind": "path", "displayName": "Branch Name", "group": "consumer", "label": "consumer", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "Name of branch" },
     "oauthToken": { "kind": "parameter", "displayName": "Oauth Token", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "GitHub OAuth token, required unless username & password are provided" },
     "password": { "kind": "parameter", "displayName": "Password", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "GitHub password, required unless oauthToken is provided" },
@@ -36,6 +36,7 @@
     "username": { "kind": "parameter", "displayName": "Username", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "GitHub username, required unless oauthToken is provided" },
     "bridgeErrorHandler": { "kind": "parameter", "displayName": "Bridge Error Handler", "group": "consumer", "label": "consumer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled b [...]
     "sendEmptyMessageWhenIdle": { "kind": "parameter", "displayName": "Send Empty Message When Idle", "group": "consumer", "label": "consumer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "If the polling consumer did not poll any files, you can enable this option to send an empty message (no body) instead." },
+    "eventFetchStrategy": { "kind": "parameter", "displayName": "Event Fetch Strategy", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.component.github.event.GitHubEventFetchStrategy", "deprecated": false, "secret": false, "description": "To specify a custom strategy that configures how the EventsConsumer fetches events." },
     "exceptionHandler": { "kind": "parameter", "displayName": "Exception Handler", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.", "deprecated": false, "secret": false, "description": "To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with [...]
     "exchangePattern": { "kind": "parameter", "displayName": "Exchange Pattern", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut", "InOptionalOut" ], "deprecated": false, "secret": false, "description": "Sets the exchange pattern when the consumer creates an exchange." },
     "pollStrategy": { "kind": "parameter", "displayName": "Poll Strategy", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.spi.PollingConsumerPollStrategy", "deprecated": false, "secret": false, "description": "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 h [...]
diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/github-component.adoc b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/github-component.adoc
index f262f4e..65a92bf 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/github-component.adoc
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/github-component.adoc
@@ -85,12 +85,12 @@ with the following path and query parameters:
 [width="100%",cols="2,5,^1,2",options="header"]
 |===
 | Name | Description | Default | Type
-| *type* | *Required* What git operation to execute. There are 9 enums and the value can be one of: CLOSEPULLREQUEST, PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE, PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE |  | GitHubType
+| *type* | *Required* What git operation to execute. There are 10 enums and the value can be one of: CLOSEPULLREQUEST, PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE, PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE, EVENT |  | GitHubType
 | *branchName* | Name of branch |  | String
 |===
 
 
-=== Query Parameters (30 parameters):
+=== Query Parameters (31 parameters):
 
 
 [width="100%",cols="2,5,^1,2",options="header"]
@@ -103,6 +103,7 @@ with the following path and query parameters:
 | *username* (common) | GitHub username, required unless oauthToken is provided |  | String
 | *bridgeErrorHandler* (consumer) | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | boolean
 | *sendEmptyMessageWhenIdle* (consumer) | If the polling consumer did not poll any files, you can enable this option to send an empty message (no body) instead. | false | boolean
+| *eventFetchStrategy* (consumer) | To specify a custom strategy that configures how the EventsConsumer fetches events. |  | GitHubEventFetchStrategy
 | *exceptionHandler* (consumer) | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. |  | ExceptionHandler
 | *exchangePattern* (consumer) | Sets the exchange pattern when the consumer creates an exchange. There are 3 enums and the value can be one of: InOnly, InOut, InOptionalOut |  | ExchangePattern
 | *pollStrategy* (consumer) | 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. |  | PollingConsumerPollStrategy
diff --git a/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointConfigurer.java b/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointConfigurer.java
index b721cd1..73c036b 100644
--- a/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointConfigurer.java
+++ b/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointConfigurer.java
@@ -33,6 +33,8 @@ public class GitHubEndpointConfigurer extends PropertyConfigurerSupport implemen
         case "bridgeErrorHandler": target.setBridgeErrorHandler(property(camelContext, boolean.class, value)); return true;
         case "delay": target.setDelay(property(camelContext, long.class, value)); return true;
         case "encoding": target.setEncoding(property(camelContext, java.lang.String.class, value)); return true;
+        case "eventfetchstrategy":
+        case "eventFetchStrategy": target.setEventFetchStrategy(property(camelContext, org.apache.camel.component.github.event.GitHubEventFetchStrategy.class, value)); return true;
         case "exceptionhandler":
         case "exceptionHandler": target.setExceptionHandler(property(camelContext, org.apache.camel.spi.ExceptionHandler.class, value)); return true;
         case "exchangepattern":
@@ -92,6 +94,8 @@ public class GitHubEndpointConfigurer extends PropertyConfigurerSupport implemen
         case "bridgeErrorHandler": return boolean.class;
         case "delay": return long.class;
         case "encoding": return java.lang.String.class;
+        case "eventfetchstrategy":
+        case "eventFetchStrategy": return org.apache.camel.component.github.event.GitHubEventFetchStrategy.class;
         case "exceptionhandler":
         case "exceptionHandler": return org.apache.camel.spi.ExceptionHandler.class;
         case "exchangepattern":
@@ -152,6 +156,8 @@ public class GitHubEndpointConfigurer extends PropertyConfigurerSupport implemen
         case "bridgeErrorHandler": return target.isBridgeErrorHandler();
         case "delay": return target.getDelay();
         case "encoding": return target.getEncoding();
+        case "eventfetchstrategy":
+        case "eventFetchStrategy": return target.getEventFetchStrategy();
         case "exceptionhandler":
         case "exceptionHandler": return target.getExceptionHandler();
         case "exchangepattern":
diff --git a/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointUriFactory.java b/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointUriFactory.java
index e067cd0..559b97f 100644
--- a/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointUriFactory.java
+++ b/components/camel-github/src/generated/java/org/apache/camel/component/github/GitHubEndpointUriFactory.java
@@ -20,9 +20,10 @@ public class GitHubEndpointUriFactory extends org.apache.camel.support.component
     private static final Set<String> PROPERTY_NAMES;
     private static final Set<String> SECRET_PROPERTY_NAMES;
     static {
-        Set<String> props = new HashSet<>(32);
+        Set<String> props = new HashSet<>(33);
         props.add("basicPropertyBinding");
         props.add("backoffMultiplier");
+        props.add("eventFetchStrategy");
         props.add("synchronous");
         props.add("initialDelay");
         props.add("type");
diff --git a/components/camel-github/src/generated/resources/org/apache/camel/component/github/github.json b/components/camel-github/src/generated/resources/org/apache/camel/component/github/github.json
index ec31a44..4287f87 100644
--- a/components/camel-github/src/generated/resources/org/apache/camel/component/github/github.json
+++ b/components/camel-github/src/generated/resources/org/apache/camel/component/github/github.json
@@ -27,7 +27,7 @@
     "basicPropertyBinding": { "kind": "property", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": true, "secret": false, "defaultValue": false, "description": "Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" }
   },
   "properties": {
-    "type": { "kind": "path", "displayName": "Type", "group": "common", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.github.GitHubType", "enum": [ "CLOSEPULLREQUEST", "PULLREQUESTCOMMENT", "COMMIT", "PULLREQUEST", "TAG", "PULLREQUESTSTATE", "PULLREQUESTFILES", "GETCOMMITFILE", "CREATEISSUE" ], "deprecated": false, "deprecationNote": "", "secret": false, "description": "What git operation to execute" },
+    "type": { "kind": "path", "displayName": "Type", "group": "common", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.github.GitHubType", "enum": [ "CLOSEPULLREQUEST", "PULLREQUESTCOMMENT", "COMMIT", "PULLREQUEST", "TAG", "PULLREQUESTSTATE", "PULLREQUESTFILES", "GETCOMMITFILE", "CREATEISSUE", "EVENT" ], "deprecated": false, "deprecationNote": "", "secret": false, "description": "What git operation to execute" },
     "branchName": { "kind": "path", "displayName": "Branch Name", "group": "consumer", "label": "consumer", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "Name of branch" },
     "oauthToken": { "kind": "parameter", "displayName": "Oauth Token", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "GitHub OAuth token, required unless username & password are provided" },
     "password": { "kind": "parameter", "displayName": "Password", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "GitHub password, required unless oauthToken is provided" },
@@ -36,6 +36,7 @@
     "username": { "kind": "parameter", "displayName": "Username", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "GitHub username, required unless oauthToken is provided" },
     "bridgeErrorHandler": { "kind": "parameter", "displayName": "Bridge Error Handler", "group": "consumer", "label": "consumer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled b [...]
     "sendEmptyMessageWhenIdle": { "kind": "parameter", "displayName": "Send Empty Message When Idle", "group": "consumer", "label": "consumer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "If the polling consumer did not poll any files, you can enable this option to send an empty message (no body) instead." },
+    "eventFetchStrategy": { "kind": "parameter", "displayName": "Event Fetch Strategy", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.component.github.event.GitHubEventFetchStrategy", "deprecated": false, "secret": false, "description": "To specify a custom strategy that configures how the EventsConsumer fetches events." },
     "exceptionHandler": { "kind": "parameter", "displayName": "Exception Handler", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.", "deprecated": false, "secret": false, "description": "To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with [...]
     "exchangePattern": { "kind": "parameter", "displayName": "Exchange Pattern", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut", "InOptionalOut" ], "deprecated": false, "secret": false, "description": "Sets the exchange pattern when the consumer creates an exchange." },
     "pollStrategy": { "kind": "parameter", "displayName": "Poll Strategy", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.spi.PollingConsumerPollStrategy", "deprecated": false, "secret": false, "description": "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 h [...]
diff --git a/components/camel-github/src/main/docs/github-component.adoc b/components/camel-github/src/main/docs/github-component.adoc
index f262f4e..65a92bf 100644
--- a/components/camel-github/src/main/docs/github-component.adoc
+++ b/components/camel-github/src/main/docs/github-component.adoc
@@ -85,12 +85,12 @@ with the following path and query parameters:
 [width="100%",cols="2,5,^1,2",options="header"]
 |===
 | Name | Description | Default | Type
-| *type* | *Required* What git operation to execute. There are 9 enums and the value can be one of: CLOSEPULLREQUEST, PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE, PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE |  | GitHubType
+| *type* | *Required* What git operation to execute. There are 10 enums and the value can be one of: CLOSEPULLREQUEST, PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE, PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE, EVENT |  | GitHubType
 | *branchName* | Name of branch |  | String
 |===
 
 
-=== Query Parameters (30 parameters):
+=== Query Parameters (31 parameters):
 
 
 [width="100%",cols="2,5,^1,2",options="header"]
@@ -103,6 +103,7 @@ with the following path and query parameters:
 | *username* (common) | GitHub username, required unless oauthToken is provided |  | String
 | *bridgeErrorHandler* (consumer) | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | boolean
 | *sendEmptyMessageWhenIdle* (consumer) | If the polling consumer did not poll any files, you can enable this option to send an empty message (no body) instead. | false | boolean
+| *eventFetchStrategy* (consumer) | To specify a custom strategy that configures how the EventsConsumer fetches events. |  | GitHubEventFetchStrategy
 | *exceptionHandler* (consumer) | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. |  | ExceptionHandler
 | *exchangePattern* (consumer) | Sets the exchange pattern when the consumer creates an exchange. There are 3 enums and the value can be one of: InOnly, InOut, InOptionalOut |  | ExchangePattern
 | *pollStrategy* (consumer) | 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. |  | PollingConsumerPollStrategy
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubConstants.java b/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubConstants.java
index 87a88a7..8723a1e 100644
--- a/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubConstants.java
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubConstants.java
@@ -35,4 +35,6 @@ public interface GitHubConstants {
     String GITHUB_PULLREQUEST_HEAD_COMMIT_SHA = "GitHubPullRequestHeadCommitSHA";
 
     String GITHUB_ISSUE_TITLE = "GitHubIssueTitle";
+
+    String GITHUB_EVENT_SERVICE = "GitHubEventService";
 }
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubEndpoint.java b/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubEndpoint.java
index 51c0a22..ea1ddb9 100644
--- a/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubEndpoint.java
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubEndpoint.java
@@ -21,9 +21,11 @@ import org.apache.camel.Consumer;
 import org.apache.camel.Processor;
 import org.apache.camel.Producer;
 import org.apache.camel.component.github.consumer.CommitConsumer;
+import org.apache.camel.component.github.consumer.EventsConsumer;
 import org.apache.camel.component.github.consumer.PullRequestCommentConsumer;
 import org.apache.camel.component.github.consumer.PullRequestConsumer;
 import org.apache.camel.component.github.consumer.TagConsumer;
+import org.apache.camel.component.github.event.GitHubEventFetchStrategy;
 import org.apache.camel.component.github.producer.ClosePullRequestProducer;
 import org.apache.camel.component.github.producer.CreateIssueProducer;
 import org.apache.camel.component.github.producer.GetCommitFileProducer;
@@ -84,6 +86,8 @@ public class GitHubEndpoint extends ScheduledPollEndpoint {
     private String targetUrl;
     @UriParam(label = "producer")
     private String encoding;
+    @UriParam(label = "consumer,advanced")
+    private GitHubEventFetchStrategy eventFetchStrategy;
 
     public GitHubEndpoint(String uri, GitHubComponent component) {
         super(uri, component);
@@ -119,6 +123,8 @@ public class GitHubEndpoint extends ScheduledPollEndpoint {
             consumer = new PullRequestCommentConsumer(this, processor);
         } else if (type == GitHubType.TAG) {
             consumer = new TagConsumer(this, processor);
+        } else if (type == GitHubType.EVENT) {
+            consumer = new EventsConsumer(this, processor);
         }
 
         if (consumer == null) {
@@ -242,4 +248,15 @@ public class GitHubEndpoint extends ScheduledPollEndpoint {
     public void setEncoding(String encoding) {
         this.encoding = encoding;
     }
+
+    public GitHubEventFetchStrategy getEventFetchStrategy() {
+        return eventFetchStrategy;
+    }
+
+    /**
+     * To specify a custom strategy that configures how the EventsConsumer fetches events.
+     */
+    public void setEventFetchStrategy(GitHubEventFetchStrategy eventFetchStrategy) {
+        this.eventFetchStrategy = eventFetchStrategy;
+    }
 }
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubType.java b/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubType.java
index 2eee9f2..330536b 100644
--- a/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubType.java
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/GitHubType.java
@@ -26,6 +26,6 @@ public enum GitHubType {
     PULLREQUESTSTATE,
     PULLREQUESTFILES,
     GETCOMMITFILE,
-    CREATEISSUE
-
+    CREATEISSUE,
+    EVENT;
 }
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/EventsConsumer.java b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/EventsConsumer.java
new file mode 100644
index 0000000..dc211ef
--- /dev/null
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/EventsConsumer.java
@@ -0,0 +1,105 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.github.consumer;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
+
+import org.apache.camel.Exchange;
+import org.apache.camel.Processor;
+import org.apache.camel.component.github.GitHubConstants;
+import org.apache.camel.component.github.GitHubEndpoint;
+import org.apache.camel.component.github.event.GitHubEventFetchStrategy;
+import org.apache.camel.spi.Registry;
+import org.eclipse.egit.github.core.Repository;
+import org.eclipse.egit.github.core.client.PageIterator;
+import org.eclipse.egit.github.core.event.Event;
+import org.eclipse.egit.github.core.service.EventService;
+
+public class EventsConsumer extends AbstractGitHubConsumer {
+
+    private final EventService eventService;
+    private final GitHubEventFetchStrategy eventFetchStrategy;
+    private long lastEventId;
+
+    public EventsConsumer(GitHubEndpoint endpoint, Processor processor) throws Exception {
+        super(endpoint, processor);
+
+        Registry registry = endpoint.getCamelContext().getRegistry();
+        EventService service = registry.lookupByNameAndType(GitHubConstants.GITHUB_EVENT_SERVICE, EventService.class);
+        if (service != null) {
+            eventService = service;
+        } else {
+            eventService = new EventService();
+        }
+
+        initService(eventService);
+
+        GitHubEventFetchStrategy strategy = endpoint.getEventFetchStrategy();
+        if (strategy != null) {
+            eventFetchStrategy = strategy;
+        } else {
+            eventFetchStrategy = new DefaultGitHubEventFetchStrategy(getRepository());
+        }
+    }
+
+    @Override
+    protected int poll() throws Exception {
+        List<Event> newEvents = new ArrayList<>();
+        PageIterator<Event> iterator = eventFetchStrategy.fetchEvents(eventService);
+
+        while (iterator.hasNext()) {
+            Collection<Event> events = iterator.next();
+            for (Event event : events) {
+                if (Long.parseLong(event.getId()) > lastEventId) {
+                    newEvents.add(event);
+                }
+            }
+        }
+
+        if (!newEvents.isEmpty()) {
+            newEvents.sort((e1, e2) -> Long.valueOf(e1.getId()).compareTo(Long.parseLong(e2.getId())));
+            Event latestEvent = newEvents.get(newEvents.size() - 1);
+            lastEventId = Long.parseLong(latestEvent.getId());
+
+            for (Event event : newEvents) {
+                Exchange exchange = getEndpoint().createExchange();
+                exchange.getMessage().setBody(event);
+                getProcessor().process(exchange);
+            }
+        }
+
+        return newEvents.size();
+    }
+
+    /**
+     * Default {@link GitHubEventFetchStrategy} to fetch events for the GitHub repository configured on the endpoint.
+     */
+    private static final class DefaultGitHubEventFetchStrategy implements GitHubEventFetchStrategy {
+        private final Repository repository;
+
+        private DefaultGitHubEventFetchStrategy(Repository repository) {
+            this.repository = repository;
+        }
+
+        @Override
+        public PageIterator<Event> fetchEvents(EventService eventService) {
+            return eventService.pageEvents(repository);
+        }
+    }
+}
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/event/GitHubEventFetchStrategy.java b/components/camel-github/src/main/java/org/apache/camel/component/github/event/GitHubEventFetchStrategy.java
new file mode 100644
index 0000000..8dc0015
--- /dev/null
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/event/GitHubEventFetchStrategy.java
@@ -0,0 +1,38 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.github.event;
+
+import org.eclipse.egit.github.core.client.PageIterator;
+import org.eclipse.egit.github.core.event.Event;
+import org.eclipse.egit.github.core.service.EventService;
+
+/**
+ * An abstraction that allows customization of how the {@link org.apache.camel.component.github.consumer.EventsConsumer}
+ * fetches GitHub events.
+ *
+ * The default strategy is to fetch events for the repository that was configured on the consumer.
+ */
+public interface GitHubEventFetchStrategy {
+
+    /**
+     * Fetches GitHub events from the {@link EventService}.
+     * 
+     * @param  eventService The {@link EventService} for interacting with the GitHub event APIs
+     * @return              {@link PageIterator} of event objects
+     */
+    PageIterator<Event> fetchEvents(EventService eventService);
+}
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/GitHubComponentTestBase.java b/components/camel-github/src/test/java/org/apache/camel/component/github/GitHubComponentTestBase.java
index 5c8a2f3..b983796 100644
--- a/components/camel-github/src/test/java/org/apache/camel/component/github/GitHubComponentTestBase.java
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/GitHubComponentTestBase.java
@@ -19,6 +19,7 @@ package org.apache.camel.component.github;
 import org.apache.camel.BindToRegistry;
 import org.apache.camel.EndpointInject;
 import org.apache.camel.component.github.services.MockCommitService;
+import org.apache.camel.component.github.services.MockEventService;
 import org.apache.camel.component.github.services.MockIssueService;
 import org.apache.camel.component.github.services.MockPullRequestService;
 import org.apache.camel.component.github.services.MockRepositoryService;
@@ -40,6 +41,8 @@ public abstract class GitHubComponentTestBase extends CamelTestSupport {
     protected MockPullRequestService pullRequestService = new MockPullRequestService();
     @BindToRegistry(GitHubConstants.GITHUB_ISSUE_SERVICE)
     protected MockIssueService issueService = new MockIssueService(pullRequestService);
+    @BindToRegistry(GitHubConstants.GITHUB_EVENT_SERVICE)
+    protected MockEventService eventService = new MockEventService();
 
     @EndpointInject("mock:result")
     protected MockEndpoint mockResultEndpoint;
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/consumer/EventConsumerTest.java b/components/camel-github/src/test/java/org/apache/camel/component/github/consumer/EventConsumerTest.java
new file mode 100644
index 0000000..17094f9
--- /dev/null
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/consumer/EventConsumerTest.java
@@ -0,0 +1,61 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.github.consumer;
+
+import org.apache.camel.RoutesBuilder;
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.github.GitHubComponentTestBase;
+import org.eclipse.egit.github.core.event.Event;
+import org.eclipse.egit.github.core.event.IssueCommentPayload;
+import org.eclipse.egit.github.core.event.PushPayload;
+import org.eclipse.egit.github.core.event.WatchPayload;
+import org.junit.jupiter.api.Test;
+
+public class EventConsumerTest extends GitHubComponentTestBase {
+
+    @Test
+    public void getEvents() throws Exception {
+        Event watchEvent = new Event();
+        watchEvent.setId("1");
+        watchEvent.setPayload(new WatchPayload());
+        eventService.addEvent(watchEvent);
+
+        Event pushEvent = new Event();
+        pushEvent.setId("2");
+        pushEvent.setPayload(new PushPayload());
+        eventService.addEvent(pushEvent);
+
+        Event issueCommentEvent = new Event();
+        issueCommentEvent.setId("3");
+        issueCommentEvent.setPayload(new IssueCommentPayload());
+        eventService.addEvent(issueCommentEvent);
+
+        mockResultEndpoint.expectedBodiesReceivedInAnyOrder(watchEvent, pushEvent, issueCommentEvent);
+        mockResultEndpoint.assertIsSatisfied(5000);
+    }
+
+    @Override
+    protected RoutesBuilder createRouteBuilder() throws Exception {
+        return new RouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                from("github:event?username=someguy&password=apassword&repoOwner=anotherguy&repoName=somerepo")
+                        .to(mockResultEndpoint);
+            }
+        };
+    }
+}
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/consumer/EventConsumerWithStrategyTest.java b/components/camel-github/src/test/java/org/apache/camel/component/github/consumer/EventConsumerWithStrategyTest.java
new file mode 100644
index 0000000..bb7e67c
--- /dev/null
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/consumer/EventConsumerWithStrategyTest.java
@@ -0,0 +1,82 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.github.consumer;
+
+import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.TimeUnit;
+
+import org.apache.camel.BindToRegistry;
+import org.apache.camel.RoutesBuilder;
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.github.GitHubComponentTestBase;
+import org.apache.camel.component.github.event.GitHubEventFetchStrategy;
+import org.eclipse.egit.github.core.client.PageIterator;
+import org.eclipse.egit.github.core.event.Event;
+import org.eclipse.egit.github.core.event.IssueCommentPayload;
+import org.eclipse.egit.github.core.event.PushPayload;
+import org.eclipse.egit.github.core.event.WatchPayload;
+import org.eclipse.egit.github.core.service.EventService;
+import org.junit.jupiter.api.Test;
+
+public class EventConsumerWithStrategyTest extends GitHubComponentTestBase {
+
+    private CountDownLatch latch = new CountDownLatch(1);
+
+    @BindToRegistry("strategy")
+    private GitHubEventFetchStrategy strategy = new GitHubEventFetchStrategy() {
+        @Override
+        public PageIterator<Event> fetchEvents(EventService eventService) {
+            latch.countDown();
+            return eventService.pageUserEvents("someguy");
+        }
+    };
+
+    @Test
+    public void customFetchStrategy() throws Exception {
+        Event watchEvent = new Event();
+        watchEvent.setId("1");
+        watchEvent.setPayload(new WatchPayload());
+        eventService.addEvent(watchEvent);
+
+        Event pushEvent = new Event();
+        pushEvent.setId("2");
+        pushEvent.setPayload(new PushPayload());
+        eventService.addEvent(pushEvent);
+
+        Event issueCommentEvent = new Event();
+        issueCommentEvent.setId("3");
+        issueCommentEvent.setPayload(new IssueCommentPayload());
+        eventService.addEvent(issueCommentEvent);
+
+        mockResultEndpoint.expectedBodiesReceivedInAnyOrder(watchEvent, pushEvent, issueCommentEvent);
+
+        latch.await(5, TimeUnit.SECONDS);
+
+        mockResultEndpoint.assertIsSatisfied(5000);
+    }
+
+    @Override
+    protected RoutesBuilder createRouteBuilder() throws Exception {
+        return new RouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                from("github:event?username=someguy&password=apassword&repoOwner=anotherguy&repoName=somerepo&eventFetchStrategy=#strategy")
+                        .to(mockResultEndpoint);
+            }
+        };
+    }
+}
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockEventService.java b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockEventService.java
new file mode 100644
index 0000000..c09044c
--- /dev/null
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockEventService.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.github.services;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.egit.github.core.IRepositoryIdProvider;
+import org.eclipse.egit.github.core.client.GitHubClient;
+import org.eclipse.egit.github.core.client.PageIterator;
+import org.eclipse.egit.github.core.client.PagedRequest;
+import org.eclipse.egit.github.core.event.Event;
+import org.eclipse.egit.github.core.service.EventService;
+
+public class MockEventService extends EventService {
+
+    private List<Event> events = new ArrayList<>();
+
+    @Override
+    public PageIterator<Event> pageEvents(IRepositoryIdProvider repository) {
+        return new MockPageIterator(new PagedRequest(), null);
+    }
+
+    @Override
+    public PageIterator<Event> pageUserEvents(String user) {
+        return new MockPageIterator(new PagedRequest(), null);
+    }
+
+    public void addEvent(Event event) {
+        events.add(event);
+    }
+
+    private final class MockPageIterator extends PageIterator {
+        private boolean hasNext = true;
+
+        public MockPageIterator(PagedRequest request, GitHubClient client) {
+            super(request, client);
+        }
+
+        @Override
+        public boolean hasNext() {
+            try {
+                return hasNext;
+            } finally {
+                hasNext = false;
+            }
+        }
+
+        @Override
+        public Collection next() {
+            return events;
+        }
+    }
+}
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java
index 8f9cc76..04ece02 100644
--- a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java
@@ -23,6 +23,7 @@ import java.util.List;
 import org.eclipse.egit.github.core.IRepositoryIdProvider;
 import org.eclipse.egit.github.core.Repository;
 import org.eclipse.egit.github.core.RepositoryTag;
+import org.eclipse.egit.github.core.User;
 import org.eclipse.egit.github.core.service.RepositoryService;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -43,6 +44,10 @@ public class MockRepositoryService extends RepositoryService {
     @Override
     public Repository getRepository(final String owner, final String name) throws IOException {
         Repository repository = new Repository();
+        User user = new User();
+        user.setName(owner);
+        user.setLogin(owner);
+        repository.setOwner(user);
         repository.setName(name);
         return repository;
     }
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
index d802773..be79eb2 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
@@ -5875,9 +5875,9 @@ public class StaticEndpointBuilders {
      * 
      * Path parameter: type (required)
      * What git operation to execute
-     * There are 9 enums and the value can be one of: CLOSEPULLREQUEST,
+     * There are 10 enums and the value can be one of: CLOSEPULLREQUEST,
      * PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE,
-     * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE
+     * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE, EVENT
      * 
      * Path parameter: branchName
      * Name of branch
@@ -5900,9 +5900,9 @@ public class StaticEndpointBuilders {
      * 
      * Path parameter: type (required)
      * What git operation to execute
-     * There are 9 enums and the value can be one of: CLOSEPULLREQUEST,
+     * There are 10 enums and the value can be one of: CLOSEPULLREQUEST,
      * PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE,
-     * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE
+     * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE, EVENT
      * 
      * Path parameter: branchName
      * Name of branch
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GitHubEndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GitHubEndpointBuilderFactory.java
index 6a77aea..1d85f2f 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GitHubEndpointBuilderFactory.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GitHubEndpointBuilderFactory.java
@@ -566,6 +566,34 @@ public interface GitHubEndpointBuilderFactory {
             return (GitHubEndpointConsumerBuilder) this;
         }
         /**
+         * To specify a custom strategy that configures how the EventsConsumer
+         * fetches events.
+         * 
+         * The option is a:
+         * <code>org.apache.camel.component.github.event.GitHubEventFetchStrategy</code> type.
+         * 
+         * Group: consumer (advanced)
+         */
+        default AdvancedGitHubEndpointConsumerBuilder eventFetchStrategy(
+                Object eventFetchStrategy) {
+            doSetProperty("eventFetchStrategy", eventFetchStrategy);
+            return this;
+        }
+        /**
+         * To specify a custom strategy that configures how the EventsConsumer
+         * fetches events.
+         * 
+         * The option will be converted to a
+         * <code>org.apache.camel.component.github.event.GitHubEventFetchStrategy</code> type.
+         * 
+         * Group: consumer (advanced)
+         */
+        default AdvancedGitHubEndpointConsumerBuilder eventFetchStrategy(
+                String eventFetchStrategy) {
+            doSetProperty("eventFetchStrategy", eventFetchStrategy);
+            return this;
+        }
+        /**
          * To let the consumer use a custom ExceptionHandler. Notice if the
          * option bridgeErrorHandler is enabled then this option is not in use.
          * By default the consumer will deal with exceptions, that will be
@@ -1070,9 +1098,9 @@ public interface GitHubEndpointBuilderFactory {
          * 
          * Path parameter: type (required)
          * What git operation to execute
-         * There are 9 enums and the value can be one of: CLOSEPULLREQUEST,
+         * There are 10 enums and the value can be one of: CLOSEPULLREQUEST,
          * PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE,
-         * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE
+         * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE, EVENT
          * 
          * Path parameter: branchName
          * Name of branch
@@ -1094,9 +1122,9 @@ public interface GitHubEndpointBuilderFactory {
          * 
          * Path parameter: type (required)
          * What git operation to execute
-         * There are 9 enums and the value can be one of: CLOSEPULLREQUEST,
+         * There are 10 enums and the value can be one of: CLOSEPULLREQUEST,
          * PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE,
-         * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE
+         * PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE, EVENT
          * 
          * Path parameter: branchName
          * Name of branch
diff --git a/docs/components/modules/ROOT/pages/github-component.adoc b/docs/components/modules/ROOT/pages/github-component.adoc
index 38f5383..f6bec6f 100644
--- a/docs/components/modules/ROOT/pages/github-component.adoc
+++ b/docs/components/modules/ROOT/pages/github-component.adoc
@@ -87,12 +87,12 @@ with the following path and query parameters:
 [width="100%",cols="2,5,^1,2",options="header"]
 |===
 | Name | Description | Default | Type
-| *type* | *Required* What git operation to execute. There are 9 enums and the value can be one of: CLOSEPULLREQUEST, PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE, PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE |  | GitHubType
+| *type* | *Required* What git operation to execute. There are 10 enums and the value can be one of: CLOSEPULLREQUEST, PULLREQUESTCOMMENT, COMMIT, PULLREQUEST, TAG, PULLREQUESTSTATE, PULLREQUESTFILES, GETCOMMITFILE, CREATEISSUE, EVENT |  | GitHubType
 | *branchName* | Name of branch |  | String
 |===
 
 
-=== Query Parameters (30 parameters):
+=== Query Parameters (31 parameters):
 
 
 [width="100%",cols="2,5,^1,2",options="header"]
@@ -105,6 +105,7 @@ with the following path and query parameters:
 | *username* (common) | GitHub username, required unless oauthToken is provided |  | String
 | *bridgeErrorHandler* (consumer) | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | boolean
 | *sendEmptyMessageWhenIdle* (consumer) | If the polling consumer did not poll any files, you can enable this option to send an empty message (no body) instead. | false | boolean
+| *eventFetchStrategy* (consumer) | To specify a custom strategy that configures how the EventsConsumer fetches events. |  | GitHubEventFetchStrategy
 | *exceptionHandler* (consumer) | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. |  | ExceptionHandler
 | *exchangePattern* (consumer) | Sets the exchange pattern when the consumer creates an exchange. There are 3 enums and the value can be one of: InOnly, InOut, InOptionalOut |  | ExchangePattern
 | *pollStrategy* (consumer) | 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. |  | PollingConsumerPollStrategy