/** * Copyright 2022 Splunk, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"): you may * not use this file except in compliance with the License. You may obtain * a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations * under the License. * * Splunk Search service * Use the Search service in Splunk Cloud Services to dispatch, review, and manage searches and search jobs. You can finalize or cancel jobs, retrieve search results, and request search-related configurations from the Metadata Catalog service in Splunk Cloud Services. * * OpenAPI spec version: v3alpha1 * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { Message, QueryParameters, SearchStatus } from './'; /** * A fully-constructed search job, including read-only fields. * @export * @interface SearchJob */ export interface SearchJob { /** * The SPL search string. * @type {string} * @memberof SearchJob */ query: string; /** * Specifies whether a search that contains commands with side effects (with possible security risks) is allowed to run. * @type {boolean} * @memberof SearchJob */ allowSideEffects?: boolean; /** * Specifies whether a search is allowed to collect events summary information during the run time. * @type {boolean} * @memberof SearchJob */ collectEventSummary?: boolean; /** * Specifies whether a search is allowed to collect fields summary information during the run time. * @type {boolean} * @memberof SearchJob */ collectFieldSummary?: boolean; /** * Specifies whether a search is allowed to collect timeline buckets summary information during the run time. * @type {boolean} * @memberof SearchJob */ collectTimeBuckets?: boolean; /** * The time, in GMT, that the search job is finished. Empty if the search job has not completed. * @type {string} * @memberof SearchJob */ readonly completionTime?: string; /** * The time, in GMT, that the search job is dispatched. * @type {string} * @memberof SearchJob */ readonly dispatchTime?: string; /** * Specifies whether a search is allowed to collect preview results during the run time. * @type {boolean} * @memberof SearchJob */ enablePreview?: boolean; /** * Specifies whether the Search service should extract all of the available fields in the data, including fields not mentioned in the SPL for the search job. Set to 'false' for better search performance. The 'extractAllFields' parameter is deprecated as of version v3alpha1. Although this parameter continues to function, it might be removed in a future version. Use the 'extractFields' parameter instead. * @type {boolean} * @memberof SearchJob */ extractAllFields?: boolean; /** * Specifies how the Search service should extract fields. Valid values include 'all', 'none', or 'indexed'. 'all' will extract all fields, 'indexed' will extract only indexed fields, and 'none' will extract only the default fields. This parameter overwrites the value of the 'extractAllFields' parameter. Set to 'none' for better search performance. * @type {string} * @memberof SearchJob */ extractFields?: string; /** * The number of seconds to run the search before finalizing the search. The default value is 3600 seconds (1 hour). The maximum value is 3600 seconds (1 hour). * @type {number} * @memberof SearchJob */ maxTime?: number; /** * * @type {Array} * @memberof SearchJob */ messages?: Array; /** * The module to run the search in. The default module is used if a module is not specified. * @type {string} * @memberof SearchJob */ module?: string; /** * The name of the created search job. * @type {string} * @memberof SearchJob */ readonly name?: string; /** * The 'rsid' of an associated recurring-search, if this search job is dispatched by a recurring-search. * @type {string} * @memberof SearchJob */ readonly parent?: string; /** * An estimate of the percent of time remaining before the job completes. * @type {number} * @memberof SearchJob */ readonly percentComplete?: number; /** * Specifies if preview results are available for the search job. The valid status values are 'unknown', 'true', and 'false'. * @type {string} * @memberof SearchJob */ readonly previewAvailable?: string; /** * Represents parameters on the search job such as 'earliest' and 'latest'. * @type {QueryParameters} * @memberof SearchJob */ queryParameters?: QueryParameters; /** * Specifies a maximum time interval, in seconds, between identical existing searches. The 'requiredFreshness' parameter is used to determine if an existing search with the same query and the same time boundaries can be reused, instead of running the same search again. Freshness is applied to the resolvedEarliest and resolvedLatest parameters. If an existing search has the same exact criteria as this search and the resolvedEarliest and resolvedLatest values are within the freshness interval, the existing search metadata is returned instead of initiating a new search job. By default, the requiredFreshness parameter is set to 0 which means that the platform does not attempt to use an existing search. * @type {number} * @memberof SearchJob */ requiredFreshness?: number; /** * The earliest time speciifed as an absolute value in GMT. The time is computed based on the values you specify for the 'timezone' and 'earliest' queryParameters. * @type {string} * @memberof SearchJob */ readonly resolvedEarliest?: string; /** * The latest time specified as an absolute value in GMT. The time is computed based on the values you specify for the 'timezone' and 'earliest' queryParameters. * @type {string} * @memberof SearchJob */ readonly resolvedLatest?: string; /** * The number of results produced so far for the search job. * @type {number} * @memberof SearchJob */ readonly resultsAvailable?: number; /** * The number of the preview search results for the job with the specified search ID (sid). * @type {number} * @memberof SearchJob */ readonly resultsPreviewAvailable?: number; /** * The ID assigned to the search job. * @type {string} * @memberof SearchJob */ readonly sid?: string; /** * * @type {SearchStatus} * @memberof SearchJob */ status?: SearchStatus; }