Skip to content

Releases: partiql/partiql-lang-kotlin

v0.10.1-alpha

20 Sep 21:12
0e5332e
Compare
Choose a tag to compare
v0.10.1-alpha Pre-release
Pre-release

Release v0.10.1-alpha

Fixes

  • Fixes build failure for version 0.10.0 by publishing partiql-plan as an independent artifact. Please note that partiql-plan is experimental.

List of commits: v0.10.0-alpha...v0.10.1-alpha

v0.13.0-alpha

08 Sep 22:37
591d7aa
Compare
Choose a tag to compare
v0.13.0-alpha Pre-release
Pre-release

Release v0.13.0-alpha

Added

  • Adds org.partiql.value (experimental) package for reading/writing PartiQL values
  • Adds function overloading to the CompilerPipeline and experimental PartiQLCompilerPipeline.
  • Adds new method getFunctions() to org.partiql.spi.Plugin.
  • Adds PartiQLFunction interface.
  • Adds FunctionSignature and FunctionParameter class to org/partiql/types/function.
  • Adds a new flag --plugins to PartiQL CLI to allow users to specify the root of their plugins directory.
    The default is ~/.partiql/plugins . Each implementer of a plugin should place a directory under the
    plugins root containing the JAR corresponding with their plugin implementation.
    Example: ~/.partiql/plugins/customPlugin/customPlugin.jar
  • Adds serialization and deserialization between IonValue and org.partiql.value.
  • Adds org.partiql.ast package and usage documentation
  • Adds org.partiql.parser package and usage documentation
  • Adds PartiQL's Timestamp Data Model.
  • Adds support for Timestamp constructor call in Parser.
  • Parsing of label patterns within node and edge graph patterns now supports
    disjunction |, conjunction &, negation !, and grouping.
  • Adds default equals and hashCode methods for each generated abstract class of Sprout. This affects the generated
    classes in :partiql-ast and :partiql-plan.
  • Adds README to partiql-types package.
  • Initializes PartiQL's Code Coverage library
    • Adds support for BRANCH and BRANCH-CONDITION Coverage
    • Adds integration with JUnit5 for ease-of-use
    • For more information, see the "Writing PartiQL Unit Tests" article in our GitHub Wiki.
  • Adds new constructor parameters to all variants of PartiQLResult.
  • Adds two new methods to PartiQLResult: getCoverageData and getCoverageStructure.

Changed

  • Breaking: all product types defined by the internal Sprout tool no longer generate interfaces. They are now abstract
    classes due to the generation of equals and hashCode methods. This change impacts many generated interfaces exposed
    in :partiql-ast and :partiql-plan.
  • Standardizes org/partiql/cli/functions/QueryDDB and other built-in functions in org/partiql/lang/eval/builtins by the new ExprFunction format.
  • Breaking: Redefines org/partiql/lang/eval/ExprFunctionkt.call() method by only invoking callWithRequired function.
  • Breaking: Redefines org/partiql/lang/eval/builtins/DynamicLookupExprFunction by merging variadicParameter into requiredParameters as a StaticType.LIST. callWithVariadic is now replaced by callWithRequired.
  • Upgrades ion-java to 1.10.2.
  • Breaking (within experimental graph features): As part of extending
    the language of graph label patterns:
    • Changed the type of the field label in AST nodes
      org.partiql.lang.domains.PartiqlAst.GraphMatchPatternPart.{Node,Edge},
      from SymbolPrimitive to new GraphLabelSpec.
    • Changed the names of subclasses of org.partiql.lang.graph.LabelSpec,
      from OneOf to Name, and from Whatever to Wildcard.
  • Breaking the package org.partiql.lang.errors has been moved to org.partiql.errors, moved classes include
    • org.partiql.lang.errors.ErrorCategory -> org.partiql.errors.ErrorCategory
    • org.partiql.lang.errors.Property -> org.partiql.errors.Property
    • org.partiql.lang.errors.PropertyValue -> org.partiql.errors.PropertyValue
    • org.partiql.lang.errors.PropertyType -> org.partiql.errors.PropertyType
    • org.partiql.lang.errors.PropertyValueMap -> org.partiql.errors.PropertyValueMap
    • org.partiql.lang.errors.ErrorCode -> org.partiql.errors.ErrorCode
    • org.partiql.lang.errors.Problem -> org.partiql.errors.Problem
    • org.partiql.lang.errors.ProblemDetails -> org.partiql.errors.ProblemDetails
    • org.partiql.lang.errors.ProblemSeverity -> org.partiql.errors.ProblemSeverity
    • org.partiql.lang.errors.ProblemHandler -> org.partiql.errors.ProblemHandler
  • Breaking the sourceLocation field of org.partiql.errors.Problem was changed from org.partiql.lang.ast.SoureceLocationMeta to org.partiql.errors.ProblemLocation.
  • Breaking removed redundant ValueParameter from FunctionParameter as all parameters are values.
  • Introduces isNullCall and isNullable properties to FunctionSignature.
  • Removed Nullable...Value implementations of PartiQLValue and made the standard implementations nullable.
  • Using PartiQLValueType requires optin; this was a miss from an earlier commit.
  • Modified timestamp static type to model precision and time zone.

