Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Arbitrary key/value pairs #6

Open
RamblingCookieMonster opened this issue Feb 12, 2016 · 1 comment
Open

Arbitrary key/value pairs #6

RamblingCookieMonster opened this issue Feb 12, 2016 · 1 comment
Assignees

Comments

@RamblingCookieMonster
Copy link

Hi!

It might be helpful to offer the option to define arbitrary key/value pairs for each block.

For example, you might have this definition:

nxlog::config::input { 'eventlog_json':
  input_execs  => [
    'delete($Keywords)',
    '$raw_event = to_json()',
  ],
  input_module => 'im_msvistalog',
  arbitrary    => {
    'Query' => "<QueryList> \
        <Query Id='0'> \
          <Select Path='Security'>*</Select> \
        </Query> \
      </QueryList>",
  },
}

Which would translate to something along the lines of:

<Input eventlog_json>
    Module  im_msvistalog
    Query   <QueryList> \
              <Query Id="0"> \
                <Select Path="Security">*</Select> \
              </Query> \
            </QueryList>
    Exec    'delete($Keywords)'; '$raw_event = to_json()';
</Input>

With the idea that you wouldn't need to map out every possible key that folks might want to specify in the nxlog conf., you could leave corner cases to some arbitrary hash table that you parse.

Cheers!

@genebean
Copy link
Owner

I'll certainly look into this, I think its a good idea.

@genebean genebean self-assigned this Aug 24, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants