Skip to content

Commit

Permalink
TypeScript fixes (#2242)
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshMock authored Aug 17, 2023
1 parent d10933d commit 3ff7b3a
Show file tree
Hide file tree
Showing 22 changed files with 26 additions and 24 deletions.
1 change: 1 addition & 0 deletions .github/validate-pr/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ async function run () {
if (file.startsWith('specification/_spec_utils')) continue
if (file.startsWith('specification/_doc_ids')) continue
if (file.startsWith('specification/_json_spec')) continue
if (file === 'specification/tsconfig.json') continue
if (getApi(file).endsWith('_types')) {
const apis = specification.endpoints
.filter(endpoint => endpoint.name.split('.').filter(s => !privateNames.includes(s))[0] === getApi(file).split('.')[0])
Expand Down
4 changes: 2 additions & 2 deletions specification/_types/query_dsl/fulltext.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ import { double, float, integer } from '@_types/Numeric'
import { Script } from '@_types/Scripting'
import { QueryBase } from './abstractions'
import { Operator } from './Operator'
import { DateMath, TimeZone } from '@_types/Time'
import { FlagsEnum, PipeSeparatedFlags } from '@spec_utils/PipeSeparatedFlags'
import { TimeZone } from '@_types/Time'
import { PipeSeparatedFlags } from '@spec_utils/PipeSeparatedFlags'

/**
* @shortcut_property query
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Id } from '@_types/common'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The unique identifier of the query ruleset to delete
Expand Down
2 changes: 1 addition & 1 deletion specification/query_ruleset/get/QueryRulesetGetRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Id } from '@_types/common'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The unique identifier of the query ruleset
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { integer } from '@_types/Numeric'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
query_parameters: {
/**
* Starting offset (default: 0)
Expand Down
2 changes: 1 addition & 1 deletion specification/query_ruleset/put/QueryRulesetPutRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import { QueryRuleset } from '../_types/QueryRuleset'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The unique identifier of the query ruleset to be created or updated
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Name } from '@_types/common'
* @availability stack since=8.8.0 stability=beta
* @availability serverless stability=beta visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The name of the search application to delete
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Name } from '@_types/common'
* @availability stack since=8.8.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The name of the analytics collection to be deleted
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Name } from '@_types/common'
* @availability stack since=8.8.0 stability=beta
* @availability serverless stability=beta visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The name of the search application
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Name } from '@_types/common'
* @availability stack since=8.8.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* A list of analytics collections to limit the returned information
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
* under the License.
*/
import { RequestBase } from '@_types/Base'
import { Name } from '@_types/common'
import { integer } from '@_types/Numeric'

/**
Expand All @@ -26,7 +25,7 @@ import { integer } from '@_types/Numeric'
* @availability stack since=8.8.0 stability=beta
* @availability serverless stability=beta visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
query_parameters: {
/**
* Query in the Lucene query string syntax"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import { SearchApplication } from '../_types/SearchApplication'
* @availability stack since=8.8.0 stability=beta
* @availability serverless stability=beta visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The name of the search application to be created or updated
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,14 @@
*/
import { RequestBase } from '@_types/Base'
import { Name } from '@_types/common'
import { SearchApplication } from '../_types/SearchApplication'

/**
* Creates a behavioral analytics collection
* @rest_spec_name search_application.put_behavioral_analytics
* @availability stack since=8.8.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The name of the analytics collection to be created or updated
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import { UserDefinedValue } from '@spec_utils/UserDefinedValue'
* @availability stack since=8.8.0 stability=beta
* @availability serverless stability=beta visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The name of the search application to be searched
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Id } from '@_types/common'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The id of the synonyms set to be deleted
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Id } from '@_types/common'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The id of the synonym set to be updated
Expand Down
2 changes: 1 addition & 1 deletion specification/synonyms/get_synonym/SynonymsGetRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import { integer } from '@_types/Numeric'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* "The id of the synonyms set to be retrieved
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { Id } from '@_types/common'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The id of the synonym set to retrieve the synonym rule from
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
* under the License.
*/
import { RequestBase } from '@_types/Base'
import { Name } from '@_types/common'
import { integer } from '@_types/Numeric'

/**
Expand All @@ -26,7 +25,7 @@ import { integer } from '@_types/Numeric'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
query_parameters: {
/**
* Starting offset
Expand Down
2 changes: 1 addition & 1 deletion specification/synonyms/put_synonym/SynonymsPutRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import { SynonymRule } from '../_types/SynonymRule'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The id of the synonyms set to be created or updated
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import { SynonymString } from '../_types/SynonymRule'
* @availability stack since=8.10.0 stability=experimental
* @availability serverless stability=experimental visibility=public
*/
interface Request extends RequestBase {
export interface Request extends RequestBase {
path_parts: {
/**
* The id of the synonym set to be updated with the synonym rule
Expand Down
4 changes: 4 additions & 0 deletions specification/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
"@enrich/*": ["enrich/*"],
"@eql/*": ["eql/*"],
"@features/*": ["features/*"],
"@fleet/*": ["fleet/*"],
"@graph/*": ["graph/*"],
"@ilm/*": ["ilm/*"],
"@indices/*": ["indices/*"],
Expand All @@ -39,14 +40,17 @@
"@ml/*": ["ml/*"],
"@monitoring/*": ["monitoring/*"],
"@nodes/*": ["nodes/*"],
"@query_ruleset/*": ["query_ruleset/*"],
"@rollup/*": ["rollup/*"],
"@searchable_snapshots/*": ["searchable_snapshots/*"],
"@search_application/*": ["search_application/*"],
"@security/*": ["security/*"],
"@shutdown/*": ["shutdown/*"],
"@slm/*": ["slm/*"],
"@snapshot/*": ["snapshot/*"],
"@sql/*": ["sql/*"],
"@ssl/*": ["ssl/*"],
"@synonyms/*": ["synonyms/*"],
"@tasks/*": ["tasks/*"],
"@text_structure/*": ["text_structure/*"],
"@transform/*": ["transform/*"],
Expand Down

0 comments on commit 3ff7b3a

Please sign in to comment.