From 666e23d77f14fcd9d731e7a278bf75cd27365d48 Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Tue, 28 Jul 2020 18:18:21 +0200 Subject: [PATCH 01/13] Few points related to replication and schema evolution checked. --- data/replication/slave/README.md | 7 ++++++- .../replication/slave/docker-compose.test.yml | 19 +++++++++++++++++++ .../{Dockerfile => test/Dockerfile-slave} | 0 data/replication/slave/test/build-slave.sh | 3 +++ data/test/Dockerfile | 7 ++++--- data/test/README.md | 11 +++++++++-- schema-evolution.md | 8 +++----- 7 files changed, 44 insertions(+), 11 deletions(-) create mode 100644 data/replication/slave/docker-compose.test.yml rename data/replication/slave/{Dockerfile => test/Dockerfile-slave} (100%) create mode 100755 data/replication/slave/test/build-slave.sh diff --git a/data/replication/slave/README.md b/data/replication/slave/README.md index 788dc90..4067ca1 100644 --- a/data/replication/slave/README.md +++ b/data/replication/slave/README.md @@ -67,7 +67,7 @@ Make sure, that the slave can access the master via TCP. Check firewall rules. Let the slave subscribe to the publication: ```sql -CREATE SUBSCRIPTION subodh CONNECTION 'host=odh-hackathon-2019_db_1 dbname=tourismuser user=vkgreplicate password=Azerty' PUBLICATION odhpub; +CREATE SUBSCRIPTION subodh CONNECTION 'host=odh-tourism-db1 dbname=tourismuser user=vkgreplicate password=Azerty' PUBLICATION odhpub; ``` Note that the subscription `subodh` must not already exist (otherwise give it another name). @@ -102,3 +102,8 @@ To free storage, you can also drop the underlying slot: ```sql SELECT pg_drop_replication_slot('Your_slotname_name'); ``` + + +## Easy experimenting + +There is [a Docker compose file](./docker-compose.test.yml) available for starting the master and the slave DB. Note that the publication and the subscription are NOT set up. Also their WAL level is `replicated`, not `logical`. \ No newline at end of file diff --git a/data/replication/slave/docker-compose.test.yml b/data/replication/slave/docker-compose.test.yml new file mode 100644 index 0000000..8bd2798 --- /dev/null +++ b/data/replication/slave/docker-compose.test.yml @@ -0,0 +1,19 @@ +version: '3.4' + +services: + master: + image: ontopicvkg/odh-tourism-db:original + shm_size: 1g + ports: + - "7779:5432" + environment: + - POSTGRES_USER=tourismuser + - POSTGRES_PASSWORD=postgres2 + slave: + image: ontopicvkg/odh-db-slave + shm_size: 1g + ports: + - "7780:5432" + environment: + - POSTGRES_USER=tourismuser + - POSTGRES_PASSWORD=postgres2 diff --git a/data/replication/slave/Dockerfile b/data/replication/slave/test/Dockerfile-slave similarity index 100% rename from data/replication/slave/Dockerfile rename to data/replication/slave/test/Dockerfile-slave diff --git a/data/replication/slave/test/build-slave.sh b/data/replication/slave/test/build-slave.sh new file mode 100755 index 0000000..cdd2f3a --- /dev/null +++ b/data/replication/slave/test/build-slave.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +docker build -f Dockerfile-slave -t ontopicvkg/odh-db-slave . \ No newline at end of file diff --git a/data/test/Dockerfile b/data/test/Dockerfile index eef48b3..1040608 100644 --- a/data/test/Dockerfile +++ b/data/test/Dockerfile @@ -1,5 +1,6 @@ -FROM postgres:12 - +FROM postgres:12 as base COPY original_schema.sql /docker-entrypoint-initdb.d/01-original_schema.sql -COPY create_triggers_gen.sql /docker-entrypoint-initdb.d/02-triggers_and_tables.sql COPY dump-tourism-201911121025.sql.gz /docker-entrypoint-initdb.d/03-dump.sql.gz + +FROM base as full +COPY create_triggers_gen.sql /docker-entrypoint-initdb.d/02-triggers_and_tables.sql diff --git a/data/test/README.md b/data/test/README.md index 4170b13..2ac8c07 100644 --- a/data/test/README.md +++ b/data/test/README.md @@ -35,7 +35,7 @@ Make sure that the following statement is disabled (`public` needs to be in the In case the schema have changed. - 1. Create a temporary Docker image of PG out the original schema and the dump. **TODO: provide the Dockerfile** + 1. Create a temporary Docker image of PG out the original schema and the dump without triggers. See below for the instructions. 2. Start this image. 3. Generate the script by connecting this container. 4. Stop and delete the container @@ -52,7 +52,14 @@ In case the schema have changed. #### Commands +With triggers: ```sh -docker build -t ontopicvkg/odh-tourism-db . +docker build --target full -t ontopicvkg/odh-tourism-db . docker push ontopicvkg/odh-tourism-db ``` + +Without triggers (original): +```sh +docker build --target base -t ontopicvkg/odh-tourism-db:original . +docker push ontopicvkg/odh-tourism-db:original +``` diff --git a/schema-evolution.md b/schema-evolution.md index 1a23cd0..46fc181 100644 --- a/schema-evolution.md +++ b/schema-evolution.md @@ -8,11 +8,9 @@ This documentation provides recommendations on how to proceed when the schema of ### JSON level #### New key -A new JSON key is first safely ignored. One [can regenerate the corresponding derived table and trigger](#regenerating-a-derived-table-and-a-trigger) for creating the corresponding column. +A new JSON key is first safely ignored. One [can regenerate the corresponding derived table and trigger](#regenerating-a-derived-table-and-a-trigger) for creating the corresponding column. #### Key removed -**TODO: check that it does not prevent anything from working immediately.** - However, one should plan to remove soon the mapping entries using that key. Indeed, they may break once the derived tables and triggers are regenerated, as the corresponding column won't appear anymore. @@ -34,10 +32,10 @@ However, removing an additional column may break the replication. See [the dedic ### Table level #### New table -Given that the subscription has been created for all the tables, it should stop the replication until the corresponding table is added on the slave. **TODO: test it**. +Given that the subscription has been created for all the tables, it should stop the replication until the corresponding table is added on the slave after the first row is inserted. #### Table removed -**TODO: test it**. +It does not seems to complain. ## Actions From 9fa8a80dca4f518208bfc09c88740ba559243a8e Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Tue, 28 Jul 2020 19:21:11 +0200 Subject: [PATCH 02/13] Script updated: credentials are not hardcoded anymore. --- .gitignore | 2 + data/replication/slave/test/Dockerfile-slave | 2 +- data/test/Dockerfile | 2 +- data/test/README.md | 7 +- ...te_derived_tables_and_triggers_from_db.py} | 76 ++++++++++++++++--- 5 files changed, 73 insertions(+), 16 deletions(-) rename scripts/{create_views_and_triggers_from_db.py => create_derived_tables_and_triggers_from_db.py} (90%) mode change 100644 => 100755 diff --git a/.gitignore b/.gitignore index cb81a33..cdf43f9 100644 --- a/.gitignore +++ b/.gitignore @@ -211,3 +211,5 @@ vkg/odh.properties .DS_Store tmp*.* + +*.local.properties diff --git a/data/replication/slave/test/Dockerfile-slave b/data/replication/slave/test/Dockerfile-slave index 134f670..5e72d3e 100644 --- a/data/replication/slave/test/Dockerfile-slave +++ b/data/replication/slave/test/Dockerfile-slave @@ -1,4 +1,4 @@ FROM postgres:12 COPY original_schema.sql /docker-entrypoint-initdb.d/01-schema.sql -COPY 02-triggers.sql /docker-entrypoint-initdb.d/ +COPY triggers_and_derived_tables.sql /docker-entrypoint-initdb.d/02-triggers.sql diff --git a/data/test/Dockerfile b/data/test/Dockerfile index 1040608..0f5373b 100644 --- a/data/test/Dockerfile +++ b/data/test/Dockerfile @@ -3,4 +3,4 @@ COPY original_schema.sql /docker-entrypoint-initdb.d/01-original_schema.sql COPY dump-tourism-201911121025.sql.gz /docker-entrypoint-initdb.d/03-dump.sql.gz FROM base as full -COPY create_triggers_gen.sql /docker-entrypoint-initdb.d/02-triggers_and_tables.sql +COPY triggers_and_derived_tables.sql /docker-entrypoint-initdb.d/02-triggers_and_tables.sql diff --git a/data/test/README.md b/data/test/README.md index 2ac8c07..4e2a08a 100644 --- a/data/test/README.md +++ b/data/test/README.md @@ -35,9 +35,12 @@ Make sure that the following statement is disabled (`public` needs to be in the In case the schema have changed. - 1. Create a temporary Docker image of PG out the original schema and the dump without triggers. See below for the instructions. + 1. Create a temporary Docker image of PG out the original schema and the dump (preferably without triggers). See below for the instructions. 2. Start this image. 3. Generate the script by connecting this container. + ```sh + python3 create_derived_tables_and_triggers_from_db.py -u tourismuser -p postgres2 -h localhost -d tourismuser --port=7777 + ``` 4. Stop and delete the container 5. Remove the temporary image. @@ -48,7 +51,7 @@ In case the schema have changed. * `original_schema.sql` * `dump-tourism-201911121025.sql.gz` (you can use the `gzip` to create it from the SQL file) -* `create_triggers_gen.sql` from the `scripts` directory +* `triggers_and_derived_tables.sql` from the `scripts` directory #### Commands diff --git a/scripts/create_views_and_triggers_from_db.py b/scripts/create_derived_tables_and_triggers_from_db.py old mode 100644 new mode 100755 similarity index 90% rename from scripts/create_views_and_triggers_from_db.py rename to scripts/create_derived_tables_and_triggers_from_db.py index 0f082f5..e43c034 --- a/scripts/create_views_and_triggers_from_db.py +++ b/scripts/create_derived_tables_and_triggers_from_db.py @@ -1,5 +1,9 @@ +#!/usr/bin/python3 + from itertools import chain from typing import List, Any, Dict, TypeVar +import getopt +import sys import psycopg2 @@ -434,14 +438,66 @@ def sql_type_of(value): t = 'varchar' return t +def usage(): + print('create_derived_tables_and_triggers_from_db.py -u -p -h -d --port=') + if __name__ == '__main__': - connection = psycopg2.connect(user="tourismuser", - password="postgres2", - host="127.0.0.1", - port="7777", - database="tourismuser") + try: + opts, args = getopt.getopt(sys.argv[1:], "u:p:h:d:", ["port="]) + except getopt.GetoptError: + usage() + exit(2) + + user = None + password = None + host = None + db = None + port = None + for opt, arg in opts: + if opt == '-u': + user = arg + if opt == '-p': + password = arg + if opt == '-h': + host = arg + if opt == '-d': + db = arg + if opt == '--port': + port = arg + + if user is None: + print("user is required") + usage() + exit(2) + + if password is None: + print("password is required") + usage() + exit(2) + + if host is None: + print("hostname is required") + usage() + exit(2) + + if db is None: + print("database is required") + usage() + exit(2) + + if port is None: + print("port is required") + usage() + exit(2) + + + connection = psycopg2.connect(user=user, + password=password, + host=host, + port=port, + database=db) cursor = connection.cursor() # Print PostgreSQL Connection properties @@ -453,13 +509,12 @@ def sql_type_of(value): # print("You are connected to - ", record, "\n") tables = get_all_table_names(cursor) + tables.sort() # tables = ['accommodationsopen'] - create_view_file = "create_views_gen.sql" - create_trigger_file = "create_triggers_gen.sql" - with open(create_view_file, "w+") as f, \ - open(create_trigger_file, "w+") as ft: + create_trigger_file = "triggers_and_derived_tables.sql" + with open(create_trigger_file, "w+") as ft: for table_name in tables: # DEBUG ONLY # if table_name != 'accommodationroomsopen': @@ -468,9 +523,6 @@ def sql_type_of(value): continue model = extract_model_from_table(cursor, table_name) for table_path, attrs in model.items(): - view = sql_view(table_name, table_path, attrs) - if view is not None: - f.write(view) trigger = sql_trigger(table_name, table_path, attrs) if trigger is not None: ft.write(trigger) From e2829d9aca43037023c930ca5b457bfc0f0e9ef1 Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Wed, 29 Jul 2020 18:20:17 +0200 Subject: [PATCH 03/13] Replication enabled also for test. --- .gitignore | 2 ++ README.md | 6 ++-- .../replication/slave/docker-compose.test.yml | 19 ------------ data/replication/slave/test/Dockerfile-slave | 4 --- data/replication/slave/test/build-slave.sh | 3 -- docker-compose.yml | 20 +++++++++++-- infrastructure/docker/ontop/Dockerfile | 18 ++++++----- infrastructure/docker/ontop/entrypoint.sh | 2 +- .../slave/README.md => replication.md | 5 ---- test/master/04-publication.sql | 3 ++ {data/test => test/master}/Dockerfile | 6 +++- {data/test => test/master}/README.md | 30 +++++++++++-------- test/sql/V2__createdeactivatedreplication.sql | 6 ++++ vkg/odh.docker.properties | 2 +- 14 files changed, 67 insertions(+), 59 deletions(-) delete mode 100644 data/replication/slave/docker-compose.test.yml delete mode 100644 data/replication/slave/test/Dockerfile-slave delete mode 100755 data/replication/slave/test/build-slave.sh rename data/replication/slave/README.md => replication.md (92%) create mode 100644 test/master/04-publication.sql rename {data/test => test/master}/Dockerfile (65%) rename {data/test => test/master}/README.md (67%) create mode 100644 test/sql/V2__createdeactivatedreplication.sql diff --git a/.gitignore b/.gitignore index cdf43f9..6da1499 100644 --- a/.gitignore +++ b/.gitignore @@ -213,3 +213,5 @@ vkg/odh.properties tmp*.* *.local.properties +*.sql.gz +test/master/*.sql diff --git a/README.md b/README.md index 6c847eb..689eeae 100644 --- a/README.md +++ b/README.md @@ -45,6 +45,7 @@ cd odh-vkg/ 3. Visit the SPARQL endpoint * Now we can open the link in the browser and test some SPARQL queries +* Note that synchronisation between the master and the slave takes some time. Until it is finished, some queries may return empty results. #### Docker environment @@ -104,7 +105,7 @@ The SPARQL endpoints do not query directly the production database but slave rea ### Test database image -For building a newer version of the Docker image of the test database out of a fresh dump, please refer to [the dedicated page](data/test/README.md). +For building a newer version of the Docker image of the test database out of a fresh dump, please refer to [the dedicated page](test/master/README.md). This Docker image is published [on Docker Hub](https://hub.docker.com/r/ontopicvkg/odh-tourism-db). @@ -142,6 +143,3 @@ Some examples of possible SPARQL queries can be found in the SPARQL Queries fold ### Schema The schema of the VKG can be visualized [in the dedicated page](sparql_queries/schema.md). - - - diff --git a/data/replication/slave/docker-compose.test.yml b/data/replication/slave/docker-compose.test.yml deleted file mode 100644 index 8bd2798..0000000 --- a/data/replication/slave/docker-compose.test.yml +++ /dev/null @@ -1,19 +0,0 @@ -version: '3.4' - -services: - master: - image: ontopicvkg/odh-tourism-db:original - shm_size: 1g - ports: - - "7779:5432" - environment: - - POSTGRES_USER=tourismuser - - POSTGRES_PASSWORD=postgres2 - slave: - image: ontopicvkg/odh-db-slave - shm_size: 1g - ports: - - "7780:5432" - environment: - - POSTGRES_USER=tourismuser - - POSTGRES_PASSWORD=postgres2 diff --git a/data/replication/slave/test/Dockerfile-slave b/data/replication/slave/test/Dockerfile-slave deleted file mode 100644 index 5e72d3e..0000000 --- a/data/replication/slave/test/Dockerfile-slave +++ /dev/null @@ -1,4 +0,0 @@ -FROM postgres:12 - -COPY original_schema.sql /docker-entrypoint-initdb.d/01-schema.sql -COPY triggers_and_derived_tables.sql /docker-entrypoint-initdb.d/02-triggers.sql diff --git a/data/replication/slave/test/build-slave.sh b/data/replication/slave/test/build-slave.sh deleted file mode 100755 index cdd2f3a..0000000 --- a/data/replication/slave/test/build-slave.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash - -docker build -f Dockerfile-slave -t ontopicvkg/odh-db-slave . \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index ffa40e5..99e8160 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -15,10 +15,20 @@ services: ONTOP_PORTAL_FILE: /opt/ontop/input/odh.portal.toml ONTOP_CORS_ALLOWED_ORIGINS: "*" ONTOP_DEV_MODE: "true" + FLYWAY_PLACEHOLDERS_ORIGINAL_HOST_IP: "master-db" + FLYWAY_PLACEHOLDERS_ORIGINAL_DB: "tourismuser" + FLYWAY_PLACEHOLDERS_ORIGINAL_USER: "vkgreplicate" + FLYWAY_PLACEHOLDERS_ORIGINAL_PASSWORD: "Azerty" + FLYWAY_PLACEHOLDERS_SUBSCRIPTION_NAME: "vkgsubscription_test" + FLYWAY_URL: "jdbc:postgresql://slave-db/tourismuser" + FLYWAY_USER: "tourismuser" + FLYWAY_PASSWORD: "postgres2" + EXTRA_FLYWAY_OPTIONS: "-mixed=true" volumes: - ./vkg:/opt/ontop/input - ./jdbc:/opt/ontop/jdbc - ./src:/opt/ontop/src + entrypoint: ["/wait-for-it.sh","master-db:5432","--timeout=0","--strict", "--", "/entrypoint.sh"] nginx: build: context: ./ @@ -26,11 +36,17 @@ services: env_file: .env ports: - "${SERVER_PORT}:80" - db: - image: ontopicvkg/odh-tourism-db + master-db: + image: ontopicvkg/odh-tourism-db:master + environment: + - POSTGRES_USER=tourismuser + - POSTGRES_PASSWORD=postgres2 + slave-db: + image: postgres:12 shm_size: 1g ports: - "${MAPPED_POSTGRES_PORT}:5432" + command: ["postgres", "-c", "wal_level=logical"] environment: - POSTGRES_USER=tourismuser - POSTGRES_PASSWORD=postgres2 diff --git a/infrastructure/docker/ontop/Dockerfile b/infrastructure/docker/ontop/Dockerfile index b1226dd..7954db2 100644 --- a/infrastructure/docker/ontop/Dockerfile +++ b/infrastructure/docker/ontop/Dockerfile @@ -1,18 +1,22 @@ FROM ontop/ontop-endpoint:4.1-snapshot as base - RUN apk add --update curl && \ rm -rf /var/cache/apk/* +COPY --from=flyway/flyway:6.4.0-alpine /flyway /flyway +RUN ln -s /flyway/flyway /usr/local/bin/flyway +RUN apk add --no-cache postgresql-client +COPY infrastructure/docker/ontop/entrypoint.sh /entrypoint.sh +COPY sql /opt/ontop/sql # Dev FROM base as dev +RUN curl https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh > /wait-for-it.sh +RUN chmod u+x /wait-for-it.sh +# Overrides some scripts +COPY test/sql/* /opt/ontop/sql/ + # Build FROM base as build -COPY --from=flyway/flyway:6.4.0-alpine /flyway /flyway -RUN ln -s /flyway/flyway /usr/local/bin/flyway -RUN apk add --no-cache postgresql-client -COPY infrastructure/docker/ontop/entrypoint.sh /entrypoint.sh -COPY sql /opt/ontop/sql COPY vkg /opt/ontop/input COPY jdbc /opt/ontop/jdbc -ENTRYPOINT /entrypoint.sh +ENTRYPOINT /entrypoint.sh \ No newline at end of file diff --git a/infrastructure/docker/ontop/entrypoint.sh b/infrastructure/docker/ontop/entrypoint.sh index 6f9fa25..f61c686 100755 --- a/infrastructure/docker/ontop/entrypoint.sh +++ b/infrastructure/docker/ontop/entrypoint.sh @@ -4,7 +4,7 @@ set -e set -o pipefail echo "Entrypoint - Run Flyway Migrations" -/usr/local/bin/flyway -X -locations=filesystem:/opt/ontop/sql migrate +/usr/local/bin/flyway -X -locations=filesystem:/opt/ontop/sql ${EXTRA_FLYWAY_OPTIONS} migrate echo "Entrypoint - Starting Ontop Endpoint" /opt/ontop/entrypoint.sh diff --git a/data/replication/slave/README.md b/replication.md similarity index 92% rename from data/replication/slave/README.md rename to replication.md index 4067ca1..e3b152a 100644 --- a/data/replication/slave/README.md +++ b/replication.md @@ -102,8 +102,3 @@ To free storage, you can also drop the underlying slot: ```sql SELECT pg_drop_replication_slot('Your_slotname_name'); ``` - - -## Easy experimenting - -There is [a Docker compose file](./docker-compose.test.yml) available for starting the master and the slave DB. Note that the publication and the subscription are NOT set up. Also their WAL level is `replicated`, not `logical`. \ No newline at end of file diff --git a/test/master/04-publication.sql b/test/master/04-publication.sql new file mode 100644 index 0000000..cc19596 --- /dev/null +++ b/test/master/04-publication.sql @@ -0,0 +1,3 @@ +CREATE ROLE vkgreplicate WITH LOGIN PASSWORD 'Azerty' REPLICATION; +CREATE PUBLICATION vkgpublication FOR ALL TABLES; +GRANT SELECT ON ALL TABLES IN SCHEMA public TO vkgreplicate; \ No newline at end of file diff --git a/data/test/Dockerfile b/test/master/Dockerfile similarity index 65% rename from data/test/Dockerfile rename to test/master/Dockerfile index 0f5373b..b65ebfc 100644 --- a/data/test/Dockerfile +++ b/test/master/Dockerfile @@ -2,5 +2,9 @@ FROM postgres:12 as base COPY original_schema.sql /docker-entrypoint-initdb.d/01-original_schema.sql COPY dump-tourism-201911121025.sql.gz /docker-entrypoint-initdb.d/03-dump.sql.gz -FROM base as full +FROM base as master +CMD ["postgres", "-c", "wal_level=logical"] +COPY 04-publication.sql /docker-entrypoint-initdb.d/ + +FROM base as standalone COPY triggers_and_derived_tables.sql /docker-entrypoint-initdb.d/02-triggers_and_tables.sql diff --git a/data/test/README.md b/test/master/README.md similarity index 67% rename from data/test/README.md rename to test/master/README.md index 4e2a08a..0c99426 100644 --- a/data/test/README.md +++ b/test/master/README.md @@ -1,13 +1,19 @@ -# PostgreSQL Docker test image for Tourism ODH +# PostgreSQL Docker test image for ODH Tourism -Contains the Open Data fragment of the tourism dataset of the Open Data Hub. This Docker image is published [on Docker Hub](https://hub.docker.com/r/ontopicvkg/odh-tourism-db). +Contains the Open Data fragment of the tourism dataset of the Open Data Hub. The various versions of the Docker image are published [on Docker Hub](https://hub.docker.com/r/ontopicvkg/odh-tourism-db). Note this image is intended to be used for development and tests purposes, on your local machine. It does not contain up-to-date data. +It has 2 main versions: + - Standalone: contains the original dump, the triggers and the derived views + - Master: contains the original dump and a publication (for logical replication) has been created. + + ## How to start manually +Standalone version: ```sh -docker run --name odh_db_running -p 7777:5432 -e POSTGRES_USER=tourismuser -e POSTGRES_PASSWORD=postgres2 -d ontopicvkg/odh-tourism-db +docker run --name odh_db_running -p 7777:5432 -e POSTGRES_USER=tourismuser -e POSTGRES_PASSWORD=postgres2 -d ontopicvkg/odh-tourism-db:standalone ``` Note that normally it is started by docker-compose in dev mode. @@ -31,7 +37,7 @@ Make sure that the following statement is disabled (`public` needs to be in the -- SELECT pg_catalog.set_config('search_path', '', false); ``` -### Updating the script generating triggers and trigger tables +### Updating the script generating triggers and trigger tables (for the standalone version) In case the schema have changed. @@ -47,22 +53,22 @@ In case the schema have changed. ### Build the Docker image -#### Files to put in the data directory +#### Files to put in the `test/master` directory * `original_schema.sql` * `dump-tourism-201911121025.sql.gz` (you can use the `gzip` to create it from the SQL file) -* `triggers_and_derived_tables.sql` from the `scripts` directory +* `triggers_and_derived_tables.sql` from the `scripts` directory (for the standalone version) #### Commands -With triggers: +Standalone version: ```sh -docker build --target full -t ontopicvkg/odh-tourism-db . -docker push ontopicvkg/odh-tourism-db +docker build --target standalone -t ontopicvkg/odh-tourism-db:standalone . +docker push ontopicvkg/odh-tourism-db:standalone ``` -Without triggers (original): +Master version: ```sh -docker build --target base -t ontopicvkg/odh-tourism-db:original . -docker push ontopicvkg/odh-tourism-db:original +docker build --target master -t ontopicvkg/odh-tourism-db:master . +docker push ontopicvkg/odh-tourism-db:master ``` diff --git a/test/sql/V2__createdeactivatedreplication.sql b/test/sql/V2__createdeactivatedreplication.sql new file mode 100644 index 0000000..d0ca43b --- /dev/null +++ b/test/sql/V2__createdeactivatedreplication.sql @@ -0,0 +1,6 @@ +-- Simplifies the V2 script (was not working for our regular PG12 set up) +CREATE SUBSCRIPTION ${subscription_name} +CONNECTION 'host=${original_host_ip} dbname=${original_db} user=${original_user} password=${original_password}' +PUBLICATION vkgpublication +WITH (create_slot = true); +ALTER SUBSCRIPTION ${subscription_name} DISABLE; diff --git a/vkg/odh.docker.properties b/vkg/odh.docker.properties index f810652..486692a 100644 --- a/vkg/odh.docker.properties +++ b/vkg/odh.docker.properties @@ -1,4 +1,4 @@ -jdbc.url=jdbc\:postgresql\://db/tourismuser +jdbc.url=jdbc\:postgresql\://slave-db/tourismuser jdbc.driver=org.postgresql.Driver jdbc.user=tourismuser jdbc.password=postgres2 From 2ce19493cee9bed17813a74b6656146ac6b7dc28 Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Wed, 29 Jul 2020 18:31:42 +0200 Subject: [PATCH 04/13] Minor fixes in the README. --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 689eeae..75ec559 100644 --- a/README.md +++ b/README.md @@ -67,7 +67,7 @@ Install [Docker](https://docs.docker.com/install/) (with Docker Compose) locally To start the container on the foreground: ``` -docker-compose pull && docker-compose up +docker-compose pull && docker-compose up --pull ``` The container is run on the foreground and can be stopped by pressing CTRL-C. @@ -75,7 +75,7 @@ The container is run on the foreground and can be stopped by pressing CTRL-C. To start the container on the background: ``` -docker-compose pull && docker-compose up -d +docker-compose pull && docker-compose up --pull -d ``` To stop it: @@ -94,7 +94,7 @@ Current deployments: * Production: https://sparql.opendatahub.bz.it/ #### Database synchronization -The SPARQL endpoints do not query directly the production database but slave read-only instances, which are synchronized with the master database through logical replication. For more details, see [the dedicated page](data/replication/slave/README.md). +The SPARQL endpoints do not query directly the production database but slave read-only instances, which are synchronized with the master database through logical replication. For more details, see [the dedicated page](replication.md). ## Maintenance From 4d9cb9f7c408bc8b4979fd90fad0024c8236f4fc Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Wed, 29 Jul 2020 18:38:45 +0200 Subject: [PATCH 05/13] Replication page updated. --- replication.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/replication.md b/replication.md index e3b152a..79490b8 100644 --- a/replication.md +++ b/replication.md @@ -1,4 +1,4 @@ -# Slave Docker image for the ODH tourism dataset +# Replication tips Inspired by https://blog.raveland.org/post/postgresql_lr_en/ @@ -51,15 +51,11 @@ GRANT SELECT ON ALL TABLES IN SCHEMA public TO vkgreplicate; ## Slave configuration -If the master is a Docker container on the same machine, one must make sure they are on the same Docker network (here `tourism`) than the master container. - -```bash -docker run --name odh_db_slave -p 7778:5432 -e POSTGRES_USER=tourismuser -e POSTGRES_PASSWORD=postgres2 --network tourism -d ontopicvkg/odh-db-slave -``` +If the master is a Docker container on the same machine, one must make sure they are on the same Docker network than the master container. Connect to the shell and open `psql` ```bash -docker exec -it odh_db_slave /bin/sh +docker exec -it my_slave_db /bin/sh psql -U tourismuser ``` From b9d51752baeb0dd5f0bedcbf824b40edc80ea1a8 Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Wed, 29 Jul 2020 18:43:33 +0200 Subject: [PATCH 06/13] Other documentation pages moved to docs. --- README.md | 6 +++--- replication.md => docs/replication.md | 0 schema-evolution.md => docs/schema-evolution.md | 0 test/master/README.md => docs/test-master.md | 0 4 files changed, 3 insertions(+), 3 deletions(-) rename replication.md => docs/replication.md (100%) rename schema-evolution.md => docs/schema-evolution.md (100%) rename test/master/README.md => docs/test-master.md (100%) diff --git a/README.md b/README.md index 75ec559..a9ebe51 100644 --- a/README.md +++ b/README.md @@ -94,18 +94,18 @@ Current deployments: * Production: https://sparql.opendatahub.bz.it/ #### Database synchronization -The SPARQL endpoints do not query directly the production database but slave read-only instances, which are synchronized with the master database through logical replication. For more details, see [the dedicated page](replication.md). +The SPARQL endpoints do not query directly the production database but slave read-only instances, which are synchronized with the master database through logical replication. For more details, see [the dedicated page](docs/replication.md). ## Maintenance ### Schema evolution -[See the dedicated page](schema-evolution.md) +[See the dedicated page](docs/schema-evolution.md) ### Test database image -For building a newer version of the Docker image of the test database out of a fresh dump, please refer to [the dedicated page](test/master/README.md). +For building a newer version of the Docker image of the test database out of a fresh dump, please refer to [the dedicated page](docs/test-master.md). This Docker image is published [on Docker Hub](https://hub.docker.com/r/ontopicvkg/odh-tourism-db). diff --git a/replication.md b/docs/replication.md similarity index 100% rename from replication.md rename to docs/replication.md diff --git a/schema-evolution.md b/docs/schema-evolution.md similarity index 100% rename from schema-evolution.md rename to docs/schema-evolution.md diff --git a/test/master/README.md b/docs/test-master.md similarity index 100% rename from test/master/README.md rename to docs/test-master.md From 623c578441b98f0a143a14428e0e50e123f89d7d Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Thu, 30 Jul 2020 19:59:29 +0200 Subject: [PATCH 07/13] Derived table regeneration scripts can now be generated. --- .env.example | 19 +- README.md | 2 +- docker-compose.yml | 10 +- docs/schema-evolution.md | 20 ++- docs/test-master.md | 3 +- ...ate_derived_tables_and_triggers_from_db.py | 169 +++++++++++++++--- 6 files changed, 174 insertions(+), 49 deletions(-) diff --git a/.env.example b/.env.example index 896dd86..2d1d65f 100644 --- a/.env.example +++ b/.env.example @@ -1,16 +1,19 @@ SERVER_PORT=8080 MAPPED_POSTGRES_PORT=7777 +# Only for development - testing on the local machine +DEV_MASTER_POSTGRES_PORT=7776 + COPY_POSTGRES_HOST= COPY_POSTGRES_DB= COPY_POSTGRES_USER= COPY_POSTGRES_PASSWORD= -FLYWAY_URL= -FLYWAY_USER= -FLYWAY_PASSWORD= -FLYWAY_PLACEHOLDERS_ORIGINAL_HOST_IP= -FLYWAY_PLACEHOLDERS_ORIGINAL_DB= -FLYWAY_PLACEHOLDERS_ORIGINAL_USER= -FLYWAY_PLACEHOLDERS_ORIGINAL_PASSWORD= -FLYWAY_PLACEHOLDERS_SUBSCRIPTION_NAME= +FLYWAY_URL=jdbc:postgresql://slave-db/tourismuser +FLYWAY_USER=tourismuser +FLYWAY_PASSWORD=postgres2 +FLYWAY_PLACEHOLDERS_ORIGINAL_HOST_IP=master-db +FLYWAY_PLACEHOLDERS_ORIGINAL_DB=tourismuser +FLYWAY_PLACEHOLDERS_ORIGINAL_USER=vkgreplicate +FLYWAY_PLACEHOLDERS_ORIGINAL_PASSWORD=Azerty +FLYWAY_PLACEHOLDERS_SUBSCRIPTION_NAME=vkgsubscription_test \ No newline at end of file diff --git a/README.md b/README.md index a9ebe51..03a5c1e 100644 --- a/README.md +++ b/README.md @@ -36,7 +36,7 @@ cd odh-vkg/ ### Local deployment -1. Create the `.env` file in which the SPARQL endpoint port and the PG external port (for debugging purposes) are specified +1. Create the `.env` file in which, amongst all, the SPARQL endpoint port and the PG external port (for debugging purposes) are specified * `cp .env.example .env` diff --git a/docker-compose.yml b/docker-compose.yml index 99e8160..7407959 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -15,14 +15,6 @@ services: ONTOP_PORTAL_FILE: /opt/ontop/input/odh.portal.toml ONTOP_CORS_ALLOWED_ORIGINS: "*" ONTOP_DEV_MODE: "true" - FLYWAY_PLACEHOLDERS_ORIGINAL_HOST_IP: "master-db" - FLYWAY_PLACEHOLDERS_ORIGINAL_DB: "tourismuser" - FLYWAY_PLACEHOLDERS_ORIGINAL_USER: "vkgreplicate" - FLYWAY_PLACEHOLDERS_ORIGINAL_PASSWORD: "Azerty" - FLYWAY_PLACEHOLDERS_SUBSCRIPTION_NAME: "vkgsubscription_test" - FLYWAY_URL: "jdbc:postgresql://slave-db/tourismuser" - FLYWAY_USER: "tourismuser" - FLYWAY_PASSWORD: "postgres2" EXTRA_FLYWAY_OPTIONS: "-mixed=true" volumes: - ./vkg:/opt/ontop/input @@ -41,6 +33,8 @@ services: environment: - POSTGRES_USER=tourismuser - POSTGRES_PASSWORD=postgres2 + ports: + - "${DEV_MASTER_POSTGRES_PORT}:5432" slave-db: image: postgres:12 shm_size: 1g diff --git a/docs/schema-evolution.md b/docs/schema-evolution.md index 46fc181..cd4790e 100644 --- a/docs/schema-evolution.md +++ b/docs/schema-evolution.md @@ -49,19 +49,21 @@ ALTER SUBSCRIPTION ${subscription_name} DISABLE; ALTER SUBSCRIPTION ${subscription_name} ENABLE; ``` -### Regenerating a derived table and a trigger - -**TODO: modify the script for performing all these actions**. +### Regenerating the derived tables of a mirror table This SQL script performs the following actions: -1. It pauses the replication -2. It regenerates the derived table and trigger. -3. It populates the derived table from the mirror table. -4. It resumes the replication (see above). +1. It pauses the replication. +2. It regenerates all the derived tables and triggers of a mirror table. +3. It populates the derived tables from the mirror table. +4. It resumes the replication. Steps: - 1. Generates the script. **TODO: add the command** - 2. [Publish it](#publish-a-migration-script) + 1. Generate the script (change the parameter values) + ```sh + cd scripts + python3 create_derived_tables_and_triggers_from_db.py regenerate -t accommodationsopen -u tourismuser -p postgres2 -h localhost -d tourismuser --port 7776 --subscription=vkgsubscription_test + ``` + 2. [Publish](#publish-a-migration-script) the SQL script with the prefix `regen-`. ### Adding and removing columns in the mirror tables diff --git a/docs/test-master.md b/docs/test-master.md index 0c99426..540df74 100644 --- a/docs/test-master.md +++ b/docs/test-master.md @@ -45,7 +45,8 @@ In case the schema have changed. 2. Start this image. 3. Generate the script by connecting this container. ```sh - python3 create_derived_tables_and_triggers_from_db.py -u tourismuser -p postgres2 -h localhost -d tourismuser --port=7777 + cd scripts + python3 create_derived_tables_and_triggers_from_db.py all -u tourismuser -p postgres2 -h localhost -d tourismuser --port=7777 ``` 4. Stop and delete the container 5. Remove the temporary image. diff --git a/scripts/create_derived_tables_and_triggers_from_db.py b/scripts/create_derived_tables_and_triggers_from_db.py index e43c034..1c5dcdd 100755 --- a/scripts/create_derived_tables_and_triggers_from_db.py +++ b/scripts/create_derived_tables_and_triggers_from_db.py @@ -302,7 +302,6 @@ def sql_view(table_name: str, table_path: TablePath, attr_paths: Dict[AttrPath, ENABLE ALWAYS TRIGGER t_v_{table_name}; """ - array_create_trigger_sql_template = """ DROP TABLE IF EXISTS "{view_name}"; @@ -421,7 +420,6 @@ def sql_trigger(table_name: str, table_path: TablePath, attr_paths: Dict[AttrPat # create_unique_index_sql = nested_create_unique_index_sql_template.format(view_name=view_name,parent_Id=parent_Id) return create_trigger_sql - def cast(col, sample_value): t = sql_type_of(sample_value) return "CAST({} As {})".format(col, t) @@ -439,33 +437,153 @@ def sql_type_of(value): return t def usage(): - print('create_derived_tables_and_triggers_from_db.py -u -p -h -d --port=') + print('create_derived_tables_and_triggers_from_db.py all -u -p -h -d --port=') + print('create_derived_tables_and_triggers_from_db.py regenerate -t -u -p -h -d --port= --subscription=') + +def generate_all(cursor, tables): + create_trigger_file = "triggers_and_derived_tables.sql" + with open(create_trigger_file, "w+") as ft: + for table_name in tables: + generate(cursor, table_name, ft) + +def generate(cursor, table_name, ft): + # DEBUG ONLY + # if table_name != 'accommodationroomsopen': + # continue + if table_name.startswith("v_"): + return + model = extract_model_from_table(cursor, table_name) + for table_path, attrs in model.items(): + trigger = sql_trigger(table_name, table_path, attrs) + if trigger is not None: + ft.write(trigger) + +def pause_resume_subscription(subscription, enable, ft): + action = "ENABLE" if enable else "DISABLE" + + ft.write(pause_resume_subscription_sql_template.format( + subscription_name=subscription, + action=action + )) + +pause_resume_subscription_sql_template = """ +ALTER SUBSCRIPTION {subscription_name} {action}; + +""" + +def regenerate(cursor, source_table, publication): + regen_file = "regen-" + source_table + ".sql" + with open(regen_file, "w+") as ft: + pause_resume_subscription(publication, False, ft) + generate(cursor, source_table, ft) + repopulate(cursor, source_table, ft) + pause_resume_subscription(publication, True, ft) + +simple_repopulate_sql_template=""" +INSERT INTO v_{table_name} +SELECT +{projections} +FROM {table_name}; +""" + +array_repopulate_sql_template = """ +INSERT INTO "{view_name}" + SELECT CAST("data"->>'Id' As varchar) AS "Id", + jsonb_array_elements_text("data" -> '{col_name}') AS "data" + FROM {table_name} + WHERE "data" -> '{col_name}' != 'null'; +""" + +nested_repopulate_sql_template = """ +INSERT INTO "{view_name}" +WITH t ("Id", "data") AS ( + SELECT CAST("data"->>'Id' As varchar) AS "Id", + jsonb_array_elements("data" -> '{col_name}') AS "data" + FROM {table_name} + WHERE "data" -> '{col_name}' != 'null') + SELECT "Id" AS "{parent_Id}", {projections} + FROM t; +""" + +def repopulate(cursor, table_name, ft): + model = extract_model_from_table(cursor, table_name) + for table_path, attr_paths in model.items(): + if table_path.is_empty(): + projections = ",\n".join([ + "{0} AS \"{1}\"".format(cast(c.as_json_path(), v), c.as_column_name()) + for c, v in attr_paths.items() + ]) + sql = simple_repopulate_sql_template.format(table_name=table_name, projections=projections) + ft.write(sql) + elif table_path._path[-1]._path[-1] == '$literal': + real_table_path = TablePath([AttrPath( + tp._path[:-1] if tp._path[-1] == '$literal' else tp._path) + for tp in table_path._path + ]) + view_name = "v_" + table_name + "_" + real_table_path.as_table_name() + col_name = real_table_path.as_table_name() + sql = array_repopulate_sql_template \ + .format(view_name=view_name, table_name=table_name, col_name=col_name) + ft.write(sql) + else: + view_name = "v_{0}_{1}".format(table_name, table_path.as_table_name()) + projections = ",\n".join([ + cast(c.as_json_path(), v) + + " AS \"" + c.as_column_name() + "\"" + for c, v in attr_paths.items() + ]) + col_name = table_path.as_table_name() + parent_Id = table_name + "_Id" + sql = nested_repopulate_sql_template \ + .format(view_name=view_name, table_name=table_name, col_name=col_name, + projections=projections, parent_Id=parent_Id) + ft.write(sql) if __name__ == '__main__': + argv = sys.argv + if len(argv) < 2: + print("command is required") + usage() + exit(2) + + command = argv[1] + try: - opts, args = getopt.getopt(sys.argv[1:], "u:p:h:d:", ["port="]) + opts, args = getopt.getopt(argv[2:], "t:u:p:h:d:", ["port=", "subscription="]) except getopt.GetoptError: usage() exit(2) + if len(opts) == 0: + usage() + exit(2) + + source_table = None user = None password = None host = None db = None port = None + subscription = None for opt, arg in opts: - if opt == '-u': + if opt == '-t': + source_table = arg + elif opt == '-u': user = arg - if opt == '-p': + elif opt == '-p': password = arg - if opt == '-h': + elif opt == '-h': host = arg - if opt == '-d': + elif opt == '-d': db = arg - if opt == '--port': + elif opt == '--port': port = arg + elif opt == '--subscription': + subscription = arg + + print(opts) if user is None: print("user is required") @@ -513,16 +631,23 @@ def usage(): # tables = ['accommodationsopen'] - create_trigger_file = "triggers_and_derived_tables.sql" - with open(create_trigger_file, "w+") as ft: - for table_name in tables: - # DEBUG ONLY - # if table_name != 'accommodationroomsopen': - # continue - if table_name.startswith("v_"): - continue - model = extract_model_from_table(cursor, table_name) - for table_path, attrs in model.items(): - trigger = sql_trigger(table_name, table_path, attrs) - if trigger is not None: - ft.write(trigger) + if command == 'all': + generate_all(cursor, tables) + else: + if source_table is None: + print("source-table is required") + exit(3) + if source_table not in tables: + print("source-table not found") + exit(4) + if source_table.startswith('v_'): + print("The source table must not start with \"v_\"") + exit(5) + if subscription is None: + print("subscription is required for regenerating") + exit(7) + if command == 'regenerate': + regenerate(cursor, source_table, subscription) + else: + print("Unknown command: " + command) + exit(6) From cb84c36fb9dcea7356a39bacf9d74233aa34778b Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Thu, 30 Jul 2020 20:11:36 +0200 Subject: [PATCH 08/13] Comments about an array removal added. --- docs/schema-evolution.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/schema-evolution.md b/docs/schema-evolution.md index cd4790e..c1cf66b 100644 --- a/docs/schema-evolution.md +++ b/docs/schema-evolution.md @@ -14,9 +14,12 @@ A new JSON key is first safely ignored. One [can regenerate the corresponding de However, one should plan to remove soon the mapping entries using that key. Indeed, they may break once the derived tables and triggers are regenerated, as the corresponding column won't appear anymore. +In case of an array, the derived table for the old array is now useless. Please write by hand a SQL script for cleaning the derived table and its trigger. + #### Literal replaced by an Object or an Array Not considered at the moment. To be investigated when the situation appears. + ### Column level #### New column From 667a21ccfe61c1d7a8bd2f6fb649fe287965b0a9 Mon Sep 17 00:00:00 2001 From: skomlaebri Date: Wed, 5 Aug 2020 16:20:26 +0200 Subject: [PATCH 09/13] add mapping Rating --- vkg/odh.obda | 32 +- vkg/odh.ttl | 992 ++++++++++++++++++++++++++------------------------- 2 files changed, 532 insertions(+), 492 deletions(-) diff --git a/vkg/odh.obda b/vkg/odh.obda index 0b40131..6beb40a 100644 --- a/vkg/odh.obda +++ b/vkg/odh.obda @@ -19,8 +19,8 @@ source SELECT "Id" WHERE "AccoTypeId" = 'Camping' mappingId LodgingBusiness -target data:accommodation/{id} a schema:LodgingBusiness ; geo:asWKT "POINT ({longitude} {latitude})"^^geo:wktLiteral ; schema:email {email} ; schema:name {de_name}@de , {it_name}@it , {en_name}@en ; schema:telephone {de_phone} ; schema:faxNumber {de_fax} ; schema:description {it_desc}@it ; schema:alternateName {de_add_name}@de , {en_add_name}@en , {it_add_name}@it . -source SELECT "Id" AS id, "Latitude" AS latitude, "Longitude" AS longitude, "AccoDetail-de-Email" AS email, "AccoDetail-de-Name" AS de_name, "AccoDetail-en-Name" AS en_name, "AccoDetail-it-Name" AS it_name, "AccoDetail-de-Phone" AS de_phone, "AccoDetail-de-Mobile" AS mobile, "AccoDetail-de-Fax" AS de_fax, "AccoDetail-it-Shortdesc" AS it_desc, "AccoDetail-de-NameAddition" AS de_add_name, "AccoDetail-en-NameAddition" as en_add_name, "AccoDetail-it-NameAddition" as it_add_name +target data:accommodation/{id} a schema:LodgingBusiness ; geo:asWKT "POINT ({longitude} {latitude})"^^geo:wktLiteral ; schema:email {email} ; schema:name {de_name}@de , {it_name}@it , {en_name}@en ; schema:telephone {de_phone} ; schema:faxNumber {de_fax} ; schema:description {it_desc}@it ; schema:alternateName {de_add_name}@de , {en_add_name}@en , {it_add_name}@it ; schema:starRating data:category/accomodation/{rating} . +source SELECT "Id" AS id, "Latitude" AS latitude, "Longitude" AS longitude, "AccoDetail-de-Email" AS email, "AccoDetail-de-Name" AS de_name, "AccoDetail-en-Name" AS en_name, "AccoDetail-it-Name" AS it_name, "AccoDetail-de-Phone" AS de_phone, "AccoDetail-de-Mobile" AS mobile, "AccoDetail-de-Fax" AS de_fax, "AccoDetail-it-Shortdesc" AS it_desc, "AccoDetail-de-NameAddition" AS de_add_name, "AccoDetail-en-NameAddition" as en_add_name, "AccoDetail-it-NameAddition" as it_add_name, "AccoCategoryId" as rating FROM "v_accommodationsopen" mappingId Lodging business - geo @@ -29,12 +29,12 @@ source SELECT "Id" AS id, "Latitude" AS latitude, "Longitude" AS longitude, "Al FROM "v_accommodationsopen" mappingId LodgingBusiness - address -target data:address/accommodation/{id} a schema:PostalAddress ; schema:name {de_name}@de , {it_name}@it , {en_name}@en ; schema:alternateName {de_add_name}@de , {en_add_name}@en , {it_add_name}@it ; schema:streetAddress {de_street}@de , {it_street}@it , {en_street}@en ; schema:postalCode {de_zip} ; schema:addressLocality {de_city}@de , {it_city}@it , {en_city}@en . data:accommodation/{id} schema:address data:address/accommodation/{id} ; schema:email {email} ; schema:telephone {de_phone} ; schema:faxNumber {de_fax} . +target data:address/accommodation/{id} a schema:PostalAddress ; schema:name {de_name}@de , {it_name}@it , {en_name}@en ; schema:alternateName {de_add_name}@de , {en_add_name}@en , {it_add_name}@it ; schema:streetAddress {de_street}@de , {it_street}@it , {en_street}@en ; schema:postalCode {de_zip} ; schema:addressLocality {de_city}@de , {it_city}@it , {en_city}@en . data:accommodation/{id} schema:address data:address/accommodation/{id} ; schema:email {email} ; schema:telephone {phone} ; schema:faxNumber {fax} . source SELECT "Id" AS id, "AccoDetail-de-City" AS de_city, "AccoDetail-de-Zip" AS de_zip, "AccoDetail-de-Street" AS de_street, "AccoDetail-it-City" AS it_city, "AccoDetail-it-Street" AS it_street, "AccoDetail-en-City" AS en_city, "AccoDetail-en-Street" AS en_street, - "AccoDetail-de-Name" AS de_name, "AccoDetail-en-Name" AS en_name, "AccoDetail-it-Name" AS it_name, "AccoDetail-de-Phone" AS de_phone, "AccoDetail-de-Mobile" AS mobile, "AccoDetail-de-Fax" AS de_fax, + "AccoDetail-de-Name" AS de_name, "AccoDetail-en-Name" AS en_name, "AccoDetail-it-Name" AS it_name, "AccoDetail-de-Phone" AS phone, "AccoDetail-de-Mobile" AS mobile, "AccoDetail-de-Fax" AS fax, "AccoDetail-de-NameAddition" AS de_add_name, "AccoDetail-en-NameAddition" as en_add_name, "AccoDetail-it-NameAddition" as it_add_name, "AccoDetail-de-Email" AS email FROM "v_accommodationsopen" @@ -273,5 +273,29 @@ target data:menu/gastronomy/{Id} schema:hasMenuItem data:menuitem/apfelstrudel/ source SELECT "Id" FROM public.v_gastronomiesopen WHERE "Detail-de-BaseText" ~ 'Apfelstrudel' + +mappingId MAPID-b0ee5b23372148f6b34b8ea5467519a8 +target data:category/accomodation/{id} a schema:Rating . +source Select "AccoCategoryId" as id FROM "v_accommodationsopen" + +mappingId 1AccomodationRating +target data:category/accomodation/{id} schema:ratingValue "1"^^xsd:integer . +source select "AccoCategoryId" as id FROM "v_accommodationsopen" where "AccoCategoryId" = '1flower' or "AccoCategoryId" = '1star' or "AccoCategoryId" = '1sun' + +mappingId 2AccomodationRating +target data:category/accomodation/{id} schema:ratingValue "2"^^xsd:integer . +source select "AccoCategoryId" as id FROM "v_accommodationsopen" where "AccoCategoryId" = '2flowers' or "AccoCategoryId" = '2stars' or "AccoCategoryId" = '2suns' + +mappingId 3AccomodationRating +target data:category/accomodation/{id} schema:ratingValue "3"^^xsd:integer . +source select "AccoCategoryId" as id FROM "v_accommodationsopen" where "AccoCategoryId" = '3flowers' or "AccoCategoryId" = '3stars' or "AccoCategoryId" = '3suns' + +mappingId 4AccomodationRating +target data:category/accomodation/{id} schema:ratingValue "4"^^xsd:integer . +source select "AccoCategoryId" as id FROM "v_accommodationsopen" where "AccoCategoryId" = '4flowers' or "AccoCategoryId" = '4stars' or "AccoCategoryId" = '4suns' + +mappingId 5AccomodationRating +target data:category/accomodation/{id} schema:ratingValue "5"^^xsd:integer . +source select "AccoCategoryId" as id FROM "v_accommodationsopen" where "AccoCategoryId" = '5flowers' or "AccoCategoryId" = '5stars' or "AccoCategoryId" = '5suns' ]] diff --git a/vkg/odh.ttl b/vkg/odh.ttl index 232130a..1862993 100644 --- a/vkg/odh.ttl +++ b/vkg/odh.ttl @@ -708,17 +708,7 @@ schema:location rdf:type owl:AnnotationProperty ; ### http://schema.org/logo -schema:logo rdf:type owl:AnnotationProperty ; - schema:domainIncludes schema:Brand , - schema:Organization , - schema:Place , - schema:Product , - schema:Service ; - schema:rangeIncludes schema:ImageObject , - schema:URL ; - rdfs:comment "An associated logo."@en ; - rdfs:label "logo"@en ; - rdfs:subPropertyOf schema:image . +schema:logo rdf:type owl:AnnotationProperty . ### http://schema.org/loser @@ -865,13 +855,7 @@ schema:performTime rdf:type owl:AnnotationProperty ; ### http://schema.org/photo -schema:photo rdf:type owl:AnnotationProperty ; - schema:domainIncludes schema:Place ; - schema:rangeIncludes schema:ImageObject , - schema:Photograph ; - rdfs:comment "A photograph of this place."@en ; - rdfs:label "photo"@en ; - rdfs:subPropertyOf schema:image . +schema:photo rdf:type owl:AnnotationProperty . ### http://schema.org/position @@ -1444,6 +1428,11 @@ schema:hasMenuItem rdf:type owl:ObjectProperty ; schema:image rdf:type owl:ObjectProperty . +### http://schema.org/logo +schema:logo rdf:type owl:ObjectProperty ; + rdfs:subPropertyOf schema:image . + + ### http://schema.org/occupancy schema:occupancy rdf:type owl:ObjectProperty ; dc:source ; @@ -1466,6 +1455,21 @@ schema:organizer rdf:type owl:ObjectProperty ; rdfs:label "organizer"@en . +### http://schema.org/photo +schema:photo rdf:type owl:ObjectProperty ; + rdfs:subPropertyOf schema:image . + + +### http://schema.org/starRating +schema:starRating rdf:type owl:ObjectProperty ; + dc:source ; + schema:domainIncludes schema:FoodEstablishment , + schema:LodgingBusiness ; + schema:rangeIncludes schema:Rating ; + rdfs:comment "An official rating for a lodging business or food establishment, e.g. from national associations or standards bodies. Use the author property to indicate the rating organization, e.g. as an Organization with name such as (e.g. HOTREC, DEHOGA, WHR, or Hotelstars)."@en ; + rdfs:label "starRating"@en . + + ### http://schema.org/url schema:url rdf:type owl:ObjectProperty ; schema:domainIncludes schema:Thing ; @@ -1631,6 +1635,15 @@ schema:postalCode rdf:type owl:DatatypeProperty ; rdfs:label "postalCode"@en . +### http://schema.org/ratingValue +schema:ratingValue rdf:type owl:DatatypeProperty ; + schema:domainIncludes schema:Rating ; + schema:rangeIncludes schema:Number , + schema:Text ; + rdfs:comment "The rating for the content.\\n\\nUsage guidelines:\\n\\n* Use values from 0123456789 (Unicode 'DIGIT ZERO' (U+0030) to 'DIGIT NINE' (U+0039)) rather than superficially similiar Unicode symbols.\\n* Use '.' (Unicode 'FULL STOP' (U+002E)) rather than ',' to indicate a decimal point. Avoid using these symbols as a readability separator."@en ; + rdfs:label "ratingValue"@en . + + ### http://schema.org/servesCuisine schema:servesCuisine rdf:type owl:DatatypeProperty ; schema:domainIncludes schema:FoodEstablishment ; @@ -7438,8 +7451,8 @@ schema:Text rdfs:label "Text"@en ; rdfs:comment "Data type: Text."@en . -schema:Time rdfs:comment "A point in time recurring on multiple days in the form hh:mm:ss[Z|(+|-)hh:mm] (see [XML schema for details](http://www.w3.org/TR/xmlschema-2/#time))."@en ; - rdfs:label "Time"@en . +schema:Time rdfs:label "Time"@en ; + rdfs:comment "A point in time recurring on multiple days in the form hh:mm:ss[Z|(+|-)hh:mm] (see [XML schema for details](http://www.w3.org/TR/xmlschema-2/#time))."@en . schema:acceptedOffer schema:rangeIncludes schema:Offer ; @@ -7470,8 +7483,8 @@ schema:accessCode rdfs:label "accessCode"@en ; schema:rangeIncludes schema:Text . -schema:accessMode dc:source ; - schema:category "issue-1110"@en ; +schema:accessMode schema:category "issue-1110"@en ; + dc:source ; schema:domainIncludes schema:CreativeWork ; schema:rangeIncludes schema:Text ; rdfs:label "accessMode"@en ; @@ -7514,8 +7527,8 @@ schema:accessibilityHazard schema:rangeIncludes schema:Text ; schema:accessibilitySummary rdfs:label "accessibilitySummary"@en ; schema:domainIncludes schema:CreativeWork ; - schema:category "issue-1110"@en ; rdfs:comment "A human-readable summary of specific accessibility features or deficiencies, consistent with the other accessibility metadata but expressing subtleties such as \"short descriptions are present but long descriptions will be needed for non-visual users\" or \"short descriptions are present and no long descriptions are needed.\""@en ; + schema:category "issue-1110"@en ; schema:rangeIncludes schema:Text ; dc:source . @@ -7561,16 +7574,16 @@ schema:actionStatus schema:domainIncludes schema:Action ; schema:actor schema:domainIncludes schema:TVSeries , - schema:CreativeWorkSeason , - schema:Movie ; + schema:CreativeWorkSeason ; schema:rangeIncludes schema:Person ; schema:domainIncludes schema:VideoGameSeries , + schema:Movie , schema:Clip ; rdfs:label "actor"@en ; - schema:domainIncludes schema:Event ; + schema:domainIncludes schema:Event , + schema:RadioSeries ; rdfs:comment "An actor, e.g. in tv, radio, movie, video games etc., or in an event. Actors can be associated with individual items or with a series, episode, clip."@en ; - schema:domainIncludes schema:RadioSeries , - schema:Episode , + schema:domainIncludes schema:Episode , schema:VideoGame , schema:MovieSeries , schema:VideoObject . @@ -7580,12 +7593,12 @@ schema:actors schema:domainIncludes schema:Movie , schema:TVSeries , schema:RadioSeries ; rdfs:comment "An actor, e.g. in tv, radio, movie, video games etc. Actors can be associated with individual items or with a series, episode, clip."@en ; - schema:domainIncludes schema:Clip , - schema:VideoObject ; + schema:domainIncludes schema:VideoObject , + schema:VideoGame ; schema:supersededBy schema:actor ; - schema:domainIncludes schema:VideoGame ; + schema:domainIncludes schema:Clip , + schema:VideoGameSeries ; schema:rangeIncludes schema:Person ; - schema:domainIncludes schema:VideoGameSeries ; rdfs:label "actors"@en ; schema:domainIncludes schema:Episode , schema:MovieSeries . @@ -7639,22 +7652,22 @@ schema:afterMedia schema:rangeIncludes schema:URL ; rdfs:comment "A media object representing the circumstances after performing this direction."@en . -schema:agent rdfs:label "agent"@en ; - rdfs:comment "The direct performer or driver of the action (animate or inanimate). e.g. *John* wrote a book."@en ; +schema:agent rdfs:comment "The direct performer or driver of the action (animate or inanimate). e.g. *John* wrote a book."@en ; + rdfs:label "agent"@en ; schema:domainIncludes schema:Action ; schema:rangeIncludes schema:Person , schema:Organization . schema:aggregateRating rdfs:comment "The overall rating, based on a collection of reviews or ratings, of the item."@en ; + schema:domainIncludes schema:Brand ; rdfs:label "aggregateRating"@en ; - schema:domainIncludes schema:Brand , - schema:Service , + schema:domainIncludes schema:Service , schema:Place , - schema:Event ; + schema:Event , + schema:Product ; schema:rangeIncludes schema:AggregateRating ; - schema:domainIncludes schema:Product , - schema:CreativeWork , + schema:domainIncludes schema:CreativeWork , schema:Offer , schema:Organization . @@ -7673,8 +7686,8 @@ schema:album rdfs:comment "A music album."@en ; schema:albumProductionType schema:domainIncludes schema:MusicAlbum ; - rdfs:comment "Classification of the album by it's type of content: soundtrack, live album, studio album, etc."@en ; schema:rangeIncludes schema:MusicAlbumProductionType ; + rdfs:comment "Classification of the album by it's type of content: soundtrack, live album, studio album, etc."@en ; rdfs:label "albumProductionType"@en ; dc:source . @@ -7714,8 +7727,8 @@ schema:alternativeHeadline schema:domainIncludes schema:CreativeWork ; schema:alumni schema:domainIncludes schema:Organization ; rdfs:comment "Alumni of an organization."@en ; - schema:domainIncludes schema:EducationalOrganization ; schema:rangeIncludes schema:Person ; + schema:domainIncludes schema:EducationalOrganization ; schema:inverseOf schema:alumniOf ; rdfs:label "alumni"@en . @@ -7730,18 +7743,18 @@ schema:alumniOf schema:rangeIncludes schema:EducationalOrganization , schema:amenityFeature rdfs:comment "An amenity feature (e.g. a characteristic or service) of the Accommodation. This generic property does not make a statement about whether the feature is included in an offer for the main accommodation or available at extra costs."@en ; rdfs:label "amenityFeature"@en ; - schema:domainIncludes schema:Accommodation ; + schema:domainIncludes schema:Accommodation , + schema:Place ; schema:rangeIncludes schema:LocationFeatureSpecification ; - schema:domainIncludes schema:Place , - schema:LodgingBusiness ; + schema:domainIncludes schema:LodgingBusiness ; dc:source . schema:amount rdfs:label "amount"@en ; - dc:source ; + schema:domainIncludes schema:InvestmentOrDeposit ; schema:category "issue-1698"@en ; - schema:domainIncludes schema:InvestmentOrDeposit , - schema:DatedMoneySpecification ; + dc:source ; + schema:domainIncludes schema:DatedMoneySpecification ; schema:rangeIncludes schema:MonetaryAmount ; schema:domainIncludes schema:LoanOrCredit ; rdfs:comment "The amount of money."@en ; @@ -7782,17 +7795,17 @@ schema:applicationCategory schema:rangeIncludes schema:Text ; schema:domainIncludes schema:SoftwareApplication . -schema:applicationSubCategory rdfs:label "applicationSubCategory"@en ; +schema:applicationSubCategory schema:rangeIncludes schema:URL ; schema:domainIncludes schema:SoftwareApplication ; - schema:rangeIncludes schema:URL ; + rdfs:label "applicationSubCategory"@en ; rdfs:comment "Subcategory of the application, e.g. 'Arcade Game'."@en ; schema:rangeIncludes schema:Text . schema:applicationSuite rdfs:comment "The name of the application suite to which the application belongs (e.g. Excel belongs to Office)."@en ; rdfs:label "applicationSuite"@en ; - schema:domainIncludes schema:SoftwareApplication ; - schema:rangeIncludes schema:Text . + schema:rangeIncludes schema:Text ; + schema:domainIncludes schema:SoftwareApplication . schema:appliesToDeliveryMethod schema:rangeIncludes schema:DeliveryMethod ; @@ -7828,10 +7841,10 @@ schema:arrivalBusStop schema:rangeIncludes schema:BusStop ; rdfs:comment "The stop or station from which the bus arrives."@en . -schema:arrivalGate rdfs:comment "Identifier of the flight's arrival gate."@en ; - rdfs:label "arrivalGate"@en ; - schema:rangeIncludes schema:Text ; - schema:domainIncludes schema:Flight . +schema:arrivalGate rdfs:label "arrivalGate"@en ; + rdfs:comment "Identifier of the flight's arrival gate."@en ; + schema:domainIncludes schema:Flight ; + schema:rangeIncludes schema:Text . schema:arrivalPlatform schema:domainIncludes schema:TrainTrip ; @@ -7842,13 +7855,13 @@ schema:arrivalPlatform schema:domainIncludes schema:TrainTrip ; schema:arrivalStation rdfs:comment "The station where the train trip ends."@en ; rdfs:label "arrivalStation"@en ; - schema:rangeIncludes schema:TrainStation ; - schema:domainIncludes schema:TrainTrip . + schema:domainIncludes schema:TrainTrip ; + schema:rangeIncludes schema:TrainStation . schema:arrivalTerminal schema:rangeIncludes schema:Text ; - schema:domainIncludes schema:Flight ; rdfs:label "arrivalTerminal"@en ; + schema:domainIncludes schema:Flight ; rdfs:comment "Identifier of the flight's arrival terminal."@en . @@ -7859,15 +7872,15 @@ schema:arrivalTime rdfs:label "arrivalTime"@en ; schema:rangeIncludes schema:DateTime . -schema:artEdition schema:domainIncludes schema:VisualArtwork ; - schema:rangeIncludes schema:Text , - schema:Integer ; +schema:artEdition schema:rangeIncludes schema:Text ; + schema:domainIncludes schema:VisualArtwork ; + schema:rangeIncludes schema:Integer ; rdfs:comment "The number of copies when multiple copies of a piece of artwork are produced - e.g. for a limited edition of 20 prints, 'artEdition' refers to the total number of copies (in this example \"20\")."@en ; rdfs:label "artEdition"@en . -schema:artform schema:rangeIncludes schema:Text ; - schema:domainIncludes schema:VisualArtwork ; +schema:artform schema:domainIncludes schema:VisualArtwork ; + schema:rangeIncludes schema:Text ; rdfs:label "artform"@en ; schema:rangeIncludes schema:URL ; rdfs:comment "e.g. Painting, Drawing, Sculpture, Print, Photograph, Assemblage, Collage, etc."@en . @@ -7888,13 +7901,13 @@ schema:articleSection schema:rangeIncludes schema:Text ; schema:artworkSurface schema:rangeIncludes schema:URL ; rdfs:comment "The supporting materials for the artwork, e.g. Canvas, Paper, Wood, Board, etc."@en ; rdfs:label "artworkSurface"@en ; - schema:domainIncludes schema:VisualArtwork ; - schema:rangeIncludes schema:Text . + schema:rangeIncludes schema:Text ; + schema:domainIncludes schema:VisualArtwork . schema:assembly rdfs:label "assembly"@en ; - schema:domainIncludes schema:APIReference ; schema:rangeIncludes schema:Text ; + schema:domainIncludes schema:APIReference ; schema:supersededBy schema:executableLibraryName ; rdfs:comment "Library file name e.g., mscorlib.dll, system.web.dll."@en . @@ -7945,8 +7958,8 @@ schema:audience schema:domainIncludes schema:CreativeWork ; schema:PlayAction ; rdfs:label "audience"@en ; rdfs:comment "An intended audience, i.e. a group for whom something was created."@en ; - schema:domainIncludes schema:LodgingBusiness , - schema:Event . + schema:domainIncludes schema:Event , + schema:LodgingBusiness . schema:audienceType schema:domainIncludes schema:Audience ; @@ -7955,8 +7968,8 @@ schema:audienceType schema:domainIncludes schema:Audience ; schema:rangeIncludes schema:Text . -schema:audio schema:rangeIncludes schema:AudioObject ; - schema:domainIncludes schema:CreativeWork ; +schema:audio schema:domainIncludes schema:CreativeWork ; + schema:rangeIncludes schema:AudioObject ; rdfs:label "audio"@en ; schema:rangeIncludes schema:Clip ; rdfs:comment "An embedded audio object."@en . @@ -7965,15 +7978,15 @@ schema:audio schema:rangeIncludes schema:AudioObject ; schema:authenticator schema:rangeIncludes schema:Organization ; schema:domainIncludes schema:MediaSubscription ; rdfs:label "authenticator"@en ; - rdfs:comment "The Organization responsible for authenticating the user's subscription. For example, many media apps require a cable/satellite provider to authenticate your subscription before playing media."@en ; schema:category "issue-1741"@en ; + rdfs:comment "The Organization responsible for authenticating the user's subscription. For example, many media apps require a cable/satellite provider to authenticate your subscription before playing media."@en ; dc:source . -schema:author schema:rangeIncludes schema:Person ; - schema:domainIncludes schema:CreativeWork ; - schema:rangeIncludes schema:Organization ; - schema:domainIncludes schema:Rating ; +schema:author schema:rangeIncludes schema:Person , + schema:Organization ; + schema:domainIncludes schema:CreativeWork , + schema:Rating ; rdfs:comment "The author of this content or rating. Please note that author is special in that HTML 5 provides a special mechanism for indicating authorship via the rel tag. That is equivalent to this and may be used interchangeably."@en ; rdfs:label "author"@en . @@ -7989,9 +8002,9 @@ schema:availabilityEnds schema:domainIncludes schema:Offer ; schema:rangeIncludes schema:DateTime ; rdfs:comment "The end of the availability of the product or service included in the offer."@en ; schema:domainIncludes schema:Demand ; - schema:rangeIncludes schema:Date ; dc:source ; - schema:rangeIncludes schema:Time ; + schema:rangeIncludes schema:Date , + schema:Time ; schema:category "issue-1741"@en ; schema:domainIncludes schema:ActionAccessSpecification ; rdfs:label "availabilityEnds"@en . @@ -8000,9 +8013,9 @@ schema:availabilityEnds schema:domainIncludes schema:Offer ; schema:availabilityStarts schema:domainIncludes schema:Offer , schema:Demand ; dc:source ; - schema:rangeIncludes schema:Date ; schema:category "issue-1741"@en ; - schema:rangeIncludes schema:DateTime , + schema:rangeIncludes schema:Date , + schema:DateTime , schema:Time ; schema:domainIncludes schema:ActionAccessSpecification ; rdfs:label "availabilityStarts"@en ; @@ -8024,15 +8037,15 @@ schema:availableDeliveryMethod schema:rangeIncludes schema:DeliveryMethod ; schema:availableFrom rdfs:label "availableFrom"@en ; schema:domainIncludes schema:DeliveryEvent ; - rdfs:comment "When the item is available for pickup from the store, locker, etc."@en ; - schema:rangeIncludes schema:DateTime . + schema:rangeIncludes schema:DateTime ; + rdfs:comment "When the item is available for pickup from the store, locker, etc."@en . schema:availableLanguage rdfs:label "availableLanguage"@en ; - schema:domainIncludes schema:LodgingBusiness ; + schema:domainIncludes schema:LodgingBusiness , + schema:ServiceChannel ; schema:rangeIncludes schema:Language ; - schema:domainIncludes schema:ServiceChannel , - schema:TouristAttraction , + schema:domainIncludes schema:TouristAttraction , schema:ContactPoint ; rdfs:comment "A language someone may use with or at the item, service or place. Please use one of the language codes from the [IETF BCP 47 standard](http://tools.ietf.org/html/bcp47). See also [[inLanguage]]"@en ; schema:rangeIncludes schema:Text . @@ -8050,8 +8063,8 @@ schema:availableThrough rdfs:comment "After this date, the item will no longer b schema:rangeIncludes schema:DateTime . -schema:award schema:domainIncludes schema:Person ; - rdfs:label "award"@en ; +schema:award rdfs:label "award"@en ; + schema:domainIncludes schema:Person ; schema:rangeIncludes schema:Text ; schema:domainIncludes schema:CreativeWork , schema:Service , @@ -8065,22 +8078,22 @@ schema:awards schema:domainIncludes schema:Product ; schema:supersededBy schema:award ; rdfs:comment "Awards won by or for this item."@en ; schema:domainIncludes schema:Person , - schema:CreativeWork , - schema:Organization ; + schema:Organization , + schema:CreativeWork ; rdfs:label "awards"@en . schema:baseSalary schema:rangeIncludes schema:PriceSpecification ; schema:domainIncludes schema:JobPosting ; schema:rangeIncludes schema:Number ; - schema:domainIncludes schema:EmployeeRole ; rdfs:comment "The base salary of the job or of an employee in an EmployeeRole."@en ; + schema:domainIncludes schema:EmployeeRole ; schema:rangeIncludes schema:MonetaryAmount ; rdfs:label "baseSalary"@en . -schema:bed dc:source ; - schema:domainIncludes schema:HotelRoom ; +schema:bed schema:domainIncludes schema:HotelRoom ; + dc:source ; schema:rangeIncludes schema:Text ; rdfs:comment """The type of bed or beds included in the accommodation. For the single case of just one bed of a certain type, you use bed directly with a text. If you want to indicate the quantity of a certain kind of bed, use an instance of BedDetails. For more detailed information, use the amenityFeature property."""@en ; @@ -8090,8 +8103,8 @@ schema:bed dc:source . + dc:source ; + rdfs:comment "The frequency in MHz for a particular broadcast."@en . schema:broadcastOfEvent rdfs:label "broadcastOfEvent"@en ; @@ -8299,12 +8312,12 @@ schema:broadcaster rdfs:label "broadcaster"@en ; schema:broker schema:rangeIncludes schema:Organization , schema:Person ; - schema:domainIncludes schema:Reservation , - schema:Order , + schema:domainIncludes schema:Order , + schema:Reservation , schema:Service , schema:Invoice ; - rdfs:comment "An entity that arranges for an exchange between a buyer and a seller. In most cases a broker never acquires or releases ownership of a product or service involved in an exchange. If it is not clear whether an entity is a broker, seller, or buyer, the latter two terms are preferred."@en ; - rdfs:label "broker"@en . + rdfs:label "broker"@en ; + rdfs:comment "An entity that arranges for an exchange between a buyer and a seller. In most cases a broker never acquires or releases ownership of a product or service involved in an exchange. If it is not clear whether an entity is a broker, seller, or buyer, the latter two terms are preferred."@en . schema:browserRequirements schema:domainIncludes schema:WebApplication ; @@ -8325,18 +8338,18 @@ schema:busNumber rdfs:label "busNumber"@en ; rdfs:comment "The unique identifier for the bus."@en . -schema:businessFunction rdfs:label "businessFunction"@en ; - schema:rangeIncludes schema:BusinessFunction ; - schema:domainIncludes schema:Offer ; +schema:businessFunction schema:rangeIncludes schema:BusinessFunction ; + rdfs:label "businessFunction"@en ; + schema:domainIncludes schema:Offer , + schema:TypeAndQuantityNode ; rdfs:comment "The business function (e.g. sell, lease, repair, dispose) of the offer or component of a bundle (TypeAndQuantityNode). The default is http://purl.org/goodrelations/v1#Sell."@en ; - schema:domainIncludes schema:TypeAndQuantityNode , - schema:Demand . + schema:domainIncludes schema:Demand . schema:byArtist schema:rangeIncludes schema:MusicGroup ; - schema:domainIncludes schema:MusicRecording , - schema:MusicAlbum ; + schema:domainIncludes schema:MusicRecording ; rdfs:comment "The artist that performed this album or recording."@en ; + schema:domainIncludes schema:MusicAlbum ; schema:rangeIncludes schema:Person ; rdfs:label "byArtist"@en . @@ -8347,9 +8360,9 @@ schema:calories rdfs:comment "The number of calories."@en ; schema:domainIncludes schema:NutritionInformation . -schema:caption schema:rangeIncludes schema:Text , - schema:MediaObject ; +schema:caption schema:rangeIncludes schema:MediaObject ; rdfs:label "caption"@en ; + schema:rangeIncludes schema:Text ; schema:domainIncludes schema:ImageObject , schema:VideoObject , schema:AudioObject ; @@ -8363,14 +8376,14 @@ schema:carbohydrateContent rdfs:label "carbohydrateContent"@en ; schema:cargoVolume rdfs:label "cargoVolume"@en ; - dc:source ; rdfs:comment "The available volume for cargo or luggage. For automobiles, this is usually the trunk volume.\\n\\nTypical unit code(s): LTR for liters, FTQ for cubic foot/feet\\n\\nNote: You can use [[minValue]] and [[maxValue]] to indicate ranges."@en ; + dc:source ; schema:domainIncludes schema:Vehicle ; schema:rangeIncludes schema:QuantitativeValue . -schema:carrier schema:supersededBy schema:provider ; - schema:domainIncludes schema:Flight ; +schema:carrier schema:domainIncludes schema:Flight ; + schema:supersededBy schema:provider ; schema:rangeIncludes schema:Organization ; rdfs:label "carrier"@en ; schema:domainIncludes schema:ParcelDelivery ; @@ -8403,8 +8416,8 @@ schema:character rdfs:label "character"@en ; schema:domainIncludes schema:CreativeWork . -schema:characterAttribute rdfs:label "characterAttribute"@en ; - schema:domainIncludes schema:VideoGameSeries ; +schema:characterAttribute schema:domainIncludes schema:VideoGameSeries ; + rdfs:label "characterAttribute"@en ; schema:rangeIncludes schema:Thing ; rdfs:comment "A piece of data that represents a particular aspect of a fictional character (skill, power, character points, advantage, disadvantage)."@en ; schema:domainIncludes schema:Game . @@ -8441,8 +8454,8 @@ schema:checkoutTime schema:domainIncludes schema:LodgingBusiness ; schema:childMaxAge schema:rangeIncludes schema:Number ; rdfs:label "childMaxAge"@en ; - schema:domainIncludes schema:ParentAudience ; - rdfs:comment "Maximal age of the child."@en . + rdfs:comment "Maximal age of the child."@en ; + schema:domainIncludes schema:ParentAudience . schema:childMinAge rdfs:comment "Minimal age of the child."@en ; @@ -8464,8 +8477,8 @@ schema:cholesterolContent rdfs:label "cholesterolContent"@en ; schema:circle schema:rangeIncludes schema:Text ; - rdfs:label "circle"@en ; rdfs:comment "A circle is the circular region of a specified radius centered at a specified latitude and longitude. A circle is expressed as a pair followed by a radius in meters."@en ; + rdfs:label "circle"@en ; schema:domainIncludes schema:GeoShape . @@ -8478,10 +8491,10 @@ schema:citation schema:rangeIncludes schema:Text ; schema:claimReviewed rdfs:label "claimReviewed"@en ; schema:rangeIncludes schema:Text ; - rdfs:comment "A short summary of the specific claims reviewed in a ClaimReview."@en ; dc:source ; - schema:domainIncludes schema:ClaimReview ; - schema:category "issue-1061"@en . + rdfs:comment "A short summary of the specific claims reviewed in a ClaimReview."@en ; + schema:category "issue-1061"@en ; + schema:domainIncludes schema:ClaimReview . schema:closes schema:domainIncludes schema:OpeningHoursSpecification ; @@ -8529,8 +8542,8 @@ schema:color schema:domainIncludes schema:Product ; schema:comment rdfs:comment "Comments, typically from users."@en ; - schema:domainIncludes schema:RsvpAction ; rdfs:label "comment"@en ; + schema:domainIncludes schema:RsvpAction ; schema:rangeIncludes schema:Comment ; schema:domainIncludes schema:CreativeWork . @@ -8547,8 +8560,8 @@ schema:commentText schema:rangeIncludes schema:Text ; rdfs:label "commentText"@en . -schema:commentTime schema:rangeIncludes schema:Date , - schema:DateTime ; +schema:commentTime schema:rangeIncludes schema:DateTime , + schema:Date ; schema:domainIncludes schema:UserComments ; rdfs:comment "The time at which the UserComment was made."@en ; rdfs:label "commentTime"@en . @@ -8571,8 +8584,8 @@ schema:contactOption schema:rangeIncludes schema:ContactPointOption ; schema:contactPoint schema:domainIncludes schema:Organization , schema:Person ; - schema:rangeIncludes schema:ContactPoint ; rdfs:label "contactPoint"@en ; + schema:rangeIncludes schema:ContactPoint ; rdfs:comment "A contact point for a person or organization."@en . @@ -8586,27 +8599,27 @@ schema:contactPoints rdfs:comment "A contact point for a person or organization. schema:contactType schema:domainIncludes schema:ContactPoint ; rdfs:comment "A person or organization can have different contact points, for different purposes. For example, a sales contact point, a PR contact point and so on. This property is used to specify the kind of contact point."@en ; - schema:rangeIncludes schema:Text ; - rdfs:label "contactType"@en . + rdfs:label "contactType"@en ; + schema:rangeIncludes schema:Text . schema:containedIn schema:domainIncludes schema:Place ; schema:supersededBy schema:containedInPlace ; rdfs:comment "The basic containment relation between a place and one that contains it."@en ; - schema:rangeIncludes schema:Place ; - rdfs:label "containedIn"@en . + rdfs:label "containedIn"@en ; + schema:rangeIncludes schema:Place . schema:contentRating schema:rangeIncludes schema:Text ; rdfs:comment "Official rating of a piece of content—for example,'MPAA PG-13'."@en ; - schema:rangeIncludes schema:Rating ; schema:domainIncludes schema:CreativeWork ; + schema:rangeIncludes schema:Rating ; rdfs:label "contentRating"@en . schema:contentSize rdfs:comment "File size in (mega/kilo) bytes."@en ; - rdfs:label "contentSize"@en ; schema:domainIncludes schema:MediaObject ; + rdfs:label "contentSize"@en ; schema:rangeIncludes schema:Text . @@ -8643,8 +8656,8 @@ schema:copyrightHolder schema:rangeIncludes schema:Organization , rdfs:comment "The party holding the legal copyright to the CreativeWork."@en . -schema:copyrightYear rdfs:comment "The year during which the claimed copyright for the CreativeWork was first asserted."@en ; - rdfs:label "copyrightYear"@en ; +schema:copyrightYear rdfs:label "copyrightYear"@en ; + rdfs:comment "The year during which the claimed copyright for the CreativeWork was first asserted."@en ; schema:rangeIncludes schema:Number ; schema:domainIncludes schema:CreativeWork . @@ -8655,8 +8668,8 @@ schema:countriesNotSupported schema:domainIncludes schema:SoftwareApplication ; schema:rangeIncludes schema:Text . -schema:countriesSupported schema:rangeIncludes schema:Text ; - rdfs:comment "Countries for which the application is supported. You can also provide the two-letter ISO 3166-1 alpha-2 country code."@en ; +schema:countriesSupported rdfs:comment "Countries for which the application is supported. You can also provide the two-letter ISO 3166-1 alpha-2 country code."@en ; + schema:rangeIncludes schema:Text ; rdfs:label "countriesSupported"@en ; schema:domainIncludes schema:SoftwareApplication . @@ -8670,25 +8683,25 @@ schema:countryOfOrigin rdfs:label "countryOfOrigin"@en ; rdfs:comment "The country of the principal offices of the production company or individual responsible for the movie or program."@en . -schema:courseCode rdfs:label "courseCode"@en ; - rdfs:comment "The identifier for the [[Course]] used by the course [[provider]] (e.g. CS101 or 6.001)."@en ; +schema:courseCode rdfs:comment "The identifier for the [[Course]] used by the course [[provider]] (e.g. CS101 or 6.001)."@en ; + rdfs:label "courseCode"@en ; schema:domainIncludes schema:Course ; schema:rangeIncludes schema:Text . -schema:courseMode rdfs:label "courseMode"@en ; - schema:domainIncludes schema:CourseInstance ; +schema:courseMode schema:domainIncludes schema:CourseInstance ; + rdfs:label "courseMode"@en ; schema:rangeIncludes schema:Text ; rdfs:comment "The medium or means of delivery of the course instance or the mode of study, either as a text label (e.g. \"online\", \"onsite\" or \"blended\"; \"synchronous\" or \"asynchronous\"; \"full-time\" or \"part-time\") or as a URL reference to a term from a controlled vocabulary (e.g. https://ceds.ed.gov/element/001311#Asynchronous )."@en ; schema:rangeIncludes schema:URL . -schema:coursePrerequisites schema:rangeIncludes schema:Text ; - rdfs:label "coursePrerequisites"@en ; - schema:rangeIncludes schema:Course ; +schema:coursePrerequisites rdfs:label "coursePrerequisites"@en ; + schema:rangeIncludes schema:Text , + schema:Course ; schema:domainIncludes schema:Course ; - schema:rangeIncludes schema:AlignmentObject ; - rdfs:comment "Requirements for taking the Course. May be completion of another [[Course]] or a textual description like \"permission of instructor\". Requirements may be a pre-requisite competency, referenced using [[AlignmentObject]]."@en . + rdfs:comment "Requirements for taking the Course. May be completion of another [[Course]] or a textual description like \"permission of instructor\". Requirements may be a pre-requisite competency, referenced using [[AlignmentObject]]."@en ; + schema:rangeIncludes schema:AlignmentObject . schema:coverageEndTime rdfs:label "coverageEndTime"@en ; @@ -8699,8 +8712,8 @@ schema:coverageEndTime rdfs:label "coverageEndTime"@en ; schema:coverageStartTime rdfs:label "coverageStartTime"@en ; schema:domainIncludes schema:LiveBlogPosting ; - rdfs:comment "The time when the live blog will begin covering the Event. Note that coverage may begin before the Event's start time. The LiveBlogPosting may also be created before coverage begins."@en ; - schema:rangeIncludes schema:DateTime . + schema:rangeIncludes schema:DateTime ; + rdfs:comment "The time when the live blog will begin covering the Event. Note that coverage may begin before the Event's start time. The LiveBlogPosting may also be created before coverage begins."@en . schema:creator schema:domainIncludes schema:CreativeWork ; @@ -8712,9 +8725,9 @@ schema:creator schema:domainIncludes schema:CreativeWork ; schema:creditedTo rdfs:label "creditedTo"@en ; - schema:rangeIncludes schema:Person ; dc:source ; - schema:rangeIncludes schema:Organization ; + schema:rangeIncludes schema:Person , + schema:Organization ; rdfs:comment "The group the release is credited to if different than the byArtist. For example, Red and Blue is credited to \"Stefani Germanotta Band\", but by Lady Gaga."@en ; schema:domainIncludes schema:MusicRelease . @@ -8729,8 +8742,8 @@ schema:cssSelector schema:domainIncludes schema:SpeakableSpecification ; schema:currenciesAccepted rdfs:label "currenciesAccepted"@en ; - rdfs:comment "The currency accepted.\\n\\nUse standard formats: [ISO 4217 currency format](http://en.wikipedia.org/wiki/ISO_4217) e.g. \"USD\"; [Ticker symbol](https://en.wikipedia.org/wiki/List_of_cryptocurrencies) for cryptocurrencies e.g. \"BTC\"; well known names for [Local Exchange Tradings Systems](https://en.wikipedia.org/wiki/Local_exchange_trading_system) (LETS) and other currency types e.g. \"Ithaca HOUR\"."@en ; schema:rangeIncludes schema:Text ; + rdfs:comment "The currency accepted.\\n\\nUse standard formats: [ISO 4217 currency format](http://en.wikipedia.org/wiki/ISO_4217) e.g. \"USD\"; [Ticker symbol](https://en.wikipedia.org/wiki/List_of_cryptocurrencies) for cryptocurrencies e.g. \"BTC\"; well known names for [Local Exchange Tradings Systems](https://en.wikipedia.org/wiki/Local_exchange_trading_system) (LETS) and other currency types e.g. \"Ithaca HOUR\"."@en ; schema:domainIncludes schema:LocalBusiness . @@ -8774,8 +8787,8 @@ schema:datasetTimeInterval schema:domainIncludes schema:Dataset ; schema:dateCreated schema:rangeIncludes schema:Date ; rdfs:label "dateCreated"@en ; - schema:domainIncludes schema:DataFeedItem , - schema:CreativeWork ; + schema:domainIncludes schema:CreativeWork , + schema:DataFeedItem ; schema:rangeIncludes schema:DateTime ; rdfs:comment "The date on which the CreativeWork was created or the item was added to a DataFeed."@en . @@ -8803,8 +8816,8 @@ schema:dateModified schema:domainIncludes schema:DataFeedItem ; schema:datePosted schema:domainIncludes schema:JobPosting ; - rdfs:comment "Publication date for the job posting."@en ; rdfs:label "datePosted"@en ; + rdfs:comment "Publication date for the job posting."@en ; schema:rangeIncludes schema:Date . @@ -8815,9 +8828,9 @@ schema:datePublished schema:rangeIncludes schema:Date ; schema:dateRead schema:domainIncludes schema:Message ; - schema:rangeIncludes schema:Date , - schema:DateTime ; + schema:rangeIncludes schema:Date ; rdfs:label "dateRead"@en ; + schema:rangeIncludes schema:DateTime ; rdfs:comment "The date/time at which the message has been read by the recipient if a single recipient exists."@en . @@ -8842,13 +8855,13 @@ schema:dateVehicleFirstRegistered rdfs:comment "The date of the first registrati schema:dateline schema:domainIncludes schema:NewsArticle ; schema:rangeIncludes schema:Text ; - rdfs:label "dateline"@en ; rdfs:comment """A [dateline](https://en.wikipedia.org/wiki/Dateline) is a brief piece of text included in news articles that describes where and when the story was written or filed though the date is often omitted. Sometimes only a placename is provided. Structured representations of dateline-related information can also be expressed more explicitly using [[locationCreated]] (which represents where a work was created e.g. where a news report was written). For location depicted or described in the content, use [[contentLocation]]. Dateline summaries are oriented more towards human readers than towards automated processing, and can vary substantially. Some examples: \"BEIRUT, Lebanon, June 2.\", \"Paris, France\", \"December 19, 2017 11:43AM Reporting from Washington\", \"Beijing/Moscow\", \"QUEZON CITY, Philippines\". - """@en . + """@en ; + rdfs:label "dateline"@en . schema:dayOfWeek schema:domainIncludes schema:OpeningHoursSpecification ; @@ -8878,8 +8891,8 @@ schema:defaultValue schema:rangeIncludes schema:Thing ; schema:deliveryAddress schema:rangeIncludes schema:PostalAddress ; rdfs:label "deliveryAddress"@en ; - rdfs:comment "Destination address."@en ; - schema:domainIncludes schema:ParcelDelivery . + schema:domainIncludes schema:ParcelDelivery ; + rdfs:comment "Destination address."@en . schema:deliveryLeadTime schema:domainIncludes schema:Demand ; @@ -8910,8 +8923,8 @@ schema:departureAirport schema:domainIncludes schema:Flight ; schema:departureBusStop rdfs:comment "The stop or station from which the bus departs."@en ; schema:rangeIncludes schema:BusStop ; rdfs:label "departureBusStop"@en ; - schema:rangeIncludes schema:BusStation ; - schema:domainIncludes schema:BusTrip . + schema:domainIncludes schema:BusTrip ; + schema:rangeIncludes schema:BusStation . schema:departureGate rdfs:label "departureGate"@en ; @@ -8945,18 +8958,18 @@ schema:departureTime rdfs:comment "The expected departure time."@en ; schema:domainIncludes schema:Trip . -schema:dependencies rdfs:comment "Prerequisites needed to fulfill steps in article."@en ; - rdfs:label "dependencies"@en ; +schema:dependencies rdfs:label "dependencies"@en ; + rdfs:comment "Prerequisites needed to fulfill steps in article."@en ; schema:rangeIncludes schema:Text ; schema:domainIncludes schema:TechArticle . schema:depth schema:domainIncludes schema:VisualArtwork ; - schema:rangeIncludes schema:QuantitativeValue ; rdfs:label "depth"@en ; + schema:rangeIncludes schema:QuantitativeValue ; schema:domainIncludes schema:Product ; - schema:rangeIncludes schema:Distance ; - rdfs:comment "The depth of the item."@en . + rdfs:comment "The depth of the item."@en ; + schema:rangeIncludes schema:Distance . schema:device schema:domainIncludes schema:SoftwareApplication ; @@ -8966,8 +8979,8 @@ schema:device schema:domainIncludes schema:SoftwareApplication ; rdfs:comment "Device required to run the application. Used in cases where a specific make/model is required to run the application."@en . -schema:director schema:domainIncludes schema:TVSeries , - schema:Event , +schema:director schema:domainIncludes schema:Event , + schema:TVSeries , schema:RadioSeries , schema:Clip ; schema:rangeIncludes schema:Person ; @@ -8988,12 +9001,12 @@ schema:directors schema:domainIncludes schema:Movie , rdfs:comment "A director of e.g. tv, radio, movie, video games etc. content. Directors can be associated with individual items or with a series, episode, clip."@en ; schema:domainIncludes schema:Clip , schema:VideoObject , - schema:VideoGame , - schema:VideoGameSeries ; + schema:VideoGame ; schema:rangeIncludes schema:Person ; + schema:domainIncludes schema:VideoGameSeries ; rdfs:label "directors"@en ; - schema:domainIncludes schema:Episode , - schema:RadioSeries ; + schema:domainIncludes schema:RadioSeries , + schema:Episode ; schema:supersededBy schema:director . @@ -9042,8 +9055,8 @@ schema:distance schema:rangeIncludes schema:Distance ; schema:distribution schema:rangeIncludes schema:DataDownload ; - rdfs:label "distribution"@en ; schema:domainIncludes schema:Dataset ; + rdfs:label "distribution"@en ; rdfs:comment "A downloadable form of this dataset, at a specific location, in a specific format."@en . @@ -9062,8 +9075,8 @@ schema:downloadUrl rdfs:label "downloadUrl"@en ; schema:downvoteCount schema:rangeIncludes schema:Integer ; rdfs:comment "The number of downvotes this question, answer or comment has received from the community."@en ; - schema:domainIncludes schema:Comment , - schema:Question ; + schema:domainIncludes schema:Question , + schema:Comment ; rdfs:label "downvoteCount"@en . @@ -9071,8 +9084,8 @@ schema:driveWheelConfiguration rdfs:label "driveWheelConfiguration"@en ; dc:source ; schema:rangeIncludes schema:DriveWheelConfigurationValue , schema:Text ; - rdfs:comment "The drive wheel configuration, i.e. which roadwheels will receive torque from the vehicle's engine via the drivetrain."@en ; - schema:domainIncludes schema:Vehicle . + schema:domainIncludes schema:Vehicle ; + rdfs:comment "The drive wheel configuration, i.e. which roadwheels will receive torque from the vehicle's engine via the drivetrain."@en . schema:dropoffLocation schema:rangeIncludes schema:Place ; @@ -9082,8 +9095,8 @@ schema:dropoffLocation schema:rangeIncludes schema:Place ; schema:dropoffTime schema:domainIncludes schema:RentalCarReservation ; - rdfs:label "dropoffTime"@en ; schema:rangeIncludes schema:DateTime ; + rdfs:label "dropoffTime"@en ; rdfs:comment "When a rental car can be dropped off."@en . @@ -9101,8 +9114,8 @@ schema:duringMedia schema:rangeIncludes schema:MediaObject ; schema:editor schema:domainIncludes schema:CreativeWork ; - schema:rangeIncludes schema:Person ; rdfs:label "editor"@en ; + schema:rangeIncludes schema:Person ; rdfs:comment "Specifies the Person who edited the CreativeWork."@en . @@ -9155,18 +9168,18 @@ schema:eligibleDuration rdfs:comment "The duration for which the given offer is schema:eligibleQuantity schema:rangeIncludes schema:QuantitativeValue ; schema:domainIncludes schema:PriceSpecification , - schema:Demand , - schema:Offer ; - rdfs:comment "The interval and unit of measurement of ordering quantities for which the offer or price specification is valid. This allows e.g. specifying that a certain freight charge is valid only for a certain quantity."@en ; - rdfs:label "eligibleQuantity"@en . + schema:Offer , + schema:Demand ; + rdfs:label "eligibleQuantity"@en ; + rdfs:comment "The interval and unit of measurement of ordering quantities for which the offer or price specification is valid. This allows e.g. specifying that a certain freight charge is valid only for a certain quantity."@en . schema:eligibleTransactionVolume schema:rangeIncludes schema:PriceSpecification ; schema:domainIncludes schema:PriceSpecification , schema:Offer ; - rdfs:comment "The transaction volume, in a monetary unit, for which the offer or price specification is valid, e.g. for indicating a minimal purchasing volume, to express free shipping above a certain order volume, or to limit the acceptance of credit cards to purchases to a certain minimal amount."@en ; rdfs:label "eligibleTransactionVolume"@en ; - schema:domainIncludes schema:Demand . + schema:domainIncludes schema:Demand ; + rdfs:comment "The transaction volume, in a monetary unit, for which the offer or price specification is valid, e.g. for indicating a minimal purchasing volume, to express free shipping above a certain order volume, or to limit the acceptance of credit cards to purchases to a certain minimal amount."@en . schema:embedUrl schema:rangeIncludes schema:URL ; @@ -9194,10 +9207,10 @@ schema:employmentType schema:rangeIncludes schema:Text ; rdfs:comment "Type of employment (e.g. full-time, part-time, contract, temporary, seasonal, internship)."@en . -schema:encodesCreativeWork schema:rangeIncludes schema:CreativeWork ; - schema:domainIncludes schema:MediaObject ; - schema:inverseOf schema:encoding ; +schema:encodesCreativeWork schema:domainIncludes schema:MediaObject ; + schema:rangeIncludes schema:CreativeWork ; rdfs:label "encodesCreativeWork"@en ; + schema:inverseOf schema:encoding ; rdfs:comment "The CreativeWork encoded by this media object."@en . @@ -9234,21 +9247,21 @@ schema:encodings schema:domainIncludes schema:CreativeWork ; schema:endTime rdfs:label "endTime"@en ; - schema:domainIncludes schema:Action , - schema:FoodEstablishmentReservation ; - schema:rangeIncludes schema:Time ; + schema:domainIncludes schema:Action ; rdfs:comment "The endTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to end. For actions that span a period of time, when the action was performed. e.g. John wrote a book from January to *December*. For media, including audio and video, it's the time offset of the end of a clip within a larger file.\\n\\nNote that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions."@en ; + schema:rangeIncludes schema:Time ; + schema:domainIncludes schema:FoodEstablishmentReservation ; schema:rangeIncludes schema:DateTime ; schema:domainIncludes schema:MediaObject . schema:episodes rdfs:comment "An episode of a TV/radio series or season."@en ; - schema:domainIncludes schema:VideoGameSeries ; + schema:domainIncludes schema:VideoGameSeries , + schema:TVSeries ; schema:rangeIncludes schema:Episode ; - schema:domainIncludes schema:TVSeries , - schema:CreativeWorkSeason ; schema:supersededBy schema:episode ; - schema:domainIncludes schema:RadioSeries ; + schema:domainIncludes schema:CreativeWorkSeason , + schema:RadioSeries ; rdfs:label "episodes"@en . @@ -9274,9 +9287,9 @@ schema:estimatedCost schema:domainIncludes schema:HowTo ; schema:estimatedFlightDuration schema:domainIncludes schema:Flight ; rdfs:comment "The estimated time the flight will take."@en ; - schema:rangeIncludes schema:Duration ; rdfs:label "estimatedFlightDuration"@en ; - schema:rangeIncludes schema:Text . + schema:rangeIncludes schema:Duration , + schema:Text . schema:estimatedSalary schema:domainIncludes schema:JobPosting ; @@ -9284,8 +9297,8 @@ schema:estimatedSalary schema:domainIncludes schema:JobPosting ; schema:rangeIncludes schema:MonetaryAmountDistribution , schema:MonetaryAmount ; rdfs:comment "An estimated salary for a job posting or occupation, based on a variety of variables including, but not limited to industry, job title, and location. Estimated salaries are often computed by outside organizations rather than the hiring organization, who may not have committed to the estimated value."@en ; - schema:category "issue-1698"@en ; dc:source ; + schema:category "issue-1698"@en ; schema:domainIncludes schema:Occupation ; schema:rangeIncludes schema:Number . @@ -9298,9 +9311,9 @@ schema:eventStatus rdfs:comment "An eventStatus of an event represents its statu schema:events rdfs:comment "Upcoming or past events associated with this place or organization."@en ; schema:supersededBy schema:event ; - schema:domainIncludes schema:Place ; rdfs:label "events"@en ; - schema:domainIncludes schema:Organization ; + schema:domainIncludes schema:Place , + schema:Organization ; schema:rangeIncludes schema:Event . @@ -9308,8 +9321,8 @@ schema:exampleOfWork rdfs:comment "A creative work that this work is an example/ dc:source ; schema:domainIncludes schema:CreativeWork ; schema:rangeIncludes schema:CreativeWork ; - schema:inverseOf schema:workExample ; - rdfs:label "exampleOfWork"@en . + rdfs:label "exampleOfWork"@en ; + schema:inverseOf schema:workExample . schema:executableLibraryName rdfs:label "executableLibraryName"@en ; @@ -9318,8 +9331,8 @@ schema:executableLibraryName rdfs:label "executableLibraryName"@en ; schema:rangeIncludes schema:Text . -schema:exifData schema:domainIncludes schema:ImageObject ; - schema:rangeIncludes schema:PropertyValue ; +schema:exifData schema:rangeIncludes schema:PropertyValue ; + schema:domainIncludes schema:ImageObject ; rdfs:label "exifData"@en ; rdfs:comment "exif data for this object."@en ; schema:rangeIncludes schema:Text . @@ -9342,9 +9355,9 @@ schema:expectedArrivalUntil rdfs:comment "The latest date the package may arrive schema:expectsAcceptanceOf schema:domainIncludes schema:ConsumeAction ; schema:category "issue-1741"@en ; schema:rangeIncludes schema:Offer ; + schema:domainIncludes schema:ActionAccessSpecification , + schema:MediaSubscription ; rdfs:comment "An Offer which must be accepted before the user can perform the Action. For example, the user may need to buy a movie before being able to watch it."@en ; - schema:domainIncludes schema:MediaSubscription , - schema:ActionAccessSpecification ; rdfs:label "expectsAcceptanceOf"@en ; dc:source . @@ -9352,8 +9365,8 @@ schema:expectsAcceptanceOf schema:domainIncludes schema:ConsumeAction ; schema:experienceRequirements schema:domainIncludes schema:JobPosting ; rdfs:comment "Description of skills and experience needed for the position or Occupation."@en ; schema:domainIncludes schema:Occupation ; - rdfs:label "experienceRequirements"@en ; schema:rangeIncludes schema:Text ; + rdfs:label "experienceRequirements"@en ; dc:source ; schema:category "issue-1698"@en . @@ -9393,9 +9406,9 @@ schema:fiberContent schema:rangeIncludes schema:Mass ; schema:fileFormat schema:supersededBy schema:encodingFormat ; - schema:rangeIncludes schema:URL , - schema:Text ; + schema:rangeIncludes schema:URL ; rdfs:label "fileFormat"@en ; + schema:rangeIncludes schema:Text ; rdfs:comment "Media type, typically MIME format (see [IANA site](http://www.iana.org/assignments/media-types/media-types.xhtml)) of the content e.g. application/zip of a SoftwareApplication binary. In cases where a CreativeWork has several media type representations, 'encoding' can be used to indicate each MediaObject alongside particular fileFormat information. Unregistered or niche file formats can be indicated instead via the most appropriate URL, e.g. defining Web page or a Wikipedia entry."@en ; schema:domainIncludes schema:CreativeWork . @@ -9415,9 +9428,9 @@ schema:firstPerformance rdfs:comment "The date and place the work was first perf schema:flightDistance rdfs:label "flightDistance"@en ; rdfs:comment "The distance of the flight."@en ; - schema:rangeIncludes schema:Distance ; - schema:domainIncludes schema:Flight ; - schema:rangeIncludes schema:Text . + schema:rangeIncludes schema:Distance , + schema:Text ; + schema:domainIncludes schema:Flight . schema:floorSize schema:domainIncludes schema:Accommodation ; @@ -9430,8 +9443,8 @@ Typical unit code(s): MTK for square meter, FTK for square foot, or YDK for squa schema:follows schema:rangeIncludes schema:Person ; rdfs:comment "The most generic uni-directional social relation."@en ; - rdfs:label "follows"@en ; - schema:domainIncludes schema:Person . + schema:domainIncludes schema:Person ; + rdfs:label "follows"@en . schema:founder schema:rangeIncludes schema:Person ; @@ -9459,8 +9472,8 @@ schema:foundingLocation schema:rangeIncludes schema:Place ; rdfs:comment "The place where the Organization was founded."@en . -schema:free schema:domainIncludes schema:PublicationEvent ; - rdfs:label "free"@en ; +schema:free rdfs:label "free"@en ; + schema:domainIncludes schema:PublicationEvent ; schema:rangeIncludes schema:Boolean ; schema:supersededBy schema:isAccessibleForFree ; rdfs:comment "A flag to signal that the item, event, or place is accessible for free."@en . @@ -9473,10 +9486,10 @@ schema:fuelConsumption schema:domainIncludes schema:Vehicle ; rdfs:comment "The amount of fuel consumed for traveling a particular distance or temporal duration with the given vehicle (e.g. liters per 100 km).\\n\\n* Note 1: There are unfortunately no standard unit codes for liters per 100 km. Use [[unitText]] to indicate the unit of measurement, e.g. L/100 km.\\n* Note 2: There are two ways of indicating the fuel consumption, [[fuelConsumption]] (e.g. 8 liters per 100 km) and [[fuelEfficiency]] (e.g. 30 miles per gallon). They are reciprocal.\\n* Note 3: Often, the absolute value is useful only when related to driving speed (\"at 80 km/h\") or usage pattern (\"city traffic\"). You can use [[valueReference]] to link the value for the fuel consumption to another value."@en . -schema:fuelEfficiency rdfs:label "fuelEfficiency"@en ; - schema:domainIncludes schema:Vehicle ; - schema:rangeIncludes schema:QuantitativeValue ; +schema:fuelEfficiency schema:domainIncludes schema:Vehicle ; + rdfs:label "fuelEfficiency"@en ; rdfs:comment "The distance traveled per unit of fuel used; most commonly miles per gallon (mpg) or kilometers per liter (km/L).\\n\\n* Note 1: There are unfortunately no standard unit codes for miles per gallon or kilometers per liter. Use [[unitText]] to indicate the unit of measurement, e.g. mpg or km/L.\\n* Note 2: There are two ways of indicating the fuel consumption, [[fuelConsumption]] (e.g. 8 liters per 100 km) and [[fuelEfficiency]] (e.g. 30 miles per gallon). They are reciprocal.\\n* Note 3: Often, the absolute value is useful only when related to driving speed (\"at 80 km/h\") or usage pattern (\"city traffic\"). You can use [[valueReference]] to link the value for the fuel economy to another value."@en ; + schema:rangeIncludes schema:QuantitativeValue ; dc:source . @@ -9517,37 +9530,37 @@ schema:gamePlatform schema:rangeIncludes schema:Text ; schema:domainIncludes schema:VideoGameSeries ; rdfs:comment "The electronic systems used to play video games."@en ; schema:rangeIncludes schema:URL ; - rdfs:label "gamePlatform"@en ; schema:domainIncludes schema:VideoGame ; + rdfs:label "gamePlatform"@en ; schema:rangeIncludes schema:Thing . -schema:gameServer schema:rangeIncludes schema:GameServer ; - schema:domainIncludes schema:VideoGame ; +schema:gameServer schema:domainIncludes schema:VideoGame ; + schema:rangeIncludes schema:GameServer ; schema:inverseOf schema:game ; rdfs:comment "The server on which it is possible to play the game."@en ; rdfs:label "gameServer"@en . -schema:gameTip rdfs:comment "Links to tips, tactics, etc."@en ; - rdfs:label "gameTip"@en ; +schema:gameTip rdfs:label "gameTip"@en ; + rdfs:comment "Links to tips, tactics, etc."@en ; schema:domainIncludes schema:VideoGame ; schema:rangeIncludes schema:CreativeWork . schema:gender rdfs:comment "Gender of the person. While http://schema.org/Male and http://schema.org/Female may be used, text strings are also acceptable for people who do not identify as a binary gender."@en ; - schema:rangeIncludes schema:Text ; schema:domainIncludes schema:Person ; + schema:rangeIncludes schema:Text ; rdfs:label "gender"@en ; schema:rangeIncludes schema:GenderType . schema:genre rdfs:label "genre"@en ; - schema:rangeIncludes schema:Text ; + schema:rangeIncludes schema:Text , + schema:URL ; schema:domainIncludes schema:MusicGroup , - schema:CreativeWork ; - schema:rangeIncludes schema:URL ; - schema:domainIncludes schema:BroadcastChannel ; + schema:CreativeWork , + schema:BroadcastChannel ; rdfs:comment "Genre of the creative work, broadcast channel or group."@en . @@ -9561,8 +9574,8 @@ schema:geoRadius schema:rangeIncludes schema:Text ; rdfs:label "geoRadius"@en ; schema:rangeIncludes schema:Number ; schema:domainIncludes schema:GeoCircle ; - rdfs:comment "Indicates the approximate radius of a GeoCircle (metres unless indicated otherwise via Distance notation)."@en ; - schema:rangeIncludes schema:Distance . + schema:rangeIncludes schema:Distance ; + rdfs:comment "Indicates the approximate radius of a GeoCircle (metres unless indicated otherwise via Distance notation)."@en . schema:geographicArea schema:domainIncludes schema:Audience ; @@ -9634,8 +9647,8 @@ schema:hasMenuSection rdfs:label "hasMenuSection"@en ; schema:rangeIncludes schema:MenuSection . -schema:hasOccupation rdfs:comment "The Person's occupation. For past professions, use Role for expressing dates."@en ; - schema:rangeIncludes schema:Occupation ; +schema:hasOccupation schema:rangeIncludes schema:Occupation ; + rdfs:comment "The Person's occupation. For past professions, use Role for expressing dates."@en ; rdfs:label "hasOccupation"@en ; schema:category "issue-1698"@en ; dc:source ; @@ -9646,8 +9659,8 @@ schema:hasOfferCatalog schema:domainIncludes schema:Service ; schema:rangeIncludes schema:OfferCatalog ; schema:domainIncludes schema:Person ; rdfs:label "hasOfferCatalog"@en ; - rdfs:comment "Indicates an OfferCatalog listing for this Organization, Person, or Service."@en ; - schema:domainIncludes schema:Organization . + schema:domainIncludes schema:Organization ; + rdfs:comment "Indicates an OfferCatalog listing for this Organization, Person, or Service."@en . schema:hasPOS rdfs:label "hasPOS"@en ; @@ -9664,9 +9677,9 @@ schema:headline rdfs:comment "Headline of the article."@en ; schema:height schema:domainIncludes schema:Person , + schema:Product , schema:MediaObject , - schema:VisualArtwork , - schema:Product ; + schema:VisualArtwork ; rdfs:label "height"@en ; schema:rangeIncludes schema:Distance , schema:QuantitativeValue ; @@ -9674,22 +9687,22 @@ schema:height schema:domainIncludes schema:Person , schema:highPrice schema:domainIncludes schema:AggregateOffer ; - rdfs:comment "The highest price of all offers available.\\n\\nUsage guidelines:\\n\\n* Use values from 0123456789 (Unicode 'DIGIT ZERO' (U+0030) to 'DIGIT NINE' (U+0039)) rather than superficially similiar Unicode symbols.\\n* Use '.' (Unicode 'FULL STOP' (U+002E)) rather than ',' to indicate a decimal point. Avoid using these symbols as a readability separator."@en ; schema:rangeIncludes schema:Text ; + rdfs:comment "The highest price of all offers available.\\n\\nUsage guidelines:\\n\\n* Use values from 0123456789 (Unicode 'DIGIT ZERO' (U+0030) to 'DIGIT NINE' (U+0039)) rather than superficially similiar Unicode symbols.\\n* Use '.' (Unicode 'FULL STOP' (U+002E)) rather than ',' to indicate a decimal point. Avoid using these symbols as a readability separator."@en ; rdfs:label "highPrice"@en ; schema:rangeIncludes schema:Number . -schema:hiringOrganization rdfs:comment "Organization offering the job position."@en ; - schema:rangeIncludes schema:Organization ; +schema:hiringOrganization schema:rangeIncludes schema:Organization ; + rdfs:comment "Organization offering the job position."@en ; rdfs:label "hiringOrganization"@en ; schema:domainIncludes schema:JobPosting . schema:honorificPrefix schema:domainIncludes schema:Person ; rdfs:comment "An honorific prefix preceding a Person's name such as Dr/Mrs/Mr."@en ; - rdfs:label "honorificPrefix"@en ; - schema:rangeIncludes schema:Text . + schema:rangeIncludes schema:Text ; + rdfs:label "honorificPrefix"@en . schema:honorificSuffix schema:rangeIncludes schema:Text ; @@ -9707,9 +9720,9 @@ schema:hostingOrganization rdfs:comment "The organization (airline, travelers' c schema:hoursAvailable schema:domainIncludes schema:ContactPoint ; schema:rangeIncludes schema:OpeningHoursSpecification ; rdfs:comment "The hours during which this service or contact is available."@en ; + schema:domainIncludes schema:Service ; rdfs:label "hoursAvailable"@en ; - schema:domainIncludes schema:Service , - schema:LocationFeatureSpecification . + schema:domainIncludes schema:LocationFeatureSpecification . schema:httpMethod rdfs:comment "An HTTP method that specifies the appropriate HTTP method for a request to an HTTP EntryPoint. Values are capitalized strings as used in HTTP."@en ; @@ -9721,8 +9734,8 @@ schema:httpMethod rdfs:comment "An HTTP method that specifies the appropriate HT schema:iataCode schema:domainIncludes schema:Airport ; rdfs:comment "IATA identifier for an airline or airport."@en ; schema:domainIncludes schema:Airline ; - rdfs:label "iataCode"@en ; - schema:rangeIncludes schema:Text . + schema:rangeIncludes schema:Text ; + rdfs:label "iataCode"@en . schema:icaoCode schema:domainIncludes schema:Airport ; @@ -9760,10 +9773,10 @@ schema:inLanguage rdfs:comment "The language of the content or performance or us rdfs:label "inLanguage"@en ; schema:rangeIncludes schema:Text ; schema:domainIncludes schema:CreativeWork , - schema:Event ; + schema:Event , + schema:WriteAction ; schema:rangeIncludes schema:Language ; - schema:domainIncludes schema:WriteAction , - schema:CommunicateAction . + schema:domainIncludes schema:CommunicateAction . schema:inPlaylist rdfs:label "inPlaylist"@en ; @@ -9819,12 +9832,12 @@ schema:industry schema:rangeIncludes schema:Text ; rdfs:comment "The industry associated with the job position."@en . -schema:ineligibleRegion schema:rangeIncludes schema:Text ; - rdfs:label "ineligibleRegion"@en ; - schema:rangeIncludes schema:Place ; - schema:domainIncludes schema:Demand ; - schema:rangeIncludes schema:GeoShape ; - schema:domainIncludes schema:Offer ; +schema:ineligibleRegion rdfs:label "ineligibleRegion"@en ; + schema:rangeIncludes schema:Text , + schema:Place , + schema:GeoShape ; + schema:domainIncludes schema:Demand , + schema:Offer ; rdfs:comment """The ISO 3166-1 (ISO 3166-1 alpha-2) or ISO 3166-2 code, the place, or the GeoShape for the geo-political region(s) for which the offer or delivery charge specification is not valid, e.g. a region where the transaction is not allowed.\\n\\nSee also [[eligibleRegion]]. """@en ; schema:domainIncludes schema:DeliveryChargeSpecification . @@ -9849,9 +9862,9 @@ schema:interactionCount schema:supersededBy schema:interactionStatistic ; schema:interactionService rdfs:label "interactionService"@en ; rdfs:comment "The WebSite or SoftwareApplication where the interactions took place."@en ; - schema:rangeIncludes schema:SoftwareApplication , - schema:WebSite ; - schema:domainIncludes schema:InteractionCounter . + schema:rangeIncludes schema:SoftwareApplication ; + schema:domainIncludes schema:InteractionCounter ; + schema:rangeIncludes schema:WebSite . schema:interactionStatistic rdfs:comment "The number of interactions for the CreativeWork using the WebSite or SoftwareApplication. The most specific child type of InteractionCounter should be used."@en ; @@ -9890,8 +9903,8 @@ schema:inventoryLevel schema:domainIncludes schema:Demand ; schema:isAccessibleForFree schema:domainIncludes schema:CreativeWork ; schema:rangeIncludes schema:Boolean ; - schema:domainIncludes schema:Place , - schema:Event ; + schema:domainIncludes schema:Event , + schema:Place ; rdfs:comment "A flag to signal that the item, event, or place is accessible for free."@en ; rdfs:label "isAccessibleForFree"@en ; schema:domainIncludes schema:PublicationEvent . @@ -9903,9 +9916,9 @@ schema:isAccessoryOrSparePartFor schema:rangeIncludes schema:Product ; schema:domainIncludes schema:Product . -schema:isBasedOn schema:rangeIncludes schema:URL ; - schema:domainIncludes schema:CreativeWork ; - schema:rangeIncludes schema:Product ; +schema:isBasedOn schema:domainIncludes schema:CreativeWork ; + schema:rangeIncludes schema:URL , + schema:Product ; rdfs:label "isBasedOn"@en ; rdfs:comment "A resource from which this work is derived or from which it is a modification or adaption."@en ; schema:rangeIncludes schema:CreativeWork . @@ -9946,8 +9959,8 @@ schema:isLiveBroadcast schema:rangeIncludes schema:Boolean ; schema:isRelatedTo rdfs:comment "A pointer to another, somehow related product (or multiple products)."@en ; schema:rangeIncludes schema:Product ; - schema:domainIncludes schema:Product , - schema:Service ; + schema:domainIncludes schema:Service , + schema:Product ; schema:rangeIncludes schema:Service ; rdfs:label "isRelatedTo"@en . @@ -9967,11 +9980,11 @@ schema:isVariantOf schema:rangeIncludes schema:ProductModel ; schema:isicV4 schema:rangeIncludes schema:Text ; + schema:domainIncludes schema:Place ; rdfs:comment "The International Standard of Industrial Classification of All Economic Activities (ISIC), Revision 4 code for a particular organization, business person, or place."@en ; - schema:domainIncludes schema:Place , - schema:Organization ; - rdfs:label "isicV4"@en ; - schema:domainIncludes schema:Person . + schema:domainIncludes schema:Organization , + schema:Person ; + rdfs:label "isicV4"@en . schema:isrcCode rdfs:comment "The International Standard Recording Code for the recording."@en ; @@ -9984,8 +9997,8 @@ schema:isrcCode rdfs:comment "The International Standard Recording Code for the schema:issuedBy rdfs:label "issuedBy"@en ; schema:domainIncludes schema:Permit ; rdfs:comment "The organization issuing the ticket or permit."@en ; - schema:rangeIncludes schema:Organization ; - schema:domainIncludes schema:Ticket . + schema:domainIncludes schema:Ticket ; + schema:rangeIncludes schema:Organization . schema:issuedThrough rdfs:label "issuedThrough"@en ; @@ -9994,10 +10007,10 @@ schema:issuedThrough rdfs:label "issuedThrough"@en ; schema:rangeIncludes schema:Service . -schema:iswcCode schema:rangeIncludes schema:Text ; - rdfs:label "iswcCode"@en ; - rdfs:comment "The International Standard Musical Work Code for the composition."@en ; +schema:iswcCode rdfs:label "iswcCode"@en ; + schema:rangeIncludes schema:Text ; dc:source ; + rdfs:comment "The International Standard Musical Work Code for the composition."@en ; schema:domainIncludes schema:MusicComposition . @@ -10016,10 +10029,10 @@ schema:itemCondition schema:rangeIncludes schema:OfferItemCondition ; rdfs:comment "A predefined value from OfferItemCondition or a textual description of the condition of the product or service, or the products or services included in the offer."@en . -schema:itemListElement schema:rangeIncludes schema:Text ; +schema:itemListElement schema:rangeIncludes schema:Text , + schema:Thing ; schema:domainIncludes schema:ItemList ; - schema:rangeIncludes schema:Thing , - schema:ListItem ; + schema:rangeIncludes schema:ListItem ; rdfs:label "itemListElement"@en ; rdfs:comment "For itemListElement values, you can use simple strings (e.g. \"Peter\", \"Paul\", \"Mary\"), existing entities, or use ListItem.\\n\\nText values are best if the elements in the list are plain strings. Existing entities are best for a simple, unordered list of existing things in your data. ListItem is used with ordered lists when you want to provide additional context about the element in that list or when the same item might be in different places in different lists.\\n\\nNote: The order of elements in your mark-up is not sufficient for indicating the order or elements. Use ListItem with a 'position' property in such cases."@en . @@ -10032,9 +10045,9 @@ schema:itemListOrder schema:rangeIncludes schema:Text ; schema:itemOffered rdfs:label "itemOffered"@en ; + schema:rangeIncludes schema:Service ; schema:domainIncludes schema:Offer ; - schema:rangeIncludes schema:Service , - schema:Product ; + schema:rangeIncludes schema:Product ; rdfs:comment "The item being offered."@en ; schema:domainIncludes schema:Demand . @@ -10076,8 +10089,8 @@ schema:keywords rdfs:label "keywords"@en ; rdfs:comment "Keywords or tags used to describe this content. Multiple entries in a keywords list are typically delimited by commas."@en . -schema:knownVehicleDamages rdfs:comment "A textual description of known damages, both repaired and unrepaired."@en ; - schema:rangeIncludes schema:Text ; +schema:knownVehicleDamages schema:rangeIncludes schema:Text ; + rdfs:comment "A textual description of known damages, both repaired and unrepaired."@en ; schema:domainIncludes schema:Vehicle ; rdfs:label "knownVehicleDamages"@en ; dc:source . @@ -10122,8 +10135,8 @@ schema:lesserOrEqual rdfs:label "lesserOrEqual"@en ; schema:license schema:rangeIncludes schema:CreativeWork ; rdfs:comment "A license document that applies to this content, typically indicated by URL."@en ; rdfs:label "license"@en ; - schema:domainIncludes schema:CreativeWork ; - schema:rangeIncludes schema:URL . + schema:rangeIncludes schema:URL ; + schema:domainIncludes schema:CreativeWork . schema:line schema:domainIncludes schema:GeoShape ; @@ -10157,11 +10170,22 @@ schema:lodgingUnitType schema:rangeIncludes schema:QualitativeValue ; rdfs:label "lodgingUnitType"@en . -schema:lowPrice schema:domainIncludes schema:AggregateOffer ; - rdfs:comment "The lowest price of all offers available.\\n\\nUsage guidelines:\\n\\n* Use values from 0123456789 (Unicode 'DIGIT ZERO' (U+0030) to 'DIGIT NINE' (U+0039)) rather than superficially similiar Unicode symbols.\\n* Use '.' (Unicode 'FULL STOP' (U+002E)) rather than ',' to indicate a decimal point. Avoid using these symbols as a readability separator."@en ; +schema:logo rdfs:label "logo"@en ; + schema:rangeIncludes schema:URL ; + schema:domainIncludes schema:Product ; + schema:rangeIncludes schema:ImageObject ; + schema:domainIncludes schema:Organization ; + rdfs:comment "An associated logo."@en ; + schema:domainIncludes schema:Service , + schema:Brand , + schema:Place . + + +schema:lowPrice rdfs:comment "The lowest price of all offers available.\\n\\nUsage guidelines:\\n\\n* Use values from 0123456789 (Unicode 'DIGIT ZERO' (U+0030) to 'DIGIT NINE' (U+0039)) rather than superficially similiar Unicode symbols.\\n* Use '.' (Unicode 'FULL STOP' (U+002E)) rather than ',' to indicate a decimal point. Avoid using these symbols as a readability separator."@en ; + schema:domainIncludes schema:AggregateOffer ; rdfs:label "lowPrice"@en ; - schema:rangeIncludes schema:Text , - schema:Number . + schema:rangeIncludes schema:Number , + schema:Text . schema:lyricist rdfs:comment "The person who wrote the words."@en ; @@ -10195,9 +10219,9 @@ schema:mainEntityOfPage rdfs:label "mainEntityOfPage"@en ; schema:makesOffer schema:inverseOf schema:offeredBy ; rdfs:comment "A pointer to products or services offered by the organization or person."@en ; rdfs:label "makesOffer"@en ; + schema:domainIncludes schema:Organization ; schema:rangeIncludes schema:Offer ; - schema:domainIncludes schema:Organization , - schema:Person . + schema:domainIncludes schema:Person . schema:manufacturer schema:domainIncludes schema:Product ; @@ -10207,10 +10231,10 @@ schema:manufacturer schema:domainIncludes schema:Product ; schema:map schema:supersededBy schema:hasMap ; - schema:domainIncludes schema:Place ; schema:rangeIncludes schema:URL ; - rdfs:label "map"@en ; - rdfs:comment "A URL to a map of the place."@en . + schema:domainIncludes schema:Place ; + rdfs:comment "A URL to a map of the place."@en ; + rdfs:label "map"@en . schema:mapType rdfs:label "mapType"@en ; @@ -10247,10 +10271,10 @@ schema:mealService schema:rangeIncludes schema:Text ; schema:median rdfs:label "median"@en ; rdfs:comment "The median value."@en ; - schema:rangeIncludes schema:Number ; dc:source ; - schema:domainIncludes schema:QuantitativeValueDistribution ; - schema:category "issue-1698"@en . + schema:rangeIncludes schema:Number ; + schema:category "issue-1698"@en ; + schema:domainIncludes schema:QuantitativeValueDistribution . schema:member schema:rangeIncludes schema:Person , @@ -10262,8 +10286,8 @@ schema:member schema:rangeIncludes schema:Person , schema:inverseOf schema:memberOf . -schema:members schema:supersededBy schema:member ; - schema:domainIncludes schema:ProgramMembership ; +schema:members schema:domainIncludes schema:ProgramMembership ; + schema:supersededBy schema:member ; rdfs:label "members"@en ; schema:rangeIncludes schema:Person , schema:Organization ; @@ -10280,8 +10304,8 @@ schema:membershipNumber rdfs:comment "A unique identifier for the membership."@e schema:memoryRequirements schema:domainIncludes schema:SoftwareApplication ; schema:rangeIncludes schema:URL ; rdfs:label "memoryRequirements"@en ; - schema:rangeIncludes schema:Text ; - rdfs:comment "Minimum memory requirements."@en . + rdfs:comment "Minimum memory requirements."@en ; + schema:rangeIncludes schema:Text . schema:mentions schema:rangeIncludes schema:Thing ; @@ -10300,8 +10324,8 @@ schema:menu schema:rangeIncludes schema:URL ; schema:menuAddOn schema:domainIncludes schema:MenuItem ; - rdfs:label "menuAddOn"@en ; dc:source ; + rdfs:label "menuAddOn"@en ; schema:rangeIncludes schema:MenuSection ; schema:category "issue-1541"@en ; schema:rangeIncludes schema:MenuItem ; @@ -10311,9 +10335,9 @@ schema:menuAddOn schema:domainIncludes schema:MenuItem ; schema:merchant rdfs:comment "'merchant' is an out-dated term for 'seller'."@en ; rdfs:label "merchant"@en ; schema:domainIncludes schema:Order ; - schema:rangeIncludes schema:Organization , - schema:Person ; - schema:supersededBy schema:seller . + schema:rangeIncludes schema:Organization ; + schema:supersededBy schema:seller ; + schema:rangeIncludes schema:Person . schema:messageAttachment rdfs:comment "A CreativeWork attached to the message."@en ; @@ -10338,15 +10362,15 @@ schema:minPrice rdfs:label "minPrice"@en ; schema:minimumPaymentDue rdfs:comment "The minimum payment required at this time."@en ; schema:rangeIncludes schema:PriceSpecification ; rdfs:label "minimumPaymentDue"@en ; - schema:rangeIncludes schema:MonetaryAmount ; - schema:domainIncludes schema:Invoice . + schema:domainIncludes schema:Invoice ; + schema:rangeIncludes schema:MonetaryAmount . schema:model schema:rangeIncludes schema:ProductModel ; rdfs:label "model"@en ; rdfs:comment "The model of the product. Use with the URL of a ProductModel or a textual representation of the model identifier. The URL of the ProductModel can be from an external source. It is recommended to additionally provide strong product identifiers via the gtin8/gtin13/gtin14 and mpn properties."@en ; - schema:rangeIncludes schema:Text ; - schema:domainIncludes schema:Product . + schema:domainIncludes schema:Product ; + schema:rangeIncludes schema:Text . schema:modifiedTime schema:domainIncludes schema:Reservation ; @@ -10364,8 +10388,8 @@ schema:mpn schema:domainIncludes schema:Product ; schema:multipleValues schema:rangeIncludes schema:Boolean ; - schema:domainIncludes schema:PropertyValueSpecification ; rdfs:comment "Whether multiple values are allowed for the property. Default is false."@en ; + schema:domainIncludes schema:PropertyValueSpecification ; rdfs:label "multipleValues"@en . @@ -10399,8 +10423,8 @@ schema:musicCompositionForm dc:source ; - rdfs:label "numberOfAirbags"@en . + rdfs:label "numberOfAirbags"@en ; + dc:source . -schema:numberOfAxles rdfs:comment "The number of axles.\\n\\nTypical unit code(s): C62"@en ; - schema:rangeIncludes schema:QuantitativeValue ; +schema:numberOfAxles schema:rangeIncludes schema:QuantitativeValue ; + rdfs:comment "The number of axles.\\n\\nTypical unit code(s): C62"@en ; dc:source ; schema:rangeIncludes schema:Number ; rdfs:label "numberOfAxles"@en ; @@ -10598,8 +10622,8 @@ schema:numberedPosition rdfs:label "numberedPosition"@en ; schema:nutrition schema:domainIncludes schema:MenuItem ; rdfs:label "nutrition"@en ; schema:domainIncludes schema:Recipe ; - rdfs:comment "Nutrition information about the recipe or menu item."@en ; - schema:rangeIncludes schema:NutritionInformation . + schema:rangeIncludes schema:NutritionInformation ; + rdfs:comment "Nutrition information about the recipe or menu item."@en . schema:occupationLocation rdfs:label "occupationLocation"@en ; @@ -10610,8 +10634,8 @@ schema:occupationLocation rdfs:label "occupationLocation"@en ; rdfs:comment " The region/country for which this occupational description is appropriate. Note that educational requirements and qualifications can vary between jurisdictions."@en . -schema:occupationalCategory schema:domainIncludes schema:Occupation , - schema:JobPosting ; +schema:occupationalCategory schema:domainIncludes schema:JobPosting , + schema:Occupation ; rdfs:label "occupationalCategory"@en ; schema:rangeIncludes schema:Text ; rdfs:comment """A category describing the job, preferably using a term from a taxonomy such as [BLS O*NET-SOC](http://www.onetcenter.org/taxonomy.html), [ISCO-08](https://www.ilo.org/public/english/bureau/stat/isco/isco08/) or similar, with the property repeated for each applicable value. Ideally the taxonomy should be identified, and both the textual label and formal code for the category should be provided.\\n @@ -10648,8 +10672,8 @@ schema:offers schema:domainIncludes schema:AggregateOffer ; schema:openingHours schema:domainIncludes schema:LocalBusiness , schema:CivicStructure ; - rdfs:comment "The general opening hours for a business. Opening hours can be specified as a weekly time range, starting with days, then times per day. Multiple days can be listed with commas ',' separating each day. Day or time ranges are specified using a hyphen '-'.\\n\\n* Days are specified using the following two-letter combinations: ```Mo```, ```Tu```, ```We```, ```Th```, ```Fr```, ```Sa```, ```Su```.\\n* Times are specified using 24:00 time. For example, 3pm is specified as ```15:00```. \\n* Here is an example: <time itemprop=\"openingHours\" datetime="Tu,Th 16:00-20:00">Tuesdays and Thursdays 4-8pm</time>.\\n* If a business is open 7 days a week, then it can be specified as <time itemprop="openingHours" datetime="Mo-Su">Monday through Sunday, all day</time>."@en ; schema:rangeIncludes schema:Text ; + rdfs:comment "The general opening hours for a business. Opening hours can be specified as a weekly time range, starting with days, then times per day. Multiple days can be listed with commas ',' separating each day. Day or time ranges are specified using a hyphen '-'.\\n\\n* Days are specified using the following two-letter combinations: ```Mo```, ```Tu```, ```We```, ```Th```, ```Fr```, ```Sa```, ```Su```.\\n* Times are specified using 24:00 time. For example, 3pm is specified as ```15:00```. \\n* Here is an example: <time itemprop=\"openingHours\" datetime="Tu,Th 16:00-20:00">Tuesdays and Thursdays 4-8pm</time>.\\n* If a business is open 7 days a week, then it can be specified as <time itemprop="openingHours" datetime="Mo-Su">Monday through Sunday, all day</time>."@en ; rdfs:label "openingHours"@en . @@ -10671,8 +10695,8 @@ schema:operatingSystem schema:rangeIncludes schema:Text ; rdfs:comment "Operating systems supported (Windows 7, OSX 10.6, Android 1.6)."@en . -schema:orderDate rdfs:comment "Date order was placed."@en ; - schema:rangeIncludes schema:DateTime ; +schema:orderDate schema:rangeIncludes schema:DateTime ; + rdfs:comment "Date order was placed."@en ; rdfs:label "orderDate"@en ; schema:domainIncludes schema:Order ; schema:rangeIncludes schema:Date . @@ -10686,13 +10710,13 @@ schema:orderDelivery schema:domainIncludes schema:Order ; schema:orderItemNumber schema:domainIncludes schema:OrderItem ; - schema:rangeIncludes schema:Text ; rdfs:comment "The identifier of the order item."@en ; + schema:rangeIncludes schema:Text ; rdfs:label "orderItemNumber"@en . -schema:orderItemStatus schema:rangeIncludes schema:OrderStatus ; - rdfs:label "orderItemStatus"@en ; +schema:orderItemStatus rdfs:label "orderItemStatus"@en ; + schema:rangeIncludes schema:OrderStatus ; schema:domainIncludes schema:OrderItem ; rdfs:comment "The current status of the order item."@en . @@ -10713,8 +10737,8 @@ schema:orderedItem schema:rangeIncludes schema:OrderItem , schema:Service , schema:Product ; rdfs:label "orderedItem"@en ; - schema:domainIncludes schema:Order , - schema:OrderItem ; + schema:domainIncludes schema:OrderItem , + schema:Order ; rdfs:comment "The item ordered."@en . @@ -10773,8 +10797,8 @@ schema:pagination dc:source . -schema:percentile25 schema:rangeIncludes schema:Number ; - dc:source ; +schema:percentile25 dc:source ; + schema:rangeIncludes schema:Number ; schema:category "issue-1698"@en ; rdfs:label "percentile25"@en ; rdfs:comment "The 25th percentile value."@en ; @@ -10912,8 +10936,8 @@ schema:percentile75 rdfs:comment "The 75th percentile value."@en ; schema:percentile90 dc:source ; - schema:domainIncludes schema:QuantitativeValueDistribution ; schema:category "issue-1698"@en ; + schema:domainIncludes schema:QuantitativeValueDistribution ; rdfs:label "percentile90"@en ; rdfs:comment "The 90th percentile value."@en ; schema:rangeIncludes schema:Number . @@ -10941,8 +10965,8 @@ schema:performers rdfs:label "performers"@en ; schema:permissionType schema:domainIncludes schema:DigitalDocumentPermission ; - rdfs:label "permissionType"@en ; rdfs:comment "The type of permission granted the person, organization, or audience."@en ; + rdfs:label "permissionType"@en ; schema:rangeIncludes schema:DigitalDocumentPermissionType . @@ -10969,16 +10993,23 @@ schema:petsAllowed schema:domainIncludes schema:Accommodation ; rdfs:comment "Indicates whether pets are allowed to enter the accommodation or lodging business. More detailed information can be put in a text value."@en ; schema:rangeIncludes schema:Text , schema:Boolean ; - rdfs:label "petsAllowed"@en ; schema:domainIncludes schema:LodgingBusiness ; + rdfs:label "petsAllowed"@en ; dc:source . -schema:photos rdfs:label "photos"@en ; - schema:domainIncludes schema:Place ; - schema:rangeIncludes schema:Photograph , - schema:ImageObject ; +schema:photo schema:rangeIncludes schema:Photograph ; + schema:domainIncludes schema:Place ; + rdfs:comment "A photograph of this place."@en ; + schema:rangeIncludes schema:ImageObject ; + rdfs:label "photo"@en . + + +schema:photos schema:domainIncludes schema:Place ; + rdfs:label "photos"@en ; + schema:rangeIncludes schema:Photograph ; rdfs:comment "Photographs of this place."@en ; + schema:rangeIncludes schema:ImageObject ; schema:supersededBy schema:photo . @@ -11041,8 +11072,8 @@ schema:predecessorOf schema:rangeIncludes schema:ProductModel ; schema:prepTime schema:domainIncludes schema:HowToDirection ; schema:rangeIncludes schema:Duration ; - rdfs:comment "The length of time it takes to prepare the items to be used in instructions or a direction, in [ISO 8601 duration format](http://en.wikipedia.org/wiki/ISO_8601)."@en ; schema:domainIncludes schema:HowTo ; + rdfs:comment "The length of time it takes to prepare the items to be used in instructions or a direction, in [ISO 8601 duration format](http://en.wikipedia.org/wiki/ISO_8601)."@en ; rdfs:label "prepTime"@en . @@ -11064,8 +11095,8 @@ schema:price rdfs:comment """The offer price of a product, or of a price compone schema:TradeAction , schema:Offer ; rdfs:label "price"@en ; - schema:rangeIncludes schema:Number , - schema:Text . + schema:rangeIncludes schema:Text , + schema:Number . schema:priceComponent dc:source ; @@ -11075,10 +11106,10 @@ schema:priceComponent dc:source ; - rdfs:comment "The date of production of the item, e.g. vehicle."@en ; +schema:productionDate rdfs:comment "The date of production of the item, e.g. vehicle."@en ; + dc:source ; schema:domainIncludes schema:Product , schema:Vehicle ; rdfs:label "productionDate"@en ; schema:rangeIncludes schema:Date . -schema:proficiencyLevel schema:rangeIncludes schema:Text ; - rdfs:comment "Proficiency needed for this content; expected values: 'Beginner', 'Expert'."@en ; +schema:proficiencyLevel rdfs:comment "Proficiency needed for this content; expected values: 'Beginner', 'Expert'."@en ; + schema:rangeIncludes schema:Text ; schema:domainIncludes schema:TechArticle ; rdfs:label "proficiencyLevel"@en . @@ -11232,8 +11263,8 @@ schema:propertyID schema:rangeIncludes schema:URL ; a URL indicating the type of the property, either pointing to an external vocabulary, or a Web resource that describes the property (e.g. a glossary entry). Standards bodies should promote a standard prefix for the identifiers of properties from their standards."""@en ; schema:rangeIncludes schema:Text ; - rdfs:label "propertyID"@en ; - schema:domainIncludes schema:PropertyValue . + schema:domainIncludes schema:PropertyValue ; + rdfs:label "propertyID"@en . schema:proteinContent schema:domainIncludes schema:NutritionInformation ; @@ -11243,9 +11274,9 @@ schema:proteinContent schema:domainIncludes schema:NutritionInformation ; schema:provider rdfs:comment "The service provider, service operator, or service performer; the goods producer. Another party (a seller) may offer those services or goods on behalf of the provider. A provider may also serve as the seller."@en ; - schema:domainIncludes schema:Trip , - schema:Invoice , - schema:ParcelDelivery ; + schema:domainIncludes schema:ParcelDelivery , + schema:Trip , + schema:Invoice ; rdfs:label "provider"@en ; schema:domainIncludes schema:Reservation ; schema:rangeIncludes schema:Person ; @@ -11310,9 +11341,9 @@ While such policies are most typically expressed in natural language, sometimes schema:domainIncludes schema:Person . -schema:purchaseDate schema:domainIncludes schema:Product , - schema:Vehicle ; +schema:purchaseDate schema:domainIncludes schema:Product ; rdfs:label "purchaseDate"@en ; + schema:domainIncludes schema:Vehicle ; rdfs:comment "The date the item e.g. vehicle was purchased by the current owner."@en ; schema:rangeIncludes schema:Date ; dc:source . @@ -11340,13 +11371,6 @@ schema:ratingCount rdfs:comment "The count of total number of ratings."@en ; rdfs:label "ratingCount"@en . -schema:ratingValue schema:rangeIncludes schema:Text ; - rdfs:comment "The rating for the content.\\n\\nUsage guidelines:\\n\\n* Use values from 0123456789 (Unicode 'DIGIT ZERO' (U+0030) to 'DIGIT NINE' (U+0039)) rather than superficially similiar Unicode symbols.\\n* Use '.' (Unicode 'FULL STOP' (U+002E)) rather than ',' to indicate a decimal point. Avoid using these symbols as a readability separator."@en ; - schema:domainIncludes schema:Rating ; - schema:rangeIncludes schema:Number ; - rdfs:label "ratingValue"@en . - - schema:readonlyValue rdfs:label "readonlyValue"@en ; schema:rangeIncludes schema:Boolean ; schema:domainIncludes schema:PropertyValueSpecification ; @@ -11366,10 +11390,10 @@ schema:recipeCuisine schema:domainIncludes schema:Recipe ; schema:recordLabel rdfs:comment "The label that issued the release."@en ; - schema:domainIncludes schema:MusicRelease ; dc:source ; - rdfs:label "recordLabel"@en ; - schema:rangeIncludes schema:Organization . + schema:domainIncludes schema:MusicRelease ; + schema:rangeIncludes schema:Organization ; + rdfs:label "recordLabel"@en . schema:recordedAs dc:source ; @@ -11416,8 +11440,8 @@ schema:referencesOrder rdfs:comment "The Order(s) related to this Invoice. One o schema:rangeIncludes schema:Order . -schema:regionsAllowed schema:domainIncludes schema:MediaObject ; - schema:rangeIncludes schema:Place ; +schema:regionsAllowed schema:rangeIncludes schema:Place ; + schema:domainIncludes schema:MediaObject ; rdfs:comment "The regions where the media is allowed. If not specified, then it's assumed to be allowed everywhere. Specify the countries in [ISO 3166 format](http://en.wikipedia.org/wiki/ISO_3166)."@en ; rdfs:label "regionsAllowed"@en . @@ -11448,9 +11472,9 @@ schema:releaseNotes schema:rangeIncludes schema:URL ; schema:releaseOf schema:domainIncludes schema:MusicRelease ; - schema:rangeIncludes schema:MusicAlbum ; dc:source ; rdfs:comment "The album this is a release of."@en ; + schema:rangeIncludes schema:MusicAlbum ; schema:inverseOf schema:albumRelease ; rdfs:label "releaseOf"@en . @@ -11463,9 +11487,9 @@ schema:releasedEvent schema:domainIncludes schema:CreativeWork ; schema:relevantOccupation schema:domainIncludes schema:JobPosting ; schema:rangeIncludes schema:Occupation ; - rdfs:label "relevantOccupation"@en ; - dc:source ; rdfs:comment "The Occupation for the JobPosting."@en ; + dc:source ; + rdfs:label "relevantOccupation"@en ; schema:category "issue-1698"@en . @@ -11540,13 +11564,13 @@ schema:requiresSubscription rdfs:label "requiresSubscription"@en ; schema:category "issue-1741"@en ; dc:source ; schema:domainIncludes schema:MediaObject ; - schema:rangeIncludes schema:MediaSubscription ; rdfs:comment "Indicates if use of the media require a subscription (either paid or free). Allowed values are ```true``` or ```false``` (note that an earlier version had 'yes', 'no')."@en ; + schema:rangeIncludes schema:MediaSubscription ; schema:domainIncludes schema:ActionAccessSpecification . -schema:reservationFor rdfs:label "reservationFor"@en ; - rdfs:comment "The thing -- flight, event, restaurant,etc. being reserved."@en ; +schema:reservationFor rdfs:comment "The thing -- flight, event, restaurant,etc. being reserved."@en ; + rdfs:label "reservationFor"@en ; schema:rangeIncludes schema:Thing ; schema:domainIncludes schema:Reservation . @@ -11559,8 +11583,8 @@ schema:reservationId schema:domainIncludes schema:Reservation ; schema:reservationStatus schema:rangeIncludes schema:ReservationStatusType ; rdfs:label "reservationStatus"@en ; - schema:domainIncludes schema:Reservation ; - rdfs:comment "The current status of the reservation."@en . + rdfs:comment "The current status of the reservation."@en ; + schema:domainIncludes schema:Reservation . schema:reservedTicket schema:rangeIncludes schema:Ticket ; @@ -11582,13 +11606,13 @@ schema:review schema:rangeIncludes schema:Review ; schema:domainIncludes schema:Service , schema:Product , schema:Organization , - schema:Brand , schema:Place , - schema:CreativeWork ; + schema:Brand , + schema:CreativeWork , + schema:Event ; rdfs:label "review"@en ; - schema:domainIncludes schema:Event ; - rdfs:comment "A review of the item."@en ; - schema:domainIncludes schema:Offer . + schema:domainIncludes schema:Offer ; + rdfs:comment "A review of the item."@en . schema:reviewAspect schema:domainIncludes schema:Rating ; @@ -11625,12 +11649,12 @@ schema:reviewedBy rdfs:label "reviewedBy"@en ; rdfs:comment "People or organizations that have reviewed the content on this web page for accuracy and/or completeness."@en . -schema:reviews schema:supersededBy schema:review ; - schema:domainIncludes schema:CreativeWork ; +schema:reviews schema:domainIncludes schema:CreativeWork ; + schema:supersededBy schema:review ; rdfs:label "reviews"@en ; - schema:domainIncludes schema:Offer , - schema:Product ; + schema:domainIncludes schema:Offer ; rdfs:comment "Review of the item."@en ; + schema:domainIncludes schema:Product ; schema:rangeIncludes schema:Review ; schema:domainIncludes schema:Organization , schema:Place . @@ -11643,8 +11667,8 @@ schema:roleName schema:rangeIncludes schema:URL , rdfs:comment "A role played, performed or filled by a person or organization. For example, the team of creators for a comic book might fill the roles named 'inker', 'penciller', and 'letterer'; or an athlete in a SportsTeam might play in the position named 'Quarterback'."@en . -schema:rsvpResponse schema:domainIncludes schema:RsvpAction ; - rdfs:label "rsvpResponse"@en ; +schema:rsvpResponse rdfs:label "rsvpResponse"@en ; + schema:domainIncludes schema:RsvpAction ; schema:rangeIncludes schema:RsvpResponseType ; rdfs:comment "The response (yes, no, maybe) to the RSVP."@en . @@ -11657,8 +11681,8 @@ schema:runtime schema:supersededBy schema:runtimePlatform ; schema:runtimePlatform schema:rangeIncludes schema:Text ; - rdfs:comment "Runtime platform or script interpreter dependencies (Example - Java v1, Python2.3, .Net Framework 3.0)."@en ; schema:domainIncludes schema:SoftwareSourceCode ; + rdfs:comment "Runtime platform or script interpreter dependencies (Example - Java v1, Python2.3, .Net Framework 3.0)."@en ; rdfs:label "runtimePlatform"@en . @@ -11682,8 +11706,8 @@ schema:saturatedFatContent schema:rangeIncludes schema:Mass ; rdfs:comment "The number of grams of saturated fat."@en . -schema:scheduledPaymentDate rdfs:comment "The date the invoice is scheduled to be paid."@en ; - rdfs:label "scheduledPaymentDate"@en ; +schema:scheduledPaymentDate rdfs:label "scheduledPaymentDate"@en ; + rdfs:comment "The date the invoice is scheduled to be paid."@en ; schema:domainIncludes schema:Invoice ; schema:rangeIncludes schema:Date . @@ -11714,8 +11738,8 @@ schema:screenshot rdfs:label "screenshot"@en ; schema:domainIncludes schema:SoftwareApplication . -schema:seasons schema:rangeIncludes schema:CreativeWorkSeason ; - schema:supersededBy schema:season ; +schema:seasons schema:supersededBy schema:season ; + schema:rangeIncludes schema:CreativeWorkSeason ; schema:domainIncludes schema:VideoGameSeries , schema:TVSeries ; rdfs:label "seasons"@en ; @@ -11731,8 +11755,8 @@ schema:seatNumber schema:domainIncludes schema:Seat ; schema:seatRow rdfs:label "seatRow"@en ; schema:rangeIncludes schema:Text ; - schema:domainIncludes schema:Seat ; - rdfs:comment "The row location of the reserved seat (e.g., B)."@en . + rdfs:comment "The row location of the reserved seat (e.g., B)."@en ; + schema:domainIncludes schema:Seat . schema:seatSection rdfs:comment "The section location of the reserved seat (e.g. Orchestra)."@en ; @@ -11755,9 +11779,9 @@ schema:securityScreening rdfs:label "securityScreening"@en ; schema:seeks rdfs:comment "A pointer to products or services sought by the organization or person (demand)."@en ; - schema:domainIncludes schema:Organization ; + schema:domainIncludes schema:Organization , + schema:Person ; schema:rangeIncludes schema:Demand ; - schema:domainIncludes schema:Person ; rdfs:label "seeks"@en . @@ -11771,8 +11795,8 @@ schema:serviceArea schema:domainIncludes schema:Organization ; schema:rangeIncludes schema:AdministrativeArea , schema:Place ; rdfs:comment "The geographic area where the service is provided."@en ; - schema:rangeIncludes schema:GeoShape ; schema:supersededBy schema:areaServed ; + schema:rangeIncludes schema:GeoShape ; schema:domainIncludes schema:ContactPoint , schema:Service ; rdfs:label "serviceArea"@en . @@ -11834,8 +11858,8 @@ schema:serviceUrl schema:domainIncludes schema:ServiceChannel ; schema:servingSize schema:domainIncludes schema:NutritionInformation ; - rdfs:label "servingSize"@en ; schema:rangeIncludes schema:Text ; + rdfs:label "servingSize"@en ; rdfs:comment "The serving size, in terms of the number of volume or mass."@en . @@ -11885,14 +11909,14 @@ schema:slogan rdfs:comment "A slogan or motto associated with the item."@en ; schema:domainIncludes schema:Product ; rdfs:label "slogan"@en ; schema:domainIncludes schema:Place , - schema:Brand , schema:Organization , + schema:Brand , schema:Service . schema:smokingAllowed rdfs:comment "Indicates whether it is allowed to smoke in the place, e.g. in the restaurant, hotel or hotel room."@en ; - rdfs:label "smokingAllowed"@en ; dc:source ; + rdfs:label "smokingAllowed"@en ; schema:domainIncludes schema:Place ; schema:rangeIncludes schema:Boolean . @@ -11923,15 +11947,15 @@ schema:softwareRequirements rdfs:comment "Component dependency requirements for schema:softwareVersion schema:rangeIncludes schema:Text ; - rdfs:comment "Version of the software instance."@en ; rdfs:label "softwareVersion"@en ; + rdfs:comment "Version of the software instance."@en ; schema:domainIncludes schema:SoftwareApplication . schema:sourceOrganization rdfs:comment "The Organization on whose behalf the creator was working."@en ; rdfs:label "sourceOrganization"@en ; - schema:domainIncludes schema:CreativeWork ; - schema:rangeIncludes schema:Organization . + schema:rangeIncludes schema:Organization ; + schema:domainIncludes schema:CreativeWork . schema:spatial schema:rangeIncludes schema:Place ; @@ -11964,8 +11988,8 @@ we define a supporting type, [[SpeakableSpecification]] which is defined to be rdfs:label "speakable"@en . -schema:specialCommitments rdfs:comment "Any special commitments associated with this job posting. Valid entries include VeteranCommit, MilitarySpouseCommit, etc."@en ; - schema:rangeIncludes schema:Text ; +schema:specialCommitments schema:rangeIncludes schema:Text ; + rdfs:comment "Any special commitments associated with this job posting. Valid entries include VeteranCommit, MilitarySpouseCommit, etc."@en ; rdfs:label "specialCommitments"@en ; schema:domainIncludes schema:JobPosting . @@ -11996,14 +12020,6 @@ schema:spouse schema:rangeIncludes schema:Person ; rdfs:label "spouse"@en . -schema:starRating rdfs:comment "An official rating for a lodging business or food establishment, e.g. from national associations or standards bodies. Use the author property to indicate the rating organization, e.g. as an Organization with name such as (e.g. HOTREC, DEHOGA, WHR, or Hotelstars)."@en ; - schema:domainIncludes schema:FoodEstablishment , - schema:LodgingBusiness ; - schema:rangeIncludes schema:Rating ; - rdfs:label "starRating"@en ; - dc:source . - - schema:startTime schema:rangeIncludes schema:Time ; schema:domainIncludes schema:Action , schema:FoodEstablishmentReservation , @@ -12028,10 +12044,10 @@ schema:stepValue rdfs:label "stepValue"@en ; schema:steps schema:rangeIncludes schema:Text ; schema:domainIncludes schema:HowToSection ; - schema:rangeIncludes schema:ItemList ; rdfs:label "steps"@en ; - rdfs:comment "A single step item (as HowToStep, text, document, video, etc.) or a HowToSection (originally misnamed 'steps'; 'step' is preferred)."@en ; + schema:rangeIncludes schema:ItemList ; schema:domainIncludes schema:HowTo ; + rdfs:comment "A single step item (as HowToStep, text, document, video, etc.) or a HowToSection (originally misnamed 'steps'; 'step' is preferred)."@en ; schema:supersededBy schema:step ; schema:rangeIncludes schema:CreativeWork . @@ -12080,11 +12096,11 @@ schema:subjectOf schema:rangeIncludes schema:Event ; rdfs:comment "A CreativeWork or Event about this Thing."@en . -schema:subtitleLanguage schema:domainIncludes schema:Movie ; +schema:subtitleLanguage schema:domainIncludes schema:Movie , + schema:TVEpisode ; rdfs:comment "Languages in which subtitles/captions are available, in [IETF BCP 47 standard format](http://tools.ietf.org/html/bcp47)."@en ; - schema:domainIncludes schema:TVEpisode , - schema:ScreeningEvent ; schema:rangeIncludes schema:Language ; + schema:domainIncludes schema:ScreeningEvent ; rdfs:label "subtitleLanguage"@en ; schema:rangeIncludes schema:Text . @@ -12107,8 +12123,8 @@ schema:suggestedGender schema:domainIncludes schema:PeopleAudience ; rdfs:comment "The gender of the person or audience."@en . -schema:suggestedMaxAge rdfs:label "suggestedMaxAge"@en ; - rdfs:comment "Maximal age recommended for viewing content."@en ; +schema:suggestedMaxAge rdfs:comment "Maximal age recommended for viewing content."@en ; + rdfs:label "suggestedMaxAge"@en ; schema:domainIncludes schema:PeopleAudience ; schema:rangeIncludes schema:Number . @@ -12159,8 +12175,8 @@ schema:targetName schema:rangeIncludes schema:Text ; schema:targetPlatform schema:domainIncludes schema:APIReference ; rdfs:comment "Type of app development: phone, Metro style, desktop, XBox, etc."@en ; - rdfs:label "targetPlatform"@en ; - schema:rangeIncludes schema:Text . + schema:rangeIncludes schema:Text ; + rdfs:label "targetPlatform"@en . schema:targetProduct rdfs:comment "Target Operating System / Product to which the code applies. If applies to several versions, just the product name can be used."@en ; @@ -12189,9 +12205,9 @@ schema:temporalCoverage rdfs:comment """The temporalCoverage of a CreativeWork i Open-ended date ranges can be written with \"..\" in place of the end date. For example, \"2015-11/..\" indicates a range beginning in November 2015 and with no specified final date. This is tentative and might be updated in future when ISO 8601 is officially updated."""@en ; schema:rangeIncludes schema:Text , - schema:DateTime , - schema:URL ; + schema:DateTime ; schema:domainIncludes schema:CreativeWork ; + schema:rangeIncludes schema:URL ; rdfs:label "temporalCoverage"@en . @@ -12210,8 +12226,8 @@ schema:thumbnail rdfs:comment "Thumbnail image for an image or video."@en ; schema:thumbnailUrl schema:rangeIncludes schema:URL ; rdfs:comment "A thumbnail image relevant to the Thing."@en ; - schema:domainIncludes schema:CreativeWork ; - rdfs:label "thumbnailUrl"@en . + rdfs:label "thumbnailUrl"@en ; + schema:domainIncludes schema:CreativeWork . schema:tickerSymbol schema:domainIncludes schema:Corporation ; @@ -12233,8 +12249,8 @@ schema:ticketToken rdfs:label "ticketToken"@en ; schema:domainIncludes schema:Ticket . -schema:ticketedSeat schema:domainIncludes schema:Ticket ; - schema:rangeIncludes schema:Seat ; +schema:ticketedSeat schema:rangeIncludes schema:Seat ; + schema:domainIncludes schema:Ticket ; rdfs:label "ticketedSeat"@en ; rdfs:comment "The seat associated with the ticket."@en . @@ -12312,8 +12328,8 @@ schema:tracks rdfs:label "tracks"@en ; schema:domainIncludes schema:MusicGroup . -schema:trailer schema:domainIncludes schema:RadioSeries , - schema:TVSeries , +schema:trailer schema:domainIncludes schema:TVSeries , + schema:RadioSeries , schema:MovieSeries , schema:Movie , schema:CreativeWorkSeason , @@ -12344,8 +12360,8 @@ schema:transFatContent schema:domainIncludes schema:NutritionInformation ; schema:transcript rdfs:label "transcript"@en ; - schema:rangeIncludes schema:Text ; rdfs:comment "If this MediaObject is an AudioObject or VideoObject, the transcript of that object."@en ; + schema:rangeIncludes schema:Text ; schema:domainIncludes schema:VideoObject , schema:AudioObject . @@ -12360,8 +12376,8 @@ schema:translator rdfs:comment "Organization or person who adapts a creative wor schema:typeOfBed schema:rangeIncludes schema:BedType ; rdfs:label "typeOfBed"@en ; - schema:rangeIncludes schema:Text ; rdfs:comment "The type of bed to which the BedDetail refers, i.e. the type of bed available in the quantity indicated by quantity."@en ; + schema:rangeIncludes schema:Text ; dc:source ; schema:domainIncludes schema:BedDetails . @@ -12385,8 +12401,8 @@ schema:underName rdfs:comment "The person or organization the reservation or tic schema:domainIncludes schema:Ticket ; schema:rangeIncludes schema:Organization ; schema:domainIncludes schema:Reservation ; - rdfs:label "underName"@en ; - schema:rangeIncludes schema:Person . + schema:rangeIncludes schema:Person ; + rdfs:label "underName"@en . schema:unitText rdfs:comment """A string or text indicating the unit of measurement. Useful if you cannot provide a standard unit code for @@ -12431,8 +12447,8 @@ schema:userInteractionCount rdfs:comment "The number of interactions for the Cre schema:validFor rdfs:comment "The duration of validity of a permit or similar thing."@en ; - rdfs:label "validFor"@en ; schema:rangeIncludes schema:Duration ; + rdfs:label "validFor"@en ; schema:domainIncludes schema:Permit . @@ -12497,8 +12513,8 @@ schema:valueMaxLength schema:rangeIncludes schema:Number ; rdfs:comment "Specifies the allowed range for number of characters in a literal value."@en . -schema:valueMinLength schema:domainIncludes schema:PropertyValueSpecification ; - rdfs:label "valueMinLength"@en ; +schema:valueMinLength rdfs:label "valueMinLength"@en ; + schema:domainIncludes schema:PropertyValueSpecification ; rdfs:comment "Specifies the minimum allowed range for number of characters in a literal value."@en ; schema:rangeIncludes schema:Number . @@ -12515,9 +12531,9 @@ schema:valuePattern schema:rangeIncludes schema:Text ; rdfs:label "valuePattern"@en . -schema:valueReference schema:rangeIncludes schema:Enumeration , +schema:valueReference schema:domainIncludes schema:QualitativeValue ; + schema:rangeIncludes schema:Enumeration , schema:QuantitativeValue ; - schema:domainIncludes schema:QualitativeValue ; rdfs:label "valueReference"@en ; schema:rangeIncludes schema:StructuredValue ; schema:domainIncludes schema:QuantitativeValue ; @@ -12540,8 +12556,8 @@ schema:vatID schema:domainIncludes schema:Organization ; rdfs:comment "The Value-added Tax ID of the organization or person."@en . -schema:vehicleConfiguration rdfs:label "vehicleConfiguration"@en ; - schema:rangeIncludes schema:Text ; +schema:vehicleConfiguration schema:rangeIncludes schema:Text ; + rdfs:label "vehicleConfiguration"@en ; rdfs:comment "A short text indicating the configuration of the vehicle, e.g. '5dr hatchback ST 2.5 MT 225 hp' or 'limited edition'."@en ; schema:domainIncludes schema:Vehicle ; dc:source . @@ -12575,16 +12591,16 @@ schema:vehicleModelDate schema:domainIncludes schema:Vehicle ; schema:rangeIncludes schema:Date . -schema:vehicleSeatingCapacity rdfs:comment "The number of passengers that can be seated in the vehicle, both in terms of the physical space available, and in terms of limitations set by law.\\n\\nTypical unit code(s): C62 for persons."@en ; +schema:vehicleSeatingCapacity rdfs:label "vehicleSeatingCapacity"@en ; dc:source ; schema:rangeIncludes schema:QuantitativeValue ; - rdfs:label "vehicleSeatingCapacity"@en ; + rdfs:comment "The number of passengers that can be seated in the vehicle, both in terms of the physical space available, and in terms of limitations set by law.\\n\\nTypical unit code(s): C62 for persons."@en ; schema:rangeIncludes schema:Number ; schema:domainIncludes schema:Vehicle . -schema:vehicleSpecialUsage schema:rangeIncludes schema:Text ; - rdfs:label "vehicleSpecialUsage"@en ; +schema:vehicleSpecialUsage rdfs:label "vehicleSpecialUsage"@en ; + schema:rangeIncludes schema:Text ; rdfs:comment "Indicates whether the vehicle has been used for special purposes, like commercial rental, driving school, or as a taxi. The legislation in many countries requires this information to be revealed when offering a car for sale."@en ; schema:domainIncludes schema:Vehicle . @@ -12606,16 +12622,16 @@ schema:version rdfs:comment "The version of the CreativeWork embodied by a speci schema:video rdfs:label "video"@en ; - rdfs:comment "An embedded video object."@en ; schema:domainIncludes schema:CreativeWork ; + rdfs:comment "An embedded video object."@en ; schema:rangeIncludes schema:Clip , schema:VideoObject . -schema:videoFormat schema:rangeIncludes schema:Text ; - schema:domainIncludes schema:BroadcastEvent , - schema:ScreeningEvent ; +schema:videoFormat schema:domainIncludes schema:BroadcastEvent ; + schema:rangeIncludes schema:Text ; rdfs:comment "The type of screening or video broadcast used (e.g. IMAX, 3D, SD, HD, etc.)."@en ; + schema:domainIncludes schema:ScreeningEvent ; rdfs:label "videoFormat"@en ; schema:domainIncludes schema:BroadcastService . @@ -12634,17 +12650,17 @@ schema:videoQuality schema:domainIncludes schema:VideoObject ; schema:warranty rdfs:label "warranty"@en ; schema:domainIncludes schema:Offer ; - rdfs:comment "The warranty promise(s) included in the offer."@en ; schema:rangeIncludes schema:WarrantyPromise ; + rdfs:comment "The warranty promise(s) included in the offer."@en ; schema:domainIncludes schema:Demand . schema:warrantyPromise schema:domainIncludes schema:BuyAction , schema:SellAction ; - schema:supersededBy schema:warranty ; rdfs:comment "The warranty promise(s) included in the offer."@en ; - schema:rangeIncludes schema:WarrantyPromise ; - rdfs:label "warrantyPromise"@en . + rdfs:label "warrantyPromise"@en ; + schema:supersededBy schema:warranty ; + schema:rangeIncludes schema:WarrantyPromise . schema:warrantyScope schema:domainIncludes schema:WarrantyPromise ; @@ -12684,20 +12700,20 @@ schema:wordCount rdfs:comment "The number of words in the text of the Article."@ schema:workExample dc:source ; schema:inverseOf schema:exampleOfWork ; rdfs:label "workExample"@en ; - schema:domainIncludes schema:CreativeWork ; rdfs:comment "Example/instance/realization/derivation of the concept of this creative work. eg. The paperback edition, first edition, or eBook."@en ; + schema:domainIncludes schema:CreativeWork ; schema:rangeIncludes schema:CreativeWork . -schema:workHours rdfs:label "workHours"@en ; - rdfs:comment "The typical working hours for this job (e.g. 1st shift, night shift, 8am-5pm)."@en ; +schema:workHours rdfs:comment "The typical working hours for this job (e.g. 1st shift, night shift, 8am-5pm)."@en ; + rdfs:label "workHours"@en ; schema:rangeIncludes schema:Text ; schema:domainIncludes schema:JobPosting . -schema:worstRating schema:rangeIncludes schema:Number , - schema:Text ; - rdfs:comment "The lowest value allowed in this rating system. If worstRating is omitted, 1 is assumed."@en ; +schema:worstRating rdfs:comment "The lowest value allowed in this rating system. If worstRating is omitted, 1 is assumed."@en ; + schema:rangeIncludes schema:Text , + schema:Number ; schema:domainIncludes schema:Rating ; rdfs:label "worstRating"@en . @@ -12719,8 +12735,8 @@ schema:yearlyRevenue rdfs:comment "The size of the business in annual revenue."@ schema:yearsInOperation schema:domainIncludes schema:BusinessAudience ; schema:rangeIncludes schema:QuantitativeValue ; - rdfs:comment "The age of the business."@en ; - rdfs:label "yearsInOperation"@en . + rdfs:label "yearsInOperation"@en ; + rdfs:comment "The age of the business."@en . dc:source , From 97abda42453fa61c959c9aad823b645c0810b798 Mon Sep 17 00:00:00 2001 From: skomlaebri Date: Wed, 19 Aug 2020 16:34:50 +0200 Subject: [PATCH 10/13] add git attributes --- .gitattributes | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..5ac58d6 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,3 @@ +*.sh eol=lf +*.conf eol=lf +*.sql eol=lf \ No newline at end of file From 4619b1a74acd17daf8fd29b69f853db41bafea17 Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Thu, 20 Aug 2020 11:17:54 +0200 Subject: [PATCH 11/13] Postgres downgraded to 12.1 (not working for 12.4) --- docker-compose.yml | 2 +- test/master/Dockerfile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 7407959..5b127ec 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -36,7 +36,7 @@ services: ports: - "${DEV_MASTER_POSTGRES_PORT}:5432" slave-db: - image: postgres:12 + image: postgres:12.1 shm_size: 1g ports: - "${MAPPED_POSTGRES_PORT}:5432" diff --git a/test/master/Dockerfile b/test/master/Dockerfile index b65ebfc..05f8611 100644 --- a/test/master/Dockerfile +++ b/test/master/Dockerfile @@ -1,4 +1,4 @@ -FROM postgres:12 as base +FROM postgres:12.1 as base COPY original_schema.sql /docker-entrypoint-initdb.d/01-original_schema.sql COPY dump-tourism-201911121025.sql.gz /docker-entrypoint-initdb.d/03-dump.sql.gz From 7d78442e2ffc9c3068e79504838119001d638ac9 Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Thu, 20 Aug 2020 11:52:28 +0200 Subject: [PATCH 12/13] Query logging options updated. --- vkg/odh.docker.properties | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/vkg/odh.docker.properties b/vkg/odh.docker.properties index 486692a..332e476 100644 --- a/vkg/odh.docker.properties +++ b/vkg/odh.docker.properties @@ -18,3 +18,7 @@ ontop.queryLogging.includeClassesAndProperties=true ontop.queryLogging.includeTables=true ontop.queryLogging.includeHttpHeader.referer=true ontop.queryLogging.extractQueryTemplate=true +# TODO: remove it +ontop.queryLogging.decompositionAndMergingMutuallyExclusive=false +# TODO: remove it +ontop.queryLogging.decomposition=true From b1ea40372b1a668bbcdabc44ba7e32321c1255d5 Mon Sep 17 00:00:00 2001 From: Benjamin Cogrel Date: Thu, 20 Aug 2020 15:36:47 +0200 Subject: [PATCH 13/13] Nginx logs are now outputting custom JSON. --- infrastructure/docker/nginx/Dockerfile | 3 +- infrastructure/docker/nginx/default.conf | 37 ++++++++++++ infrastructure/docker/nginx/nginx.conf | 76 ++++++++++++++---------- 3 files changed, 82 insertions(+), 34 deletions(-) create mode 100644 infrastructure/docker/nginx/default.conf diff --git a/infrastructure/docker/nginx/Dockerfile b/infrastructure/docker/nginx/Dockerfile index 9391480..92ba304 100644 --- a/infrastructure/docker/nginx/Dockerfile +++ b/infrastructure/docker/nginx/Dockerfile @@ -3,7 +3,8 @@ FROM nginx:1.17.8-alpine RUN apk add --update curl && \ rm -rf /var/cache/apk/* -COPY infrastructure/docker/nginx/nginx.conf /etc/nginx/conf.d/default.conf +COPY infrastructure/docker/nginx/default.conf /etc/nginx/conf.d/default.conf +COPY infrastructure/docker/nginx/nginx.conf /etc/nginx/nginx.conf # expose port 80 EXPOSE 80 diff --git a/infrastructure/docker/nginx/default.conf b/infrastructure/docker/nginx/default.conf new file mode 100644 index 0000000..caac654 --- /dev/null +++ b/infrastructure/docker/nginx/default.conf @@ -0,0 +1,37 @@ + +proxy_cache_path /tmp/cache-nginx levels=1:2 keys_zone=my_cache:10m max_size=10g + inactive=1d use_temp_path=off; + +server { + listen 80; + + gzip on; + + location / { + proxy_pass http://ontop:8080/; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "upgrade"; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + proxy_read_timeout 6000; + gzip_proxied any; + gzip_types *; + + proxy_cache my_cache; + proxy_cache_lock on; + proxy_cache_background_update on; + proxy_cache_methods GET HEAD POST; + # proxy_cache_revalidate on; + # For large POST requests, the request_body is not considered in the key! + # In such a case, we do not cache it in Nginx. + # NB: one can adjust client_body_buffer_size for deciding to cache or not. + # https://stackoverflow.com/questions/18795701/nginx-proxy-cache-key-request-body-is-ignored-for-large-request-body#18986571 + proxy_no_cache $request_body_file; + proxy_cache_key $request_uri|$request_body|$upstream_http_vary; + } +} + + + diff --git a/infrastructure/docker/nginx/nginx.conf b/infrastructure/docker/nginx/nginx.conf index caac654..7166b27 100644 --- a/infrastructure/docker/nginx/nginx.conf +++ b/infrastructure/docker/nginx/nginx.conf @@ -1,37 +1,47 @@ +user nginx; +worker_processes auto; + +error_log /var/log/nginx/error.log warn; +pid /var/run/nginx.pid; -proxy_cache_path /tmp/cache-nginx levels=1:2 keys_zone=my_cache:10m max_size=10g - inactive=1d use_temp_path=off; - -server { - listen 80; - - gzip on; - - location / { - proxy_pass http://ontop:8080/; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "upgrade"; - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto $scheme; - proxy_read_timeout 6000; - gzip_proxied any; - gzip_types *; - - proxy_cache my_cache; - proxy_cache_lock on; - proxy_cache_background_update on; - proxy_cache_methods GET HEAD POST; - # proxy_cache_revalidate on; - # For large POST requests, the request_body is not considered in the key! - # In such a case, we do not cache it in Nginx. - # NB: one can adjust client_body_buffer_size for deciding to cache or not. - # https://stackoverflow.com/questions/18795701/nginx-proxy-cache-key-request-body-is-ignored-for-large-request-body#18986571 - proxy_no_cache $request_body_file; - proxy_cache_key $request_uri|$request_body|$upstream_http_vary; - } -} +events { + worker_connections 1024; +} +http { + include /etc/nginx/mime.types; + default_type application/octet-stream; + + log_format json_combined escape=json + '{' + '"@timestamp":"$time_iso8601",' + '"message":"query:reverse-proxy",' + '"application":"ontop-odh",' + '"payload": {' + '"cacheStatus": "$upstream_cache_status",' + '"httpHeaders": {' + '"referer":"$http_referer",' + '"client-app": "$http_client_app",' + '"prepared-query": "$http_prepared_query"' + '},' + '"remoteAddr":"$remote_addr",' + '"request":"$request",' + '"requestBody": "$request_body",' + '"status": "$status",' + '"bodyBytesSent":"$body_bytes_sent",' + '"requestTime":"$request_time"' + '}}'; + + access_log /var/log/nginx/access.log json_combined; + + sendfile on; + #tcp_nopush on; + + keepalive_timeout 65; + + #gzip on; + + include /etc/nginx/conf.d/*.conf; +} \ No newline at end of file