Skip to content

Commit

Permalink
feature/230: Added serializer for SqlNode (#232)
Browse files Browse the repository at this point in the history
* feature/230: Added serializer for SqlNode
  • Loading branch information
jakobbraun authored Aug 6, 2021
1 parent 6653ab3 commit e18c8f1
Show file tree
Hide file tree
Showing 17 changed files with 1,628 additions and 206 deletions.
9 changes: 4 additions & 5 deletions .github/workflows/broken_links_checker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: lychee Link Checker
id: lc
uses: lycheeverse/[email protected]
- name: Fail if there were link errors
run: exit ${{ steps.lc.outputs.exit_code }}
- uses: gaurav-nelson/github-action-markdown-link-check@v1
with:
use-quiet-mode: 'yes'
use-verbose-mode: 'yes'
30 changes: 30 additions & 0 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: CI Build

on:
- push

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Cache local Maven repository
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Run tests and build with Maven
run: mvn --batch-mode --update-snapshots clean verify sonar:sonar --file pom.xml -DtrimStackTrace=false -Dsonar.organization=exasol -Dsonar.host.url=https://sonarcloud.io -Dsonar.login=$SONAR_TOKEN
env:
GITHUB_OAUTH: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,9 @@ jobs:
uses: shogo82148/actions-upload-release-asset@v1
with:
upload_url: ${{ github.event.inputs.upload_url }}
asset_path: target/*.jar
asset_path: target/*.jar
- name: Upload error-code-report
uses: shogo82148/actions-upload-release-asset@v1
with:
upload_url: ${{ github.event.inputs.upload_url }}
asset_path: target/error_code_report.json
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,4 @@ dependency-reduced-pom.xml
**/local
Scripts
.dbeaver*
pom.xml.versionsBackup
13 changes: 0 additions & 13 deletions .travis.yml

This file was deleted.

50 changes: 3 additions & 47 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
# Common module of Exasol Virtual Schemas Adapters

[![Build Status](https://travis-ci.com/exasol/virtual-schema-common-java.svg?branch=main)](https://travis-ci.com/exasol/virtual-schema-common-java)
[![Build Status](https://github.com/exasol/virtual-schema-common-java/actions/workflows/ci-build.yml/badge.svg)](https://github.com/exasol/virtual-schema-common-java/actions/workflows/ci-build.yml)
[![Maven Central](https://img.shields.io/maven-central/v/com.exasol/virtual-schema-common-java)](https://search.maven.org/artifact/com.exasol/virtual-schema-common-java)

SonarCloud results:

[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=com.exasol%3Avirtual-schema-common-java&metric=alert_status)](https://sonarcloud.io/dashboard?id=com.exasol%3Avirtual-schema-common-java)

[![Security Rating](https://sonarcloud.io/api/project_badges/measure?project=com.exasol%3Avirtual-schema-common-java&metric=security_rating)](https://sonarcloud.io/dashboard?id=com.exasol%3Avirtual-schema-common-java)
Expand All @@ -17,9 +15,7 @@ SonarCloud results:
[![Duplicated Lines (%)](https://sonarcloud.io/api/project_badges/measure?project=com.exasol%3Avirtual-schema-common-java&metric=duplicated_lines_density)](https://sonarcloud.io/dashboard?id=com.exasol%3Avirtual-schema-common-java)
[![Lines of Code](https://sonarcloud.io/api/project_badges/measure?project=com.exasol%3Avirtual-schema-common-java&metric=ncloc)](https://sonarcloud.io/dashboard?id=com.exasol%3Avirtual-schema-common-java)

This is one of the modules of Virtual Schemas Adapters.
The libraries provided by this project are the foundation of the adapter development, i.e. adapters must be implemented on top of them.
You can find the full description of the project here: https://github.com/exasol/virtual-schemas
This is one of the modules of Virtual Schemas Adapters. The libraries provided by this project are the foundation of the adapter development, i.e. adapters must be implemented on top of them. You can find the full description of the project here: https://github.com/exasol/virtual-schemas

A Virtual Schema adapter is basically a [UDF](https://docs.exasol.com/database_concepts/udf_scripts.htm). The Exasol core database communicates with this UDF using JSON strings. There are different types of messages, that define the API for a virtual Schema adapter ([protocol reference](doc/development/api/virtual_schema_api.md)). This repository wraps this JSON API with a Java API to facilitate the implementation of Virtual Schema adapters in Java.

Expand All @@ -28,53 +24,13 @@ Please note that the artifact name changed from "virtualschema-common" to "virtu
## Information for Users

* [Changelog](doc/changes/changelog.md)
* [Dependencies](dependencies.md)

## Information for Developers

* [Virtual Schema API](doc/development/api/virtual_schema_api.md)
* [Capabilities list](doc/development/api/capabilities_list.md)

## Dependencies

### Run Time Dependencies

| Dependency | Purpose | License |
|-------------------------------------------------------------------------------------|--------------------------------------------------------|-------------------------------|
| [JSON-P](https://javaee.github.io/jsonp/) | JSON Processing | CDDL-1.0 |
| [Exasol Script API](https://docs.exasol.com/database_concepts/udf_scripts.htm) | Accessing Exasol features | MIT License |

### Build Time Dependencies

| Dependency | Purpose | License |
|-------------------------------------------------------------------------------------|--------------------------------------------------------|-------------------------------|
| [Apache Maven](https://maven.apache.org/) | Build tool | Apache License 2.0 |
| [Java Hamcrest](http://hamcrest.org/JavaHamcrest/) | Checking for conditions in code via matchers | BSD License |
| [JSONassert](http://jsonassert.skyscreamer.org/) | Compare JSON documents for semantic equality | Apache License 2.0 |
| [JUnit](https://junit.org/junit5) | Unit testing framework | Eclipse Public License 1.0 |
| [Mockito](http://site.mockito.org/) | Mocking framework | MIT License |
| [JUnit 5 System Extensions](https://github.com/itsallcode/junit5-system-extensions) | Capturing `STDOUT` and `STDERR` | Eclipse Public License 2.0 |
| [Equals Verifier](https://jqno.nl/equalsverifier/) | Testing `equals(...)` and `hashCode()` contracts | Apache License 2.0 |

### Maven Plug-ins

| Plug-in | Purpose | License |
---------------------------------------------------------------------------------|--------------------------------------------------------|--------------------------------
| [Maven Compiler Plugin][maven-compiler-plugin] | Setting required Java version | Apache License 2.0 |
| [Maven GPG Plugin](https://maven.apache.org/plugins/maven-gpg-plugin/) | Signs JARs | Apache License 2.0 |
| [Maven Enforcer Plugin][maven-enforcer-plugin] | Controlling environment constants | Apache License 2.0 |
| [Maven Jacoco Plugin](https://www.eclemma.org/jacoco/trunk/doc/maven.html) | Code coverage metering | Eclipse Public License 2.0 |
| [Maven JavaDoc Plugin](https://maven.apache.org/plugins/maven-javadoc-plugin/) | Creates JavaDoc JARs | Apache License 2.0 |
| [Maven Source Plugin](https://maven.apache.org/plugins/maven-source-plugin/) | Creates source JARs | Apache License 2.0 |
| [Maven Surefire Plugin][maven-surefire-plugin] | Unit testing | Apache License 2.0 |
| [Sonatype OSS Index Maven Plugin][sonatype-oss-index-maven-plugin] | Checking Dependencies Vulnerability | ASL2 |
| [Versions Maven Plugin][versions-maven-plugin] | Checking if dependencies updates are available | Apache License 2.0 |

[maven-compiler-plugin]: https://maven.apache.org/plugins/maven-compiler-plugin/
[maven-enforcer-plugin]: http://maven.apache.org/enforcer/maven-enforcer-plugin/
[maven-surefire-plugin]: https://maven.apache.org/surefire/maven-surefire-plugin/
[sonatype-oss-index-maven-plugin]: https://sonatype.github.io/ossindex-maven/maven-plugin/
[versions-maven-plugin]: https://www.mojohaus.org/versions-maven-plugin/

## Open Source Project Support

Please note that this is an open source project which is officially supported by Exasol. This module is part of a larger project called [Virtual Schemas](https://github.com/exasol/virtual-schemas).
Expand Down
84 changes: 84 additions & 0 deletions dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
<!-- @formatter:off -->
# Dependencies

## Compile Dependencies

| Dependency | License |
| ----------------------------------------------- | -------------------------------------------------------- |
| [JSR 374 (JSON Processing) Default Provider][0] | [Dual license consisting of the CDDL v1.1 and GPL v2][1] |
| [Java Interface for EXASOL Scripts][2] | [MIT License][3] |
| [error-reporting-java][4] | [MIT][3] |

## Test Dependencies

| Dependency | License |
| -------------------------------- | --------------------------------------------- |
| [Hamcrest][6] | [BSD License 3][7] |
| [JSONassert][8] | [The Apache Software License, Version 2.0][9] |
| [JUnit Jupiter (Aggregator)][10] | [Eclipse Public License v2.0][11] |
| [mockito-junit-jupiter][12] | [The MIT License][13] |
| [JUnit5 System Extensions][14] | [Eclipse Public License v2.0][15] |
| [EqualsVerifier][16] | [Apache License, Version 2.0][9] |

## Plugin Dependencies

| Dependency | License |
| ------------------------------------------------------- | --------------------------------------------- |
| [Apache Maven Compiler Plugin][18] | [Apache License, Version 2.0][19] |
| [JaCoCo :: Maven Plugin][20] | [Eclipse Public License 2.0][21] |
| [Maven Surefire Plugin][22] | [Apache License, Version 2.0][19] |
| [Apache Maven Source Plugin][24] | [Apache License, Version 2.0][19] |
| [Apache Maven Javadoc Plugin][26] | [Apache License, Version 2.0][19] |
| [Apache Maven GPG Plugin][28] | [Apache License, Version 2.0][9] |
| [org.sonatype.ossindex.maven:ossindex-maven-plugin][30] | [ASL2][9] |
| [Versions Maven Plugin][32] | [Apache License, Version 2.0][19] |
| [Apache Maven Enforcer Plugin][34] | [Apache License, Version 2.0][19] |
| [Maven Deploy Plugin][36] | [The Apache Software License, Version 2.0][9] |
| [Nexus Staging Maven Plugin][38] | [Eclipse Public License][39] |
| [error-code-crawler-maven-plugin][40] | [MIT][3] |
| [Project keeper maven plugin][42] | [MIT][3] |
| [Reproducible Build Maven Plugin][44] | [Apache 2.0][9] |
| [Maven Clean Plugin][46] | [The Apache Software License, Version 2.0][9] |
| [Maven Resources Plugin][48] | [The Apache Software License, Version 2.0][9] |
| [Maven JAR Plugin][50] | [The Apache Software License, Version 2.0][9] |
| [Maven Install Plugin][52] | [The Apache Software License, Version 2.0][9] |
| [Maven Site Plugin 3][54] | [The Apache Software License, Version 2.0][9] |

[20]: https://www.eclemma.org/jacoco/index.html
[42]: https://github.com/exasol/project-keeper-maven-plugin
[4]: https://github.com/exasol/error-reporting-java
[15]: http://www.eclipse.org/legal/epl-v20.html
[0]: https://javaee.github.io/jsonp
[9]: http://www.apache.org/licenses/LICENSE-2.0.txt
[22]: https://maven.apache.org/surefire/maven-surefire-plugin/
[38]: http://www.sonatype.com/public-parent/nexus-maven-plugins/nexus-staging/nexus-staging-maven-plugin/
[46]: http://maven.apache.org/plugins/maven-clean-plugin/
[3]: https://opensource.org/licenses/MIT
[12]: https://github.com/mockito/mockito
[32]: http://www.mojohaus.org/versions-maven-plugin/
[7]: http://opensource.org/licenses/BSD-3-Clause
[18]: https://maven.apache.org/plugins/maven-compiler-plugin/
[1]: https://oss.oracle.com/licenses/CDDL+GPL-1.1
[28]: http://maven.apache.org/plugins/maven-gpg-plugin/
[21]: https://www.eclipse.org/legal/epl-2.0/
[39]: http://www.eclipse.org/legal/epl-v10.html
[13]: https://github.com/mockito/mockito/blob/main/LICENSE
[44]: http://zlika.github.io/reproducible-build-maven-plugin
[50]: http://maven.apache.org/plugins/maven-jar-plugin/
[19]: https://www.apache.org/licenses/LICENSE-2.0.txt
[34]: https://maven.apache.org/enforcer/maven-enforcer-plugin/
[2]: http://www.exasol.com
[11]: https://www.eclipse.org/legal/epl-v20.html
[52]: http://maven.apache.org/plugins/maven-install-plugin/
[10]: https://junit.org/junit5/
[30]: https://sonatype.github.io/ossindex-maven/maven-plugin/
[14]: https://github.com/itsallcode/junit5-system-extensions
[8]: https://github.com/skyscreamer/JSONassert
[16]: http://www.jqno.nl/equalsverifier
[24]: https://maven.apache.org/plugins/maven-source-plugin/
[6]: http://hamcrest.org/JavaHamcrest/
[36]: http://maven.apache.org/plugins/maven-deploy-plugin/
[54]: http://maven.apache.org/plugins/maven-site-plugin/
[48]: http://maven.apache.org/plugins/maven-resources-plugin/
[26]: https://maven.apache.org/plugins/maven-javadoc-plugin/
[40]: https://github.com/exasol/error-code-crawler-maven-plugin
1 change: 1 addition & 0 deletions doc/changes/changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Changes

* [15.2.0](changes_15.2.0.md)
* [15.1.0](changes_15.1.0.md)
* [15.0.1](changes_15.0.1.md)
* [15.0.0](changes_15.0.0.md)
Expand Down
23 changes: 23 additions & 0 deletions doc/changes/changes_15.2.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Common module of Exasol Virtual Schemas Adapters 15.2.0, released 2021-08-06

Code name: SqlNode serialization

## Summary

In this release we added a renderer for the `SqlNode` structure.

## Features

* #230: Added serializer for SqlNode

## Dependency Updates

### Test Dependency Updates

* Updated `nl.jqno.equalsverifier:equalsverifier:3.6` to `3.7`
* Updated `org.mockito:mockito-junit-jupiter:3.10.0` to `3.11.2`

### Plugin Dependency Updates

* Updated `com.exasol:error-code-crawler-maven-plugin:0.1.0` to `0.5.1`
* Updated `com.exasol:project-keeper-maven-plugin:0.6.1` to `0.10.0`
3 changes: 0 additions & 3 deletions errorCodeConfig.yml

This file was deleted.

4 changes: 4 additions & 0 deletions error_code_config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
error-tags:
VS-COM-JAVA:
packages:
- com.exasol
Loading

0 comments on commit e18c8f1

Please sign in to comment.