Deprecated

  • Breaking: Deprecates the Arguments, RequiredArgs, RequiredWithOptional, and RequiredWithVariadic classes,
    along with the callWithOptional(), callWithVariadic(), and the overloaded call() methods in the ExprFunction class,
    marking them with a Deprecation Level of ERROR. Now, it's recommended to use
    call(session: EvaluationSession, args: List<ExprValue>) and callWithRequired() instead.
  • Breaking: Deprecates optionalParameter and variadicParameter in the FunctionSignature with a Deprecation
    Level of ERROR. Please use multiple implementations of ExprFunction and use the LIST ExprValue to
    represent variadic parameters instead.

Fixed

Removed

  • Breaking: Removes optionalParameter and variadicParameter from org.partiql.lang.types.FunctionSignature. To continue support for evaluation of optionalParameters, please create another same-named function. To continue support for evaluation of variadicParameter, please use a StaticType.LIST to hold all previously variadic parameters.
    As this changes coincides with the addition of function overloading, only callWithRequired will be invoked upon execution of an ExprFunction. Note: Function overloading is now allowed, which is the reason for the removal of optionalParameter and variadicParameter.
  • Breaking: Removes unused class Arguments from org.partiql.lang.eval.
  • Breaking: Removes unused parameter args: Arguments from org.partiql.lang.eval.ExprFunctionkt.call() method.

Security

Contributors

Thank you to all who have contributed!

Commits: v0.12.0-alpha...v0.13.0-alpha

v0.12.0-alpha

15 Jun 21:39
e256776
Compare
Choose a tag to compare
v0.12.0-alpha Pre-release
Pre-release

Added

  • Adds support for using EXCLUDED within DML ON-CONFLICT-ACTION conditions. Closes #1111.

Changed

  • Updates Kotlin target from 1.4 (DEPRECATED) to 1.6
  • Moves PartiqlAst, PartiqlLogical, PartiqlLogicalResolved, and PartiqlPhysical (along with the transforms)
    to a new project, partiql-ast. These are still imported into partiql-lang with the api annotation. Therefore,
    no action is required to consume the migrated classes. However, this now gives consumers of the AST, Experimental Plans,
    Visitors, and VisitorTransforms the option of importing them directly using: org.partiql:partiql-ast:${VERSION}.
    The file partiql.ion is still published in the partiql-lang-kotlin JAR.
  • Moves internal class org.partiql.lang.syntax.PartiQLParser to org.partiql.lang.syntax.impl.PartiQLPigParser as we refactor for explicit API.
  • Moves ANTLR grammar to partiql-parser package. The files PartiQL.g4 and PartiQLTokens.g4 are still published in the partiql-lang-kotlin JAR.
  • Breaking: Adds new property, rowAlias, to experimental PartiqlLogical.DmlOperation.DmlUpdate,
    PartiqlLogical.DmlOperation.DmlReplace, PartiqlLogicalResolved.DmlOperation.DmlUpdate,
    PartiqlLogicalResolved.DmlOperation.DmlReplace, PartiqlPhysical.DmlOperation.DmlUpdate, and
    PartiqlPhysical.DmlOperation.DmlReplace.

Deprecated

Fixed

Removed

  • Breaking: Removes deprecated org.partiql.annotations.PartiQLExperimental

  • Breaking: Removes deprecated/unused blacklist() and denyList() from org.partiql.lang.eval

  • Breaking: Removes deprecated enum LEGACY in org.partiql.lang.eval.CompileOptions

  • Breaking: Removes deprecated org.partiql.lang.eval.ExprValueFactory, as well as all methods that had its instance
    among arguments. The counterparts of these methods without an ExprValueFactory are still available. The affected methods
    include: ofIonStruct() in org.partiql.lang.eval.Bindings, a constructor of org.partiql.lang.CompilerPipeline,
    convert() in org.partiql.lang.eval.io.DelimitedValues.ConversionMode, exprValue() from
    org.partiql.lang.eval.io.DelimitedValues, a constructor for org.partiql.lang.eval.physical.EvaluatorState, and
    valueFactory, build, builder, standard in org.partiql.lang.CompilerPipeline

  • Breaking: Removes deprecated org.partiql.lang.eval.visitors.GroupKeyReferencesVisitorTransform

  • Breaking: Removes org.partiql.lang.mappers.StaticTypeMapper

  • Breaking: Removes org.partiql.lang.mappers.IonSchemaMapper

  • Breaking: Removes org.partiql.lang.mappers.TypeNotFoundException

  • Breaking: Removes org.partiql.lang.mappers.getBaseTypeName()

  • Breaking: Removes unused/deprecated enums KEYWORD, TOKEN_TYPE, EXPECTED_TOKEN_TYPE, EXPECTED_TOKEN_TYPE_1_OF_2,
    EXPECTED_TOKEN_TYPE_2_OF_2, TIMESTAMP_STRING, NARY_OP from org.partiql.lang.errors.Property

  • Breaking: Removes unused tokenTypeValue() from org.partiql.lang.errors.PropertyValue

  • Breaking: Removes unused TOKEN_CLASS from org.partiql.lang.errors.PropertyType

  • Breaking: Removes unused set(Property, TokenType) from org.partiql.lang.errors.PropertyValueMap

  • Breaking: Removes unused/deprecated enums LEXER_INVALID_NAME, LEXER_INVALID_OPERATOR, LEXER_INVALID_ION_LITERAL,
    PARSE_EXPECTED_KEYWORD, PARSE_EXPECTED_TOKEN_TYPE, PARSE_EXPECTED_2_TOKEN_TYPES, PARSE_EXPECTED_TYPE_NAME,
    PARSE_EXPECTED_WHEN_CLAUSE, PARSE_EXPECTED_WHERE_CLAUSE, PARSE_EXPECTED_CONFLICT_ACTION, PARSE_EXPECTED_RETURNING_CLAUSE,
    PARSE_UNSUPPORTED_RETURNING_CLAUSE_SYNTAX, PARSE_UNSUPPORTED_TOKEN, PARSE_EXPECTED_MEMBER, PARSE_UNSUPPORTED_SELECT,
    PARSE_UNSUPPORTED_CASE, PARSE_UNSUPPORTED_CASE_CLAUSE, PARSE_UNSUPPORTED_ALIAS, PARSE_UNSUPPORTED_SYNTAX,
    PARSE_UNSUPPORTED_SYNTAX, PARSE_INVALID_PATH_COMPONENT, PARSE_MISSING_IDENT_AFTER_AT, PARSE_UNEXPECTED_OPERATOR,
    PARSE_UNEXPECTED_TERM, PARSE_UNEXPECTED_KEYWORD, PARSE_EXPECTED_EXPRESSION, PARSE_EXPECTED_LEFT_PAREN_AFTER_CAST,
    PARSE_EXPECTED_LEFT_PAREN_VALUE_CONSTRUCTOR, PARSE_EXPECTED_LEFT_PAREN_BUILTIN_FUNCTION_CALL,
    PARSE_EXPECTED_RIGHT_PAREN_BUILTIN_FUNCTION_CALL, PARSE_EXPECTED_ARGUMENT_DELIMITER, PARSE_CAST_ARITY,
    PARSE_INVALID_TYPE_PARAM, PARSE_EMPTY_SELECT, PARSE_SELECT_MISSING_FROM, PARSE_MISSING_OPERATION,
    PARSE_MISSING_SET_ASSIGNMENT, PARSE_EXPECTED_IDENT_FOR_GROUP_NAME, PARSE_EXPECTED_IDENT_FOR_ALIAS,
    PARSE_EXPECTED_KEYWORD_FOR_MATCH, PARSE_EXPECTED_IDENT_FOR_MATCH, PARSE_EXPECTED_LEFT_PAREN_FOR_MATCH_NODE,
    PARSE_EXPECTED_RIGHT_PAREN_FOR_MATCH_NODE, PARSE_EXPECTED_LEFT_BRACKET_FOR_MATCH_EDGE,
    PARSE_EXPECTED_RIGHT_BRACKET_FOR_MATCH_EDGE, PARSE_EXPECTED_PARENTHESIZED_PATTERN, PARSE_EXPECTED_EDGE_PATTERN_MATCH_EDGE,
    PARSE_EXPECTED_EQUALS_FOR_MATCH_PATH_VARIABLE, PARSE_EXPECTED_AS_FOR_LET, PARSE_UNSUPPORTED_CALL_WITH_STAR,
    PARSE_NON_UNARY_AGREGATE_FUNCTION_CALL, PARSE_NO_STORED_PROCEDURE_PROVIDED, PARSE_MALFORMED_JOIN,
    PARSE_EXPECTED_IDENT_FOR_AT, PARSE_INVALID_CONTEXT_FOR_WILDCARD_IN_SELECT_LIST,
    PARSE_CANNOT_MIX_SQB_AND_WILDCARD_IN_SELECT_LIST, PARSE_ASTERISK_IS_NOT_ALONE_IN_SELECT_LIST,
    SEMANTIC_DUPLICATE_ALIASES_IN_SELECT_LIST_ITEM, SEMANTIC_NO_SUCH_FUNCTION, SEMANTIC_INCORRECT_ARGUMENT_TYPES_TO_FUNC_CALL,
    EVALUATOR_NON_TEXT_STRUCT_KEY, SEMANTIC_INCORRECT_NODE_ARITY, SEMANTIC_ASTERISK_USED_WITH_OTHER_ITEMS,
    getKeyword() from org.partiql.lang.errors.ErrorCode

  • Breaking: Removes unused fillErrorContext() from org.partiql.lang.eval

  • Breaking: Removes deprecated isNull() from org.partiql.lang.eval.ExprValueType

  • Breaking: Remove unused fromTypeName(), fromSqlDataType(), fromSqlDataTypeOrNull() from org.partiql.lang.eval.ExprValueType

  • Breaking: Removes deprecated org.partiql.lang.syntax.Lexer

  • Breaking: Removes unused STANDARD_AGGREGATE_FUNCTIONS, OperatorPrecedenceGroups from org.partiql.lang.syntax

  • Breaking: Removes deprecated org.partiql.lang.syntax.SourcePosition

  • Breaking: Removes deprecated org.partiql.lang.syntax.SourceSpan

  • Breaking: Removes deprecated org.partiql.lang.syntax.Token

  • Breaking: Removes deprecated org.partiql.lang.syntax.TokenType

  • Breaking: Stops publishing PartiQL ISL to Maven Central. The last published version is https://central.sonatype.com/artifact/org.partiql/partiql-isl-kotlin/0.11.0

  • Breaking: Removes unused package org.partiql.lang.schemadiscovery which included unused classes of:
    SchemaInferencerFromExample, SchemaInferencerFromExampleImpl, TypeConstraint, NormalizeNullableVisitorTransform,
    NormalizeDecimalPrecisionsToUpToRange, and IonExampleParser.

  • Breaking: Removes unused package org.partiql.lang.partiqlisl which includes unused classes/methods: ResourceAuthority,
    getResourceAuthority(), and loadPartiqlIsl().

  • Breaking: Plan nodes cannot be directly instantiated. To instantiate, use the Plan (DEFAULT) factory.

  • Breaking: PlanRewriter has been moved from org.partiql.plan.visitor.PlanRewriter to org.partiql.plan.util.PlanRewriter

Security

Contributors

Thank you to all who have contributed!

Commits: v0.11.0-alpha...v0.12.0-alpha

v0.11.0-alpha

22 May 18:42
748e8eb
Compare
Choose a tag to compare
v0.11.0-alpha Pre-release
Pre-release

Added

  • Adds an initial implementation of GPML (Graph Pattern Matching Language), following
    PartiQL RFC-0025
    and RFC-0033.
    This initial implementation includes:
    • A file format for external graphs, defined as a schema in ISL (Ion Schema Language),
      as well as an in-memory graph data model and a reader for loading external graphs into it.
    • CLI shell commands !add_graph and !add_graph_from_file for bringing
      externally-defined graphs into the evaluation environment.
    • Evaluation of straight-path patterns with simple label matching and
      all directed/undirected edge patterns.
  • Adds new TupleConstraint variant, Ordered, to represent ordering in StructType. See the KDoc for more information.

Changed

  • Breaking: The fields attribute of org.partiql.types.StructType is no longer a Map<String, StaticType>. It is
    now a List<org.partiql.types.StructType.Field>, where Field contains a key (String) and value (StaticType). This
    is to allow duplicates within the StructType.

Deprecated

  • None

Fixed

  • Fixes the ability for JOIN predicates to access the FROM source aliases and corresponding attributes.

Removed

  • None

Security

  • None

Comparison

Comparing v0.10.0 - v0.11.0

Contributors

Thank you to all who have contributed!

v0.10.0-alpha

06 May 00:38
c6b9c7f
Compare
Choose a tag to compare
v0.10.0-alpha Pre-release
Pre-release

Added

  • Added numeric builtins ABS, SQRT, EXP, LN, POW, MOD.
  • Added standard SQL built-in functions POSITION, OVERLAY, LENGTH, BIT_LENGTH, OCTET_LENGTH, CARDINALITY,
    an additional builtin TEXT_REPLACE, and standard SQL aggregations on booleans EVERY, ANY, SOME.
  • Breaking Added coercion of SQL-style subquery to a single value, as defined in SQL for
    subqueries occurring in a single-value context and outlined in Chapter 9 of the PartiQL specification.
    This is backward incompatible with the prior behavior (which left the computed collection as is),
    but brings it in conformance with the specification.
  • Added partiql-plan package which contains experimental PartiQL Plan data structures.
  • Initializes SPI Framework under partiql-spi.
  • Models experimental Schema with constraints.
    With this change, we're introducing Tuple and Collection constraints to be able to model the shape of data as
    constraints.
  • Introduces the PartiQLSchemaInferencer and PlannerSession
    • The PlannerSession describes the current session and is used by the PartiQLSchemaInferencer.
    • The PartiQLSchemaInferencer provides a function, infer, to aid in inferring the output StaticType of a
      PartiQL Query. See the KDoc for more information and examples.
  • Adds back ability to convert an IonDatagram to an ExprValue using of(value: IonValue): ExprValue and newFromIonValue(value: IonValue): ExprValue
  • Adds support for SQL's CURRENT_USER in the AST, EvaluatingCompiler, experimental planner implementation, and Schema Inferencer.
    • Adds the AST node session_attribute.
    • Adds the function EvaluationSession.Builder::user() to add the CURRENT_USER to the EvaluationSession
  • Adds support for parsing and planning of INSERT INTO .. AS <alias> ... ON CONFLICT DO [UPDATE|REPLACE] EXCLUDED WHERE <expr>
  • Adds the statement.dml and dml_operation node to the experimental PartiQL Physical Plan.

Changed

  • Deprecates the project level opt-in annotation PartiQLExperimental and split it into feature level. ExperimentalPartiQLCompilerPipeline and ExperimentalWindowFunctions.
  • Breaking: Moves StaticType to partiql-types.
    • All references to static types need to modify their imports accordingly. For example,
      org.partiql.lang.types.IntType is now org.partiql.types.IntType.
    • Please modify existing dependencies accordingly. You may need to add dependency org.partiql:partiql-types:0.10.0.
    • Also, several methods within StaticType have been moved to a utility class within partiql-lang-kotln. See the below list:
      1. org.partiql.lang.types.StaticType.fromExprValueType -> org.partiql.lang.types.StaticTypeUtils.staticTypeFromExprValueType
      2. org.partiql.lang.types.StaticType.fromExprValue -> org.partiql.lang.types.StaticTypeUtils.staticTypeFromExprValue
      3. org.partiql.lang.types.StaticType.isInstance -> org.partiql.lang.types.StaticTypeUtils.isInstance
      4. org.partiql.lang.types.StaticType.isComparableTo -> org.partiql.lang.types.StaticTypeUtils.areStaticTypesComparable
      5. org.partiql.lang.types.StaticType.isSubTypeOf -> org.partiql.lang.types.StaticTypeUtils.isSubTypeOf
      6. org.partiql.lang.types.StaticType.typeDomain -> org.partiql.lang.types.StaticTypeUtils.getTypeDomain
      7. org.partiql.lang.types.SingleType.getRuntimeType -> org.partiql.lang.types.StaticTypeUtils.getRuntimeType
      8. org.partiql.lang.types.StringType.StringLengthConstraint.matches -> org.partiql.lang.types.StaticTypeUtils.stringLengthConstraintMatches
  • Breaking: Removes deprecated ionSystem() function from PartiQLCompilerBuilder and PartiQLParserBuilder
  • Breaking: Adds a new property as_alias to the insert AST node.
  • Breaking: Adds new property condition to the AST nodes of do_replace and do_update
  • Breaking: Adds target_alias property to the dml_insert, dml_replace, and dml_update nodes within the
    Logical and Logical Resolved plans
  • Breaking: Adds condition property to the dml_replace and dml_update nodes within the
    Logical and Logical Resolved plans

Deprecated

  • ExprValueFactory interface marked as deprecated. Equivalent ExprValue construction methods are implemented in the ExprValue interface as static methods.

Fixed

  • Javadoc jar now contains dokka docs (was broken by gradle commit from 0.9.0)
  • ANTLR (PartiQL.g4, PartiQLTokens.g4) and PIG (org/partiql/type-domains/partiql.ion) sources
    are back to being distributed with the jar.
  • CLI no longer terminates on user errors in submitted PartiQL (when printing out the AST with !!)
    and no longer prints out stack traces upon user errors.
  • Constrained Decimal matching logic.
  • Parsing INSERT statements with aliases no longer loses the original table name. Closes #1043.
  • Parsing INSERT statements with the legacy ON CONFLICT clause is no longer valid. Similarly, parsing the legacy INSERT
    statement with the up-to-date ON CONFLICT clause is no longer valid. Closes #1063.

Removed

  • The deprecated IonValue property in ExprValue interface is now removed.
  • Removed partiql-extensions to partiql-cli org.partiql.cli.functions
  • Removed IonSystem from PartiQLParserBuilder
  • Breaking: Removes node statement.dml_query from the experimental PartiQL Physical Plan. Please see the added
    statement.dml and dml_operation nodes.

Security

  • None

Commits: v0.9.4-alpha...v0.10.0-alpha

v0.9.4-alpha

21 Apr 19:05
265d679
Compare
Choose a tag to compare
v0.9.4-alpha Pre-release
Pre-release

Release v0.9.4-alpha

This release reverts changes in the previous release v0.9.3-alpha because the previous version contains the following breaking changes:

  • StaticType move from partiql-lang to partiql-types.
  • Deprecated ionSystem() function has been removed from PartiQLCompilerBuilder and PartiQLParserBuilder.

List of commits: v0.9.3-alpha...v0.9.4-alpha

v0.9.3-alpha

13 Apr 21:23
5e7ccd1
Compare
Choose a tag to compare
v0.9.3-alpha Pre-release
Pre-release

Release v0.9.3-alpha

Please note:

Although this version is versioned as patch on v0.9.2-alpha (the previous version) it still contains the following breaking changes PartiQL maintainers are working to rectify this issue and will update the release notes:

  • StaticType move from partiql-lang to partiql-types.
  • Deprecated ionSystem() function has been removed from PartiQLCompilerBuilder and PartiQLParserBuilder.

Added

  • Added numeric builtins ABS, SQRT, EXP, LN, POW, MOD.
  • Added standard SQL built-in functions POSITION, OVERLAY, LENGTH, BIT_LENGTH, OCTET_LENGTH, CARDINALITY,
    an additional builtin TEXT_REPLACE, and standard SQL aggregations on booleans EVERY, ANY, SOME.
  • Breaking Added coercion of SQL-style subquery to a single value, as defined in SQL for
    subqueries occurring in a single-value context and outlined in Chapter 9 of the PartiQL specification.
    This is backward incompatible with the prior behavior (which left the computed collection as is),
    but brings it in conformance with the specification.
  • Added partiql-plan package which contains experimental PartiQL Plan data structures.
  • Initializes SPI Framework under partiql-spi.
  • Models experimental Schema with constraints.
    With this change, we're introducing Tuple and Collection constraints to be able to model the shape of data as
    constraints.
  • Introduces the PartiQLSchemaInferencer and PlannerSession
    • The PlannerSession describes the current session and is used by the PartiQLSchemaInferencer.
    • The PartiQLSchemaInferencer provides a function, infer, to aid in inferring the output StaticType of a
      PartiQL Query. See the KDoc for more information and examples.

