$id: http://substrait.io/schemas/simple_extensions
$schema: https://json-schema.org/draft/2020-12/schema
title: Simple Extensions
additionalProperties: false
type: object
properties:
dependencies:
type: object
patternProperties:
"^[a-zA-Z_\\$][a-zA-Z0-9_\\$]*$":
type: string
types:
type: array
minItems: 1
items:
type: object
additionalProperties: false
required: [name]
properties:
name:
type: string
structure:
$ref: "#/$defs/type"
parameters: $ref: "#/$defs/type_param_defs"
variadic: type: boolean
type_variations:
type: array
minItems: 1
items:
type: object
additionalProperties: false
required: [parent, name]
properties:
parent:
$ref: "#/$defs/type"
name:
type: string
description:
type: string
functions:
type: string
enum: [INHERITS, SEPARATE]
scalar_functions:
type: array
items:
$ref: "#/$defs/scalarFunction"
aggregate_functions:
type: array
items:
$ref: "#/$defs/aggregateFunction"
window_functions:
type: array
items:
$ref: "#/$defs/windowFunction"
$defs:
type:
oneOf:
- type: string - type: object type_param_defs: type: array
items:
type: object
required: [type]
properties:
name: type: string
description: type: string
type: type: string
enum:
- dataType
- boolean
- integer
- enumeration
- string
min: type: number
max: type: number
options: $ref: "#/$defs/enum_options"
optional: type: boolean
enum_options:
type: array
minItems: 1
uniqueItems: true
items:
type: string
enumeration_arg:
type: object
additionalProperties: false
required: [options]
properties:
name:
type: string
description:
type: string
options:
$ref: "#/$defs/enum_options"
value_arg:
type: object
required: [value]
properties:
name:
type: string
description:
type: string
value:
$ref: "#/$defs/type"
constant:
type: boolean
type_arg:
type: object
required: [type]
properties:
name:
type: string
description:
type: string
type:
type: string
arguments: type: array
items:
oneOf:
- $ref: "#/$defs/enumeration_arg"
- $ref: "#/$defs/value_arg"
- $ref: "#/$defs/type_arg"
options: type: object
additionalProperties:
type: object additionalProperties: false
required: [values]
properties:
description:
type: string
values:
type: array
items:
type: string
variadicBehavior:
type: object
additionalProperties: false
properties:
min:
type: number
max:
type: number
parameterConsistency:
type: string
enum: [CONSISTENT, INCONSISTENT]
deterministic:
type: boolean
sessionDependent:
type: boolean
nullabilityHandling:
type: string
enum: [MIRROR, DECLARED_OUTPUT, DISCRETE]
returnValue:
$ref: "#/$defs/type"
implementation:
type: object
additionalProperties:
type: string
intermediate:
$ref: "#/$defs/type"
decomposable:
type: string
enum: [NONE, ONE, MANY]
maxset:
type: number
ordered:
type: boolean
scalarFunction:
type: object
additionalProperties: false
required: [name, impls]
properties:
name:
type: string
description:
type: string
impls:
type: array
minItems: 1
items:
type: object
additionalProperties: false
required: [return]
properties:
args:
$ref: "#/$defs/arguments"
options:
$ref: "#/$defs/options"
variadic:
$ref: "#/$defs/variadicBehavior"
sessionDependent:
$ref: "#/$defs/sessionDependent"
deterministic:
$ref: "#/$defs/deterministic"
nullability:
$ref: "#/$defs/nullabilityHandling"
return:
$ref: "#/$defs/returnValue"
implementation:
$ref: "#/$defs/implementation"
aggregateFunction:
type: object
additionalProperties: false
required: [name, impls]
properties:
name:
type: string
description:
type: string
impls:
type: array
minItems: 1
items:
type: object
additionalProperties: false
required: [return]
properties:
args:
$ref: "#/$defs/arguments"
options:
$ref: "#/$defs/options"
variadic:
$ref: "#/$defs/variadicBehavior"
sessionDependent:
$ref: "#/$defs/sessionDependent"
deterministic:
$ref: "#/$defs/deterministic"
nullability:
$ref: "#/$defs/nullabilityHandling"
return:
$ref: "#/$defs/returnValue"
implementation:
$ref: "#/$defs/implementation"
intermediate:
$ref: "#/$defs/intermediate"
ordered:
$ref: "#/$defs/ordered"
maxset:
$ref: "#/$defs/maxset"
decomposable:
$ref: "#/$defs/decomposable"
windowFunction:
type: object
additionalProperties: false
required: [name, impls]
properties:
name:
type: string
description:
type: string
impls:
type: array
minItems: 1
items:
type: object
additionalProperties: false
required: [return]
properties:
args:
$ref: "#/$defs/arguments"
options:
$ref: "#/$defs/options"
variadic:
$ref: "#/$defs/variadicBehavior"
sessionDependent:
$ref: "#/$defs/sessionDependent"
deterministic:
$ref: "#/$defs/deterministic"
nullability:
$ref: "#/$defs/nullabilityHandling"
return:
$ref: "#/$defs/returnValue"
implementation:
$ref: "#/$defs/implementation"
intermediate:
$ref: "#/$defs/intermediate"
ordered:
$ref: "#/$defs/ordered"
maxset:
$ref: "#/$defs/maxset"
decomposable:
$ref: "#/$defs/decomposable"
window_type:
type: string
enum: [STREAMING, PARTITION]