Camel
  1. Camel
  2. CAMEL-5197

Allow the definition of a FileComponent with a FileConfiguration (same as for JMS)

    Details

    • Type: New Feature New Feature
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Won't Fix
    • Affects Version/s: None
    • Fix Version/s: Future
    • Component/s: camel-core
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      We should be able to configure something like this:

      <bean id="file" class="org.apache.camel.component.file.FileComponent">
      <property name="configuration">
      <bean class="org.apache.camel.component.file.FileConfiguration">
      <property name="autoCreate" value="true" />
      <property name="premove" value="work"/>
      <property name="move" value="done"/>
      </bean>
      </property>
      </bean>

      To ensure a common behaviour and directory structure for file processing and make the endpoint declaration lighter
      (without all the options).

        Issue Links

          Activity

          Manuel EVENO created issue -
          Manuel EVENO made changes -
          Field Original Value New Value
          Description We should be able to configure something like this:

              <!-- ActiveMQ Configuration for XA without JCA -->
              <bean id="file" class="org.apache.camel.component.file.FileComponent">
                  <property name="configuration">
                      <bean class="org.apache.camel.component.file.FileConfiguration">
                          <property name="autoCreate" value="true" />
                          <property name="premove" value="work"/>
                          <property name="move" value="done"/>
                      </bean>
                  </property>
              </bean>

          To ensure a common behaviour and directory structure for file processing and make the endpoint declaration lighter
          (without all the options).
          We should be able to configure something like this:

              <bean id="file" class="org.apache.camel.component.file.FileComponent">
                  <property name="configuration">
                      <bean class="org.apache.camel.component.file.FileConfiguration">
                          <property name="autoCreate" value="true" />
                          <property name="premove" value="work"/>
                          <property name="move" value="done"/>
                      </bean>
                  </property>
              </bean>

          To ensure a common behaviour and directory structure for file processing and make the endpoint declaration lighter
          (without all the options).
          Hide
          Claus Ibsen added a comment -

          Its not often used by ppl to specify a <bean> for endpoints.
          But since file endpoint has many options now, we could consider this as well.

          And for uri you can refer to a file configuration bean, "file:foo?fileConfiguration=#myFileConfig" to reuse shared options.

          Show
          Claus Ibsen added a comment - Its not often used by ppl to specify a <bean> for endpoints. But since file endpoint has many options now, we could consider this as well. And for uri you can refer to a file configuration bean, "file:foo?fileConfiguration=#myFileConfig" to reuse shared options.
          Claus Ibsen made changes -
          Issue Type Improvement [ 4 ] New Feature [ 2 ]
          Fix Version/s Future [ 12315692 ]
          Affects Version/s Future [ 12315692 ]
          Priority Major [ 3 ] Minor [ 4 ]
          Claus Ibsen made changes -
          Link This issue is related to CAMEL-7419 [ CAMEL-7419 ]
          Hide
          Manuel EVENO added a comment -

          The FileConfiguration references is doing the job actually.
          There is no more need to define the FileComponent in my opinion.

          Show
          Manuel EVENO added a comment - The FileConfiguration references is doing the job actually. There is no more need to define the FileComponent in my opinion.
          Hide
          Claus Ibsen added a comment - - edited

          Yeah we should look at allowing to define an <endpoint> as abstract then you can use that as a baseline. And it would work on any endpoint, not only the ones that may have a configuration class.

          Show
          Claus Ibsen added a comment - - edited Yeah we should look at allowing to define an <endpoint> as abstract then you can use that as a baseline. And it would work on any endpoint, not only the ones that may have a configuration class.
          Claus Ibsen made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Assignee Claus Ibsen [ davsclaus ]
          Resolution Won't Fix [ 2 ]
          Transition Time In Source Status Execution Times Last Executer Last Execution Date
          Open Open Resolved Resolved
          1030d 4h 58m 1 Claus Ibsen 14/Feb/15 13:37

            People

            • Assignee:
              Claus Ibsen
              Reporter:
              Manuel EVENO
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development