Uploaded image for project: 'Flume'
  1. Flume
  2. FLUME-2884

Tag not allowed in ElasticSearch indexNameBuilder properties

    Details

    • Type: Bug
    • Status: Patch Available
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Sinks+Sources
    • Labels:
      None

      Description

      Note: The patch FLUME - 2207 is required to reproduce the issue.

      The following code causes the flume agent to crash a stack trace when starting (illegal pattern passed to FastDateFormat) :

      agent1.sinks.sinkEls.indexNameBuilder.dateFormat = %{format}
      

      In practice, we need a variable to customize the index rotation (daily, weekly, monthly) from a header. (the header is defined in a morphline in our case, configured as an interceptor on the source)

      The problem happens because the FastDateFormat is instanciated in the method configure. We could delay its instanciation inside the method getIndexName without decrease the performance of the agent (FastDateFormat uses caching extensively). I added a patch to present this implementation.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                julien_sobczak Julien Sobczak
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated: