Class S3Emitter

  • All Implemented Interfaces:
    Initializable, Emitter, StreamEmitter

    public class S3Emitter
    extends AbstractEmitter
    implements Initializable, StreamEmitter
    Emits to existing s3 bucket
      <properties>
          <emitters>
              <emitter class="org.apache.tika.pipes.emitter.s3.S3Emitter>
                  <params>
                      <!-- required -->
                      <param name="name" type="string">s3e</param>
                      <!-- required -->
                      <param name="region" type="string">us-east-1</param>
                      <!-- required -->
                      <param name="credentialsProvider"
                           type="string">(profile|instance)</param>
                      <!-- required if credentialsProvider=profile-->
                      <param name="profile" type="string">my-profile</param>
                      <!-- required -->
                      <param name="bucket" type="string">my-bucket</param>
                      <!-- optional; prefix to add to the path before emitting;
                           default is no prefix -->
                      <param name="prefix" type="string">my-prefix</param>
                      <!-- optional; default is 'json' this will be added to the SOURCE_PATH
                                        if no emitter key is specified. Do not add a "."
                                         before the extension -->
                      <param name="fileExtension" type="string">json</param>
                      <!-- optional; default is 'true'-- whether to copy the
                         json to a local file before putting to s3 -->
                      <param name="spoolToTemp" type="bool">true</param>
                  </params>
              </emitter>
          </emitters>
      </properties>
    • Constructor Detail

      • S3Emitter

        public S3Emitter()
    • Method Detail

      • setSpoolToTemp

        @Field
        public void setSpoolToTemp​(boolean spoolToTemp)
        Whether or not to spool the metadatalist to a tmp file before putting object. Default: true. If this is set to false, this emitter writes the json object to memory and then puts that into s3.
        Parameters:
        spoolToTemp -
      • setRegion

        @Field
        public void setRegion​(String region)
      • setProfile

        @Field
        public void setProfile​(String profile)
      • setBucket

        @Field
        public void setBucket​(String bucket)
      • setPrefix

        @Field
        public void setPrefix​(String prefix)
      • setCredentialsProvider

        @Field
        public void setCredentialsProvider​(String credentialsProvider)
      • setFileExtension

        @Field
        public void setFileExtension​(String fileExtension)
        If you want to customize the output file's file extension. Do not include the "."
        Parameters:
        fileExtension -
      • setAccessKey

        @Field
        public void setAccessKey​(String accessKey)
      • setSecretKey

        @Field
        public void setSecretKey​(String secretKey)
      • setMaxConnections

        @Field
        public void setMaxConnections​(int maxConnections)
        maximum number of http connections allowed. This should be greater than or equal to the number of threads emitting to S3.
        Parameters:
        maxConnections -
      • setEndpointConfigurationService

        @Field
        public void setEndpointConfigurationService​(String endpointConfigurationService)
      • setPathStyleAccessEnabled

        @Field
        public void setPathStyleAccessEnabled​(boolean pathStyleAccessEnabled)