![JAR search and dependency download from the Maven repository](/logo.png)
de.elide-model-config.7.0.0-pr2.source-code.elideTableSchema.json Maven / Gradle / Ivy
{
"$schema": "https://json-schema.org/draft-04/schema#",
"definitions": {
"argument" : {
"title" : "Arguments",
"description" : "Arguments are supported for table, measures and dimensions.",
"type" : "object",
"properties": {
"name": {
"title": "Argument name",
"description": "Name must start with an alphabetic character and can include alaphabets, numbers and '_' only.",
"type": "string",
"format": "elideArgumentName"
},
"description": {
"title": "Argument description",
"description": "A long description for this Argument.",
"type": "string"
},
"type": {
"title": "Argument type",
"description": "Must be one of Integer, Decimal, Money, Text, Coordinate, Boolean",
"type": "string",
"format": "elideFieldType"
},
"values": {
"title": "Argument values",
"description": "An array of valid string values for this Argument",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"tableSource": {
"$ref": "#/definitions/tableSource"
},
"default": {
"title": "Default argument value",
"description": "Default value for this argument.",
"type": [
"string",
"number",
"boolean"
]
}
},
"required": [
"name",
"type",
"default"
],
"validateArgumentProperties": true,
"additionalProperties": false
},
"join": {
"title": "Join",
"description": "Joins describe the SQL expression necessary to join two physical tables. Joins can be used when defining dimension columns that reference other tables.",
"type": "object",
"properties": {
"name": {
"title": "Join name",
"description": "The name of the join relationship.",
"type": "string",
"format": "elideFieldName"
},
"namespace": {
"title": "Join Namespace",
"description": "Namespace for the Join.",
"type": "string",
"format": "elideNamespaceName",
"default": "default"
},
"to": {
"title": "Join table name",
"description": "The name of the table that is being joined to",
"type": "string",
"format": "elideName"
},
"type": {
"title": "Type of Join",
"description": "Type of the join - left, inner, full or cross",
"type": "string",
"format": "elideJoinType"
},
"kind": {
"title": "Kind of Join",
"description": "Kind of the join - toOne or toMany",
"type": "string",
"format": "elideJoinKind"
},
"definition": {
"title": "Join definition SQL",
"description": "Templated SQL expression that represents the ON clause of the join",
"type": "string"
}
},
"required": [
"name",
"to"
],
"additionalProperties": false
},
"tableSource": {
"title": "Table Source",
"description": "Provides information about where a column or argument values can be found.",
"type": "object",
"properties": {
"table": {
"title": "Source table",
"description": "The source table that contains the colum or argument values.",
"type": "string",
"format": "elideName"
},
"namespace": {
"title": "Source table namespace",
"description": "Namespace for the source table.",
"type": "string",
"format": "elideNamespaceName",
"default": "default"
},
"column": {
"title": "Primary source table column name",
"description": "The column that provides a unique list of values for the given column or argument",
"type": "string",
"format": "elideFieldName"
},
"suggestionColumns": {
"title": "Secondary search columns",
"description": "Secondary columns that can be searched to locate the primary column(s)",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string",
"format": "elideFieldName"
}
}
},
"required": [
"table",
"column"
],
"additionalProperties": false
},
"measure": {
"title": "Measure",
"description": "Metric definitions are extensible objects that contain a type field and one or more additional attributes. Each type is tied to logic in Elide that generates a metric function.",
"type": "object",
"properties": {
"name": {
"title": "Metric name",
"description": "The name of the metric. This will be the same as the POJO field name.",
"type": "string",
"format": "elideFieldName"
},
"friendlyName": {
"title": "Metric friendly name",
"description": "The friendly name of the metric. This will be displayed in the UI. If not provided, this defaults to the name",
"type": "string"
},
"description": {
"title": "Metric description",
"description": "A long description of the metric.",
"type": "string"
},
"category": {
"title": "Measure group category",
"description": "Category for grouping",
"type": "string"
},
"hidden": {
"title": "Hide/Show measure",
"description": "Whether this metric is exposed via API metadata",
"type": "boolean",
"default": false
},
"readAccess": {
"title": "Measure read access",
"description": "Read permission for the metric.",
"type": "string",
"default": "Prefab.Role.All"
},
"definition": {
"title": "Metric definition",
"description": "The definition of the metric",
"type": "string"
},
"maker": {
"title": "Metric Projection Maker",
"description": "Registers a custom function to create a projection for this metric",
"type": "string",
"format": "javaClassName"
},
"type": {
"title": "Measure field type",
"description": "The data type of the measure field",
"type": "string",
"format": "elideFieldType"
},
"tags": {
"title": "Measure tags",
"description": "An array of string based tags for measures",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"arguments": {
"title": "Measure arguments",
"description": "An array of supported arguments for measure",
"type": "array",
"items": {
"$ref": "#/definitions/argument"
}
},
"filterTemplate": {
"title": "Required RSQL Filter Template",
"description": "Client queries must include a filter conforming to this RSQL template.",
"type": "string",
"format": "elideRSQLFilter"
}
},
"oneOf": [
{
"required": [
"name",
"type",
"definition"
]
},
{
"required": [
"name",
"type",
"maker"
]
}
],
"additionalProperties": false
},
"dimensionRef": {
"title": "Dimension",
"description": "Dimensions represent labels for measures. Dimensions are used to filter and group measures.",
"type": "object",
"properties": {
"name": {
"title": "Dimension name",
"description": "The name of the dimension. This will be the same as the POJO field name.",
"type": "string",
"format": "elideFieldName"
},
"friendlyName": {
"title": "Dimension friendly name",
"description": "The friendly name of the dimension. This will be displayed in the UI. If not provided, this defaults to the name",
"type": "string"
},
"description": {
"title": "Dimension description",
"description": "A long description of the dimension.",
"type": "string"
},
"category": {
"title": "Dimension group category",
"description": "Category for grouping dimension",
"type": "string"
},
"hidden": {
"title": "Hide/Show dimension",
"description": "Whether this dimension is exposed via API metadata",
"type": "boolean",
"default": false
},
"readAccess": {
"title": "Dimension read access",
"description": "Read permission for the dimension.",
"type": "string",
"default": "Prefab.Role.All"
},
"definition": {
"title": "Dimension definition",
"description": "The definition of the dimension",
"type": "string"
},
"cardinality": {
"title": "Dimension cardinality",
"description": "Dimension cardinality: (tiny, small, medium, large, huge). The relative sizes are decided by the table designer(s).",
"type": "string",
"format": "elideCardiality"
},
"tags": {
"title": "Dimension tags",
"description": "An array of string based tags for dimensions",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"arguments": {
"title": "Dimension arguments",
"description": "An array of supported arguments for dimensions",
"type": "array",
"items": {
"$ref": "#/definitions/argument"
}
},
"filterTemplate": {
"title": "Required RSQL Filter Template",
"description": "Client queries must include a filter conforming to this RSQL template.",
"type": "string",
"format": "elideRSQLFilter"
}
}
},
"dimension": {
"title": "Dimension",
"description": "Dimensions represent labels for measures. Dimensions are used to filter and group measures.",
"type": "object",
"allOf": [
{
"$ref": "#/definitions/dimensionRef"
},
{
"properties": {
"type": {
"title": "Dimension field type",
"description": "The data type of the dimension field",
"type": "string",
"format": "elideFieldType"
},
"values": {
"title": "Dimension values",
"description": "An array of valid string values for this dimension",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"tableSource": {
"$ref": "#/definitions/tableSource"
}
}
}
],
"validateDimensionProperties": true,
"required": [
"name",
"type",
"definition"
]
},
"timeDimension": {
"title": "Time Dimension",
"description": "Time Dimensions represent labels for measures. Dimensions are used to filter and group measures.",
"type": "object",
"allOf": [
{
"$ref": "#/definitions/dimensionRef"
},
{
"properties": {
"type": {
"title": "Dimension field type",
"description": "The data type of the dimension field",
"type": "string",
"format": "elideTimeFieldType"
},
"grains" : {
"title" : "Time Dimension grains",
"description" : "Time Dimension granularity and Sqls",
"type" : "array",
"items" : {
"title": "Grains",
"description": "Grains can have SQL expressions that can substitute column with the dimension definition expression",
"type": "object",
"properties": {
"type": {
"title": "Time granularity",
"description": "Indicates grain time granularity",
"type": "string",
"format": "elideGrainType"
},
"sql": {
"title": "Grain SQL",
"description": "Grain SQL query",
"type": "string"
}
},
"additionalProperties": false
},
"default" : []
}
}
}
],
"validateTimeDimensionProperties": true,
"required": [
"name",
"type",
"definition"
]
}
},
"type": "object",
"title": "Elide Table Root Schema",
"description": "Elide Table config json/hjson schema",
"properties": {
"tables": {
"type": "array",
"title": "Elide Model Collection",
"description": "An array of Elide table configs.",
"uniqueItems": true,
"minItems": 1,
"items": {
"type": "object",
"title": "Elide Model",
"description": "Elide Table Config",
"properties": {
"name": {
"title": "Table Model Name",
"description": "The name of the model. This will be the same as the POJO class name.",
"type": "string",
"format": "elideName"
},
"friendlyName": {
"title": "Table friendly name",
"description": "The friendly name of the table. This will be displayed in the UI. If not provided, this defaults to the name",
"type": "string"
},
"filterTemplate": {
"title": "Required RSQL Filter Template",
"description": "Client queries must include a filter conforming to this RSQL template.",
"type": "string",
"format": "elideRSQLFilter"
},
"isFact": {
"title": "Is Fact Table",
"description": "Whether this table is a fact",
"type": "boolean",
"default": true
},
"hidden": {
"title": "Hide/Show Table",
"description": "Whether this table is exposed via API metadata",
"type": "boolean",
"default": false
},
"description": {
"title": "Table Model description",
"description": "A long description of the model.",
"type": "string"
},
"cardinality": {
"title": "Table cardinality",
"description": "Table cardinality: (tiny, small, medium, large, huge). The relative sizes are decided by the table designer(s).",
"type": "string",
"format": "elideCardiality"
},
"readAccess": {
"title": "Table read access",
"description": "Read permission for the table.",
"type": "string",
"default": "Prefab.Role.All"
},
"namespace": {
"title": "Table Namespace",
"description": "Namespace for the table.",
"type": "string",
"format": "elideNamespaceName",
"default": "default"
},
"hints": {
"title": "Optimizer Hints",
"description": "An array of hint names to control the optimizer",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"joins": {
"title": "Table joins",
"description": "Describes SQL joins to other tables for column references.",
"type": "array",
"items": {
"$ref": "#/definitions/join"
}
},
"measures": {
"title": "Table measures",
"description": "Zero or more metric definitions.",
"type": "array",
"items": {
"$ref": "#/definitions/measure"
}
},
"dimensions": {
"title": "Table dimensions",
"description": "One or more dimension definitions.",
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/definitions/dimension"
},
{
"$ref": "#/definitions/timeDimension"
}
]
}
},
"tags": {
"title": "Table tags",
"description": "An array of string based tags",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"arguments": {
"title": "Table arguments",
"description": "An array of supported arguments for tables.",
"type": "array",
"items": {
"$ref": "#/definitions/argument"
}
}
},
"oneOf": [
{
"properties": {
"sql": {
"title": "Table SQL",
"description": "SQL query which is used to populate the table.",
"type": "string"
},
"dbConnectionName": {
"title": "DB Connection Name",
"description": "The database connection name for this model.",
"type": "string",
"format": "elideName"
}
},
"required": [
"name",
"sql",
"dimensions"
]
},
{
"properties": {
"maker": {
"title": "Table SQL maker function",
"description": "JVM function to invoke to generate the SQL query which is used to populate the table.",
"type": "string",
"format": "javaClassName"
},
"dbConnectionName": {
"title": "DB Connection Name",
"description": "The database connection name for this model.",
"type": "string",
"format": "elideName"
}
},
"required": [
"name",
"maker",
"dimensions"
]
},
{
"properties": {
"schema": {
"title": "Table Schema",
"description": "The database or schema where the model lives.",
"type": "string"
},
"table": {
"title": "Table name",
"description": "The physical table name where the model lives.",
"type": "string"
},
"dbConnectionName": {
"title": "DB Connection Name",
"description": "The database connection name for this model.",
"type": "string",
"format": "elideName"
}
},
"required": [
"name",
"table",
"dimensions"
]
},
{
"properties": {
"extend": {
"title": "Table Extends",
"description": "Extends another logical table.",
"type": "string",
"format": "elideName"
}
},
"required": [
"name",
"extend"
]
}
]
}
}
},
"required": [
"tables"
],
"additionalProperties": false
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy