Camel Spring Boot Starter for google-mail

Spring Boot Auto-Configuration

When using google-mail with Spring Boot make sure to use the following Maven dependency to have support for auto configuration:

<dependency>
  <groupId>org.apache.camel.springboot</groupId>
  <artifactId>camel-google-mail-starter</artifactId>
  <version>x.x.x</version>
  <!-- use the same version as your Camel core version -->
</dependency>

The component supports 25 options, which are listed below.

Name Description Default Type

camel.component.google-mail-stream.access-token

OAuth 2 access token. This typically expires after an hour so refreshToken is recommended for long term usage.

String

camel.component.google-mail-stream.application-name

Google mail application name. Example would be camel-google-mail/1.0

String

camel.component.google-mail-stream.basic-property-binding

Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities

false

Boolean

camel.component.google-mail-stream.bridge-error-handler

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

camel.component.google-mail-stream.client-factory

The client Factory. The option is a org.apache.camel.component.google.mail.GoogleMailClientFactory type.

String

camel.component.google-mail-stream.client-id

Client ID of the mail application

String

camel.component.google-mail-stream.client-secret

Client secret of the mail application

String

camel.component.google-mail-stream.configuration

The configuration. The option is a org.apache.camel.component.google.mail.stream.GoogleMailStreamConfiguration type.

String

camel.component.google-mail-stream.enabled

Whether to enable auto configuration of the google-mail-stream component. This is enabled by default.

Boolean

camel.component.google-mail-stream.labels

Comma separated list of labels to take into account

String

camel.component.google-mail-stream.mark-as-read

Mark the message as read once it has been consumed

false

Boolean

camel.component.google-mail-stream.max-results

Max results to be returned

10

Long

camel.component.google-mail-stream.query

The query to execute on gmail box

is:unread

String

camel.component.google-mail-stream.refresh-token

OAuth 2 refresh token. 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

camel.component.google-mail.access-token

OAuth 2 access token. This typically expires after an hour so refreshToken is recommended for long term usage.

String

camel.component.google-mail.application-name

Google mail application name. Example would be camel-google-mail/1.0

String

camel.component.google-mail.basic-property-binding

Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities

false

Boolean

camel.component.google-mail.bridge-error-handler

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

camel.component.google-mail.client-factory

To use the GoogleCalendarClientFactory as factory for creating the client. Will by default use BatchGoogleMailClientFactory. The option is a org.apache.camel.component.google.mail.GoogleMailClientFactory type.

String

camel.component.google-mail.client-id

Client ID of the mail application

String

camel.component.google-mail.client-secret

Client secret of the mail application

String

camel.component.google-mail.configuration

To use the shared configuration. The option is a org.apache.camel.component.google.mail.GoogleMailConfiguration type.

String

camel.component.google-mail.enabled

Whether to enable auto configuration of the google-mail component. This is enabled by default.

Boolean

camel.component.google-mail.lazy-start-producer

Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel’s routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing.

false

Boolean

camel.component.google-mail.refresh-token

OAuth 2 refresh token. 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