-
Notifications
You must be signed in to change notification settings - Fork 70
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added Google Sheets Stream Source Kamelet
- Loading branch information
1 parent
f6e1364
commit 524e51a
Showing
4 changed files
with
77 additions
and
1 deletion.
There are no files selected for viewing
1 change: 1 addition & 0 deletions
1
docs/modules/ROOT/assets/images/kamelets/google-sheets-stream-source.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
// THIS FILE IS AUTOMATICALLY GENERATED: DO NOT EDIT | ||
= image:kamelets/google-sheets-stream-source.svg[] Google Sheets Stream Source | ||
|
||
*Provided by: "Apache Software Foundation"* | ||
|
||
Receive data from Google Sheets. | ||
|
||
== Configuration Options | ||
|
||
The following table summarizes the configuration options available for the `google-sheets-stream-source` Kamelet: | ||
[width="100%",cols="2,^2,3,^2,^2,^3",options="header"] | ||
|=== | ||
| Property| Name| Description| Type| Default| Example | ||
| *accessToken {empty}* *| Access Token| OAuth 2 access token for google sheets application. This typically expires after an hour so refreshToken is recommended for long term usage.| string| | | ||
| *applicationName {empty}* *| Application name| Google Sheets application name| string| | | ||
| *clientId {empty}* *| Client Id| Client ID of the sheets application| string| | | ||
| *clientSecret {empty}* *| Client Secret| Client Secret of the sheets application| string| | | ||
| *index {empty}* *| Index| An index for the google sheets endpoint| string| | | ||
| *refreshToken {empty}* *| Refresh Token| OAuth 2 refresh token for google sheets application. Using this, the Google Calendar component can obtain a new accessToken whenever the current one expires - a necessity if the application is long-lived.| string| | | ||
| *spreadsheetId {empty}* *| Spreadsheet ID| The Spreadsheet ID to be used as events source| string| | | ||
| range| Consume from now| the range of rows and columns in a sheet to get data from.| boolean| | `"A1:B3"` | ||
| splitResults| Split Results| True if value range result should be split into rows or columns to process each of them individually.| boolean| `true`| | ||
|=== | ||
|
||
NOTE: Fields marked with ({empty}*) are mandatory. | ||
|
||
== Usage | ||
|
||
This section summarizes how the `google-sheets-stream-source` can be used in various contexts. | ||
|
||
=== Knative Source | ||
|
||
The `google-sheets-stream-source` Kamelet can be used as Knative source by binding it to a Knative object. | ||
|
||
.google-sheets-stream-source-binding.yaml | ||
[source,yaml] | ||
---- | ||
apiVersion: camel.apache.org/v1alpha1 | ||
kind: KameletBinding | ||
metadata: | ||
name: google-sheets-stream-source-binding | ||
spec: | ||
source: | ||
ref: | ||
kind: Kamelet | ||
apiVersion: camel.apache.org/v1alpha1 | ||
name: google-sheets-stream-source | ||
properties: | ||
accessToken: "The Access Token" | ||
applicationName: "The Application name" | ||
clientId: "The Client Id" | ||
clientSecret: "The Client Secret" | ||
index: "The Index" | ||
refreshToken: "The Refresh Token" | ||
spreadsheetId: "The Spreadsheet ID" | ||
sink: | ||
ref: | ||
kind: InMemoryChannel | ||
apiVersion: messaging.knative.dev/v1 | ||
name: mychannel | ||
---- | ||
|
||
Make sure you have xref:latest@camel-k::installation/installation.adoc[Camel K installed] into the Kubernetes cluster you're connected to. | ||
|
||
Save the `google-sheets-stream-source-binding.yaml` file into your hard drive, then configure it according to your needs. | ||
|
||
You can run the source using the following command: | ||
|
||
[source,shell] | ||
---- | ||
kubectl apply -f google-sheets-stream-source-binding.yaml | ||
---- | ||
// THIS FILE IS AUTOMATICALLY GENERATED: DO NOT EDIT |