The updateParser() GraphQL mutation is used to update a parser in LogScale. This is deprecated and will be removed in version 1.142. Use instead updateParserV2().

For more information on parsers, see the Parsing Data documentation page.

Syntax

Below is the syntax for the updateParser() mutation field:

graphql
updateParser(
     input: UpdateParserInput!
   ): UpdateParserMutation!

Given Datatypes

For the given datatype, UpdateParserInput, there are several parameters that may be given. Below is a list of them along with their datatypes and a description of each:

Table: UpdateParserInput

ParameterTypeRequiredDefaultDescription
Some arguments may be required, as indicated in the Required column. For some fields, this column indicates that a result will always be returned for this column.
Table last updated: Sep 23, 2024
fieldsToBeRemovedBeforeParsing[string]yes A list of fields that will be removed from the event before it's parsed. They won't be included when calculating usage.
idstring  The unique identifier of the parser to update.
languageVersionLanguageVersionEnum  The version of the LogScale query language to use. See LanguageVersionEnum.
namestring  The name to use for the parser.
repositoryNamestring  The repository where the parser is located.
sourceCodestring  The parser script that is executed for every incoming event.
tagFields[string]yes Any fields which the parser should convert to tags after an event is parsed.
testData[string]yes Test events that can be parsed by the parser.

Returned Datatypes

The returned datatype UpdateParserMutation has its own parameters. Below is a list of them along with their datatypes and a description of each:

Table: UpdateParserMutation

ParameterTypeRequiredDefaultDescription
Some arguments may be required, as indicated in the Required column. For some fields, this column indicates that a result will always be returned for this column.
Table last updated: Oct 4, 2024
parserParseryes The parser to update See Parser.