rdf4j icon indicating copy to clipboard operation
rdf4j copied to clipboard

[FedX] Enable monitoring and log of the query plan using the configuration file

Open ludovicm67 opened this issue 1 year ago • 3 comments

Problem description

According to https://rdf4j.org/documentation/programming/federation/#logging-the-query-plan, it is possible to enable monitoring and the log of the query plan by using:

FedXConfig config = new FedXConfig().withEnableMonitoring(true).withLogQueryPlan(true);

I'm currently using the following to create the FedX repository from a turtle configuration file:

FedXFactory.createFederation(configFile)

I'm wondering if it is possible to configure those settings using the configuration file.

Preferred solution

Be able to enable monitoring and the log of the query plan using the configuration file, and have those options documented.

Are you interested in contributing a solution yourself?

None

Alternatives you've considered

No response

Anything else?

No response

ludovicm67 avatar Aug 23 '23 09:08 ludovicm67

@aschwarte10 do you know if this is possible?

hmottestad avatar Aug 23 '23 09:08 hmottestad

The FedXFactory#createFederation(memberConfig) method takes an RDF turtle file describing the federation members. The respective feature is documented in https://rdf4j.org/documentation/programming/federation/#member-configuration

All other configuration options are currently exposed through the FedXFactory. The available options are documented at https://rdf4j.org/documentation/programming/federation/#fedx-configuration Currently there is no means to have configuration options declared in a configuration file.

I understand that in your scenario you are creating the federation explicitly through code in your application, i.e. you have full control over the creation of the federation and its configuration.

What I could imagine as improvement in RDF4J, is to expose some of the configuration settings in the FedXRepositoryConfig- this allows to expose configuration e.g. in use.cases where the federation is configured in the RDF4J workbench or managed declaratively in some RepositoryManager. I do however not see that the FedXFactory requires a separate configuration file for the options - but maybe you can elaborate on your use-cases.

aschwarte10 avatar Aug 25 '23 06:08 aschwarte10

No need for a separate configuration file. The ideal way would be to be able to configure https://rdf4j.org/documentation/programming/federation/#fedx-configuration options directly in the same turtle configuration file.

This will allow having a generic application that can be used for many use-cases, where the user can define what he wants directly using a single configuration file.

ludovicm67 avatar Aug 25 '23 07:08 ludovicm67