Changed

  • Deprecates the project level opt-in annotation PartiQLExperimental and split it into feature level. ExperimentalPartiQLCompilerPipeline and ExperimentalWindowFunctions.
  • Breaking: Moves StaticType to partiql-types.
    • All references to static types need to modify their imports accordingly. For example,
      org.partiql.lang.types.IntType is now org.partiql.types.IntType.
    • Please modify existing dependencies accordingly. You may need to add dependency org.partiql:partiql-types:0.10.0.
    • Also, several methods within StaticType have been moved to a utility class within partiql-lang-kotln. See the below list:
      1. org.partiql.lang.types.StaticType.fromExprValueType -> org.partiql.lang.types.StaticTypeUtils.staticTypeFromExprValueType
      2. org.partiql.lang.types.StaticType.fromExprValue -> org.partiql.lang.types.StaticTypeUtils.staticTypeFromExprValue
      3. org.partiql.lang.types.StaticType.isInstance -> org.partiql.lang.types.StaticTypeUtils.isInstance
      4. org.partiql.lang.types.StaticType.isComparableTo -> org.partiql.lang.types.StaticTypeUtils.areStaticTypesComparable
      5. org.partiql.lang.types.StaticType.isSubTypeOf -> org.partiql.lang.types.StaticTypeUtils.isSubTypeOf
      6. org.partiql.lang.types.StaticType.typeDomain -> org.partiql.lang.types.StaticTypeUtils.getTypeDomain
      7. org.partiql.lang.types.SingleType.getRuntimeType -> org.partiql.lang.types.StaticTypeUtils.getRuntimeType
      8. org.partiql.lang.types.StringType.StringLengthConstraint.matches -> org.partiql.lang.types.StaticTypeUtils.stringLengthConstraintMatches
  • Breaking: Removes deprecated ionSystem() function from PartiQLCompilerBuilder and PartiQLParserBuilder

Deprecated

  • ExprValueFactory interface marked as deprecated. Equivalent ExprValue construction methods are implemented in the ExprValue interface as static methods.

Fixed

  • Javadoc jar now contains dokka docs (was broken by gradle commit from 0.9.0)

  • ANTLR (PartiQL.g4, PartiQLTokens.g4) and PIG (org/partiql/type-domains/partiql.ion) sources
    are back to being distributed with the jar.

  • CLI no longer terminates on user errors in submitted PartiQL (when printing out the AST with !!)
    and no longer prints out stack traces upon user errors.

  • Constrained Decimal matching logic.

Removed

  • The deprecated IonValue property in ExprValue interface is now removed.
  • Removed partiql-extensions to partiql-cli org.partiql.cli.functions
  • Removed IonSystem from PartiQLParserBuilder

Security

List of commits: v0.9.2-alpha...v0.9.3-alpha

v0.9.2-alpha

23 Jan 18:17
f3b92a8
Compare
Choose a tag to compare
v0.9.2-alpha Pre-release
Pre-release

This version is a minor version with no breaking changes.

Release v0.9.2-alpha

Features

  • Integrates Pico CLI to create a better CLI experience
  • Adds support for shebangs (allowing for executable PartiQL files)

Fixes

  • Fixes list/bag ExprValue creation in plan evaluator
  • Fixes gradle build issues

List of commits: v0.9.1-alpha...v0.9.2-alpha

v0.9.1-alpha

04 Jan 23:53
Compare
Choose a tag to compare
v0.9.1-alpha Pre-release
Pre-release

This version is a minor version with no breaking changes.

Added

  • Makes the following PartiQLCompilerBuilder functions public:
    • customOperatorFactories
    • customFunctions
    • customProcedures
    • customTypes

List of commits: v0.9.0-alpha...v0.9.1-alpha

v0.9.0-alpha

21 Dec 20:48
692d442
Compare
Choose a tag to compare
v0.9.0-alpha Pre-release
Pre-release

Breaking Changes

Breaking behavioral changes

In version v.9.0, as a result of deprecating ionValue property in ExprValue and introduction of the substitute method ExprValue.toIonValue(ion: IonSystem) in Kotlin, and ExprValueKt.toIonValue(value: ExprValue, ion: IonSystem) in Java.
Ion annotation will get elided from the provided Ion values in identity evaluations:

Example

val query = `annotation::1`

/* Prior to v0.9 

  ExprValue: IonExprValue
  ionValue: annotation::1

*/

/* After v0.9

  ExprValue: IntExprValue
  toIonValue: 1

*/

