3.0.3 • Published 20 days ago

@comunica/actor-optimize-query-operation-prune-empty-source-operations v3.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
20 days ago

Comunica Prune Empty Source Operations Optimize Query Operation Actor

npm version

An Optimize Query Operation actor that removes operations from the query plan that are guaranteed to produce empty results. This actor relies on source-based cardinality metadata, or may optionally make use of ASK queries if the source supports it.

This module is part of the Comunica framework, and should only be used by developers that want to build their own query engine.

Click here if you just want to query with Comunica.

Install

$ yarn add @comunica/actor-optimize-query-operation-prune-empty-source-operations

Configure

After installing, this package can be added to your engine's configuration as follows:

{
  "@context": [
    ...
    "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-optimize-query-operation-prune-empty-source-operations/^1.0.0/components/context.jsonld"
  ],
  "actors": [
    ...
    {
      "@id": "urn:comunica:default:optimize-query-operation/actors#prune-empty-source-operations",
      "@type": "ActorOptimizeQueryOperationPruneEmptySourceOperations",
      "useAskIfSupported": false
    }
  ]
}

Config Parameters

  • useAskIfSupported: If true, ASK queries will be sent to the source instead of COUNT queries to check emptiness for patterns. This will only be done for sources that accept ASK queries. (defaults to false)