Other Breaking Changes

  • Removes the deprecated V0 AST in the codebase.
  • Removes the deprecated MetaContainer in the codebase, removed interfaces and classes include:
    • [MetaContainer] Interface
    • [MetaContainerImpl]
    • [MetaDeserialize]
    • [MemoizedMetaDeserializer]
  • Removes the deprecated Rewriter/AstWalker/AstVisitor in the code base, removed interfaces and classes include:
    • [AstRewriter] Interface & [AstRewriterBase] class
    • [AstVisitor] Interface & [AstVisitorBase] class
    • [AstWalker] class
    • [MetaStrippingRewriter] class
  • Removes the deprecated ExprNode and related files in the code base.
    • [Parser] API parseExprNode(source: String): ExprNode has been removed.
    • [CompilerPipeline] API compile(query: ExprNode): Expression has been removed.
    • [ExprNode] and [AstNode] have been removed.
    • Functions related to conversions between ExprNode and PartiqlAst have been removed.
  • Removes the deprecated SqlParser and SqlLexer
  • Removes the CallAgg node from the Logical, LogicalResolved, and Physical plans.
  • Removes the experimental PlannerPipeline and replaces it with PartiQLCompilerPipeline.

Added

  • Adds simple auto-completion to the CLI.
  • Adds the IsListParenthesizedMeta meta to aid in differentiating between parenthesized and non-parenthesized lists
  • Adds support for HAVING clause in planner
  • Adds support for collection aggregation functions in the EvaluatingCompiler and experimental planner
  • Adds support for the syntactic sugar of using aggregations functions in place of their collection aggregation function
    counterparts (in the experimental planner)
  • Experimental implementation for window function Lag and Lead.
  • Adds support for EXPLAIN
  • Adds continuous performance benchmarking to the CI for existing JMH benchmarks
    • Benchmark results can be seen on the project's GitHub Pages site
  • Adds the pipeline flag to the CLI to provide experimental usage of the PartiQLCompilerPipeline
  • Added ExprValue.toIonValue(ion: IonSystem) in kotlin, and ExprValueExtensionKt.toIonValue(value: ExprValue, ion: IonSystem) in Java to transform one ExprValue to a corresponding IonValue.
  • Added ExprValue.of(value: IonValue) method to construct an ExprValue from an IonValue.

Changed

  • Now CompileOption uses TypedOpParameter.HONOR_PARAMETERS as default.
  • Updates the CLI Shell Highlighter to use the ANTLR generated lexer/parser for highlighting user queries
  • PartiQL MISSING in Ion representation now becomes ion null with annotation of $missing, instead of $partiql_missing
  • PartiQL BAG in Ion representation now becomes ion list with annotation of $bag, instead of $partiql_bag
  • PartiQL DATE in Ion representation now becomes ion timestamp with annotation of $date, instead of $partiql_date
  • PartiQL TIME in Ion representation now becomes ion struct with annotation of $time, instead of $partiql_time
  • Simplifies the aggregation operator in the experimental planner by removing the use of metas
  • Increases the performance of the PartiQLParser by changing the parsing strategy
    • The PartiQLParser now attempts to parse queries using the SLL Prediction Mode set by ANTLR
    • If unable to parse via SLL Prediction Mode, it attempts to parse using the slower LL Prediction Mode
    • Modifications have also been made to the ANTLR grammar to increase the speed of parsing joined table references
    • Updates how the PartiQLParser handles parameter indexes to remove the double-pass while lexing
  • Changes the expected Property's of TOKEN_INFO to use Property.TOKEN_DESCRIPTION instead of Property.TOKEN_TYPE

Deprecated

  • Marks the GroupKeyReferencesVisitorTransform as deprecated. There is no functionally equivalent class.
  • Marks ionValue property in ExprValue interface as deprecated. The functional equivalent method is ExprValue.toIonValue(ion: IonSystem) in kotlin, and ExprValueKt.toIonValue(value: ExprValue, ion: IonSystem) in Java.
  • Marks Lexer, Token, TokenType, SourcePosition, and SourceSpan as deprecated. These will be removed without
    any replacement.
  • Marks approximately 60 ErrorCode's as deprecated. These will be removed without any replacement.
  • Marks Property.TOKEN_TYPE as deprecated. Please use Property.TOKEN_DESCRIPTION.

Fixed

  • Fixes the ThreadInterruptedTests by modifying the time to interrupt parses. Also adds better exception exposure to
    facilitate debugging.