Skip to content

Commit

Permalink
Change pattern of drivers properties
Browse files Browse the repository at this point in the history
  • Loading branch information
charphi committed Jul 25, 2023
1 parent 0e84f55 commit 66790d3
Show file tree
Hide file tree
Showing 30 changed files with 106 additions and 93 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Added

- ![PROVIDER] Add RI networking
- ![PROVIDER] Add support of environment variables

### Fixed

- ![PROVIDER] Fix file locking in cache
Expand All @@ -19,6 +24,7 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
- ![API] Refactor listeners API [#506](https://github.com/nbbrd/sdmx-dl/issues/506)
- ![API] Handle languages per connection instead of per manager [#507](https://github.com/nbbrd/sdmx-dl/issues/507)
- ![API] Simplify naming and structure [#508](https://github.com/nbbrd/sdmx-dl/issues/508)
- ![API] Change pattern of drivers properties
- ![SOURCE] Update ECB endpoint [#495](https://github.com/nbbrd/sdmx-dl/issues/495)
- ![FORMAT] Refactor file format API [#502](https://github.com/nbbrd/sdmx-dl/issues/502)
- ![PROVIDER] Move curl backend to an external project
Expand Down
38 changes: 19 additions & 19 deletions docs/tmp/sources.csv
Original file line number Diff line number Diff line change
@@ -1,34 +1,34 @@
Name,Description,Aliases,Driver,Endpoint,Properties,Website,Monitor,MonitorWebsite,Languages
ABS,Australian Bureau of Statistics,,ri:sdmx21,https://api.data.abs.gov.au,detailSupported=true,https://explore.data.abs.gov.au,upptime:/nbbrd/sdmx-upptime/ABS,https://nbbrd.github.io/sdmx-upptime/history/abs,en
ABS,Australian Bureau of Statistics,,ri:sdmx21,https://api.data.abs.gov.au,sdmxdl.driver.detailSupported=true,https://explore.data.abs.gov.au,upptime:/nbbrd/sdmx-upptime/ABS,https://nbbrd.github.io/sdmx-upptime/history/abs,en
BBK,Deutsche Bundesbank,,ri:bbk,https://api.statistiken.bundesbank.de/rest,,https://www.bundesbank.de/en/statistics/time-series-databases,upptime:/nbbrd/sdmx-upptime/BBK,https://nbbrd.github.io/sdmx-upptime/history/bbk,"en,de"
BIS,Bank for International Settlements,,ri:sdmx21,https://stats.bis.org/api/v1,detailSupported=true,https://stats.bis.org/statx/toc/LBS.html,upptime:/nbbrd/sdmx-upptime/BIS,https://nbbrd.github.io/sdmx-upptime/history/bis,en
BIS,Bank for International Settlements,,ri:sdmx21,https://stats.bis.org/api/v1,sdmxdl.driver.detailSupported=true,https://stats.bis.org/statx/toc/LBS.html,upptime:/nbbrd/sdmx-upptime/BIS,https://nbbrd.github.io/sdmx-upptime/history/bis,en
CAMSTAT,National Institute of Statistics of Cambodia,,ri:sdmx21,https://nsiws-stable-camstat-live.officialstatistics.org/rest,,http://camstat.nis.gov.kh/?locale=en&start=0,upptime:/nbbrd/sdmx-upptime/CAMSTAT,https://nbbrd.github.io/sdmx-upptime/history/camstat,"en,km"
ECB,European Central Bank,,ri:sdmx21,https://data-api.ecb.europa.eu/service,detailSupported=true,https://data.ecb.europa.eu/,upptime:/nbbrd/sdmx-upptime/ECB,https://nbbrd.github.io/sdmx-upptime/history/ecb,en
ECB,European Central Bank,,ri:sdmx21,https://data-api.ecb.europa.eu/service,sdmxdl.driver.detailSupported=true,https://data.ecb.europa.eu/,upptime:/nbbrd/sdmx-upptime/ECB,https://nbbrd.github.io/sdmx-upptime/history/ecb,en
EC_DG_COMP,European Commission - Directorate General for Competition,,ri:estat,https://webgate.ec.europa.eu/comp/redisstat/api/dissemination/sdmx/2.1,,https://data.europa.eu/data/datasets?catalog=comp,upptime:/nbbrd/sdmx-upptime/EC_DG_COMP,https://nbbrd.github.io/sdmx-upptime/history/ec_dg_comp,en
EC_DG_EMPL,"European Commission - Directorate General for Employment, Social Affairs and inclusion",,ri:estat,https://webgate.ec.europa.eu/empl/redisstat/api/dissemination/sdmx/2.1,,https://data.europa.eu/data/datasets?catalog=empl,upptime:/nbbrd/sdmx-upptime/EC_DG_EMPL,https://nbbrd.github.io/sdmx-upptime/history/ec_dg_empl,en
EC_DG_GROW,"European Commission - Directorate General for Internal Market, Industry, Entrepreneurship and SMEs",,ri:estat,https://webgate.ec.europa.eu/grow/redisstat/api/dissemination/sdmx/2.1,,https://data.europa.eu/data/datasets?catalog=grow,upptime:/nbbrd/sdmx-upptime/EC_DG_GROW,https://nbbrd.github.io/sdmx-upptime/history/ec_dg_grow,en
ESCAP,Economic and Social Commission for Asia and the Pacific,,ri:sdmx21,https://api-dataexplorer.unescap.org/rest,detailSupported=true,https://dataexplorer.unescap.org/,upptime:/nbbrd/sdmx-upptime/ESCAP,https://nbbrd.github.io/sdmx-upptime/history/escap,en
ESCAP,Economic and Social Commission for Asia and the Pacific,,ri:sdmx21,https://api-dataexplorer.unescap.org/rest,sdmxdl.driver.detailSupported=true,https://dataexplorer.unescap.org/,upptime:/nbbrd/sdmx-upptime/ESCAP,https://nbbrd.github.io/sdmx-upptime/history/escap,en
ESTAT,Eurostat,EUROSTAT,ri:estat,https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1,,https://ec.europa.eu/eurostat/data/database,upptime:/nbbrd/sdmx-upptime/ESTAT,https://nbbrd.github.io/sdmx-upptime/history/estat,"en,de,fr"
ESTAT_COMEXT,Eurostat - International trade in goods statistics (ITGS),,ri:estat,https://ec.europa.eu/eurostat/api/comext/dissemination/sdmx/2.1,,https://ec.europa.eu/eurostat/web/international-trade-in-goods/overview,upptime:/nbbrd/sdmx-upptime/ESTAT_COMEXT,https://nbbrd.github.io/sdmx-upptime/history/estat_comext,en
ILO,International Labour Organization,,ri:sdmx21,https://www.ilo.org/sdmx/rest,detailSupported=true,https://ilostat.ilo.org/data/,upptime:/nbbrd/sdmx-upptime/ILO,https://nbbrd.github.io/sdmx-upptime/history/ilo,"en,es,fr"
ILO,International Labour Organization,,ri:sdmx21,https://www.ilo.org/sdmx/rest,sdmxdl.driver.detailSupported=true,https://ilostat.ilo.org/data/,upptime:/nbbrd/sdmx-upptime/ILO,https://nbbrd.github.io/sdmx-upptime/history/ilo,"en,es,fr"
IMF,International Monetary Fund,,ri:imf,http://dataservices.imf.org/REST/SDMX_XML.svc,,https://data.imf.org,upptime:/nbbrd/sdmx-upptime/IMF,https://nbbrd.github.io/sdmx-upptime/history/imf,en
IMF_SDMX_CENTRAL,International Monetary Fund (SDMX Central),,ri:sdmx21,https://sdmxcentral.imf.org/ws/public/sdmxapi/rest,detailSupported=true,https://data.imf.org,upptime:/nbbrd/sdmx-upptime/IMF_SDMX_CENTRAL,https://nbbrd.github.io/sdmx-upptime/history/imf-sdmx-central,"en,fr"
INEGI,"National Institute of Statistics, Geography and Informatics",,ri:sdmx21,https://sdmx.snieg.mx/service/Rest,"detailSupported=true,trailingSlashRequired=true",https://sdmx.snieg.mx,upptime:/nbbrd/sdmx-upptime/INEGI,https://nbbrd.github.io/sdmx-upptime/history/inegi,"en,es"
IMF_SDMX_CENTRAL,International Monetary Fund (SDMX Central),,ri:sdmx21,https://sdmxcentral.imf.org/ws/public/sdmxapi/rest,sdmxdl.driver.detailSupported=true,https://data.imf.org,upptime:/nbbrd/sdmx-upptime/IMF_SDMX_CENTRAL,https://nbbrd.github.io/sdmx-upptime/history/imf-sdmx-central,"en,fr"
INEGI,"National Institute of Statistics, Geography and Informatics",,ri:sdmx21,https://sdmx.snieg.mx/service/Rest,"sdmxdl.driver.detailSupported=true,sdmxdl.driver.trailingSlash=true",https://sdmx.snieg.mx,upptime:/nbbrd/sdmx-upptime/INEGI,https://nbbrd.github.io/sdmx-upptime/history/inegi,"en,es"
INSEE,National Institute of Statistics and Economic Studies,,ri:insee,https://bdm.insee.fr/series/sdmx,,https://www.insee.fr/fr/statistiques,upptime:/nbbrd/sdmx-upptime/INSEE,https://nbbrd.github.io/sdmx-upptime/history/insee,"en,fr"
ISTAT,Italian National Institute of Statistics,,ri:sdmx21,https://esploradati.istat.it/SDMXWS/rest,detailSupported=true,https://esploradati.istat.it/databrowser/,upptime:/nbbrd/sdmx-upptime/ISTAT,https://nbbrd.github.io/sdmx-upptime/history/istat,"en,it"
NB,Norges Bank,,ri:sdmx21,https://data.norges-bank.no/api,detailSupported=true,https://www.norges-bank.no/en/topics/Statistics/,upptime:/nbbrd/sdmx-upptime/NB,https://nbbrd.github.io/sdmx-upptime/history/nb,"en,no"
ISTAT,Italian National Institute of Statistics,,ri:sdmx21,https://esploradati.istat.it/SDMXWS/rest,sdmxdl.driver.detailSupported=true,https://esploradati.istat.it/databrowser/,upptime:/nbbrd/sdmx-upptime/ISTAT,https://nbbrd.github.io/sdmx-upptime/history/istat,"en,it"
NB,Norges Bank,,ri:sdmx21,https://data.norges-bank.no/api,sdmxdl.driver.detailSupported=true,https://www.norges-bank.no/en/topics/Statistics/,upptime:/nbbrd/sdmx-upptime/NB,https://nbbrd.github.io/sdmx-upptime/history/nb,"en,no"
NBB,National Bank of Belgium,,ri:nbb,https://stat.nbb.be/restsdmx/sdmx.ashx,,https://stat.nbb.be,upptime:/nbbrd/sdmx-upptime/NBB,https://nbbrd.github.io/sdmx-upptime/history/nbb,"en,de,fr,nl"
OECD,The Organisation for Economic Co-operation and Development,,ri:dotstat,https://stats.oecd.org/restsdmx/sdmx.ashx,,https://stats.oecd.org,upptime:/nbbrd/sdmx-upptime/OECD,https://nbbrd.github.io/sdmx-upptime/history/oecd,"en,es,fr,it"
SE,Statistics Estonia,,ri:dotstat,http://andmebaas.stat.ee/restsdmx/sdmx.ashx,,http://andmebaas.stat.ee,upptime:/nbbrd/sdmx-upptime/SE,https://nbbrd.github.io/sdmx-upptime/history/se,"en,et"
SGR,SDMX Global Registry,,ri:sdmx21,https://registry.sdmx.org/ws/rest,detailSupported=true,https://registry.sdmx.org/overview.html,upptime:/nbbrd/sdmx-upptime/SGR,https://nbbrd.github.io/sdmx-upptime/history/sgr,en
SIMEL,El Salvador Labor Market Information System,,ri:sdmx21,https://disseminatesimel.mtps.gob.sv/rest,detailSupported=true,https://datasimel.mtps.gob.sv/,upptime:/nbbrd/sdmx-upptime/SIMEL,https://nbbrd.github.io/sdmx-upptime/history/simel,"en,es"
SPC,Pacific Data Hub,,ri:sdmx21,https://stats-nsi-stable.pacificdata.org/rest,detailSupported=true,https://stats.pacificdata.org/?locale=en,upptime:/nbbrd/sdmx-upptime/SPC,https://nbbrd.github.io/sdmx-upptime/history/spc,"en,fr"
STATCAN,Statistics Canada,,ri:statcan,https://www150.statcan.gc.ca/t1/wds/rest,cacheTtl=3600000,https://www150.statcan.gc.ca/n1/en/type/data?MM=1,upptime:/nbbrd/sdmx-upptime/STATCAN,https://nbbrd.github.io/sdmx-upptime/history/statcan,"en,fr"
STATEC,National Institute of statistics and economic studies of the Grand Duchy of Luxembourg,,ri:sdmx21,https://lustat.statec.lu/rest,detailSupported=true,https://lustat.statec.lu,upptime:/nbbrd/sdmx-upptime/STATEC,https://nbbrd.github.io/sdmx-upptime/history/statec,"en,fr"
TNSO,National Statistical Office of Thailand,,ri:sdmx21,https://ns1-oshub.nso.go.th/rest,detailSupported=true,https://oshub.nso.go.th/?lc=en,upptime:/nbbrd/sdmx-upptime/TNSO,https://nbbrd.github.io/sdmx-upptime/history/tnso,"en,th"
SGR,SDMX Global Registry,,ri:sdmx21,https://registry.sdmx.org/ws/rest,sdmxdl.driver.detailSupported=true,https://registry.sdmx.org/overview.html,upptime:/nbbrd/sdmx-upptime/SGR,https://nbbrd.github.io/sdmx-upptime/history/sgr,en
SIMEL,El Salvador Labor Market Information System,,ri:sdmx21,https://disseminatesimel.mtps.gob.sv/rest,sdmxdl.driver.detailSupported=true,https://datasimel.mtps.gob.sv/,upptime:/nbbrd/sdmx-upptime/SIMEL,https://nbbrd.github.io/sdmx-upptime/history/simel,"en,es"
SPC,Pacific Data Hub,,ri:sdmx21,https://stats-nsi-stable.pacificdata.org/rest,sdmxdl.driver.detailSupported=true,https://stats.pacificdata.org/?locale=en,upptime:/nbbrd/sdmx-upptime/SPC,https://nbbrd.github.io/sdmx-upptime/history/spc,"en,fr"
STATCAN,Statistics Canada,,ri:statcan,https://www150.statcan.gc.ca/t1/wds/rest,sdmxdl.driver.cacheTtl=3600000,https://www150.statcan.gc.ca/n1/en/type/data?MM=1,upptime:/nbbrd/sdmx-upptime/STATCAN,https://nbbrd.github.io/sdmx-upptime/history/statcan,"en,fr"
STATEC,National Institute of statistics and economic studies of the Grand Duchy of Luxembourg,,ri:sdmx21,https://lustat.statec.lu/rest,sdmxdl.driver.detailSupported=true,https://lustat.statec.lu,upptime:/nbbrd/sdmx-upptime/STATEC,https://nbbrd.github.io/sdmx-upptime/history/statec,"en,fr"
TNSO,National Statistical Office of Thailand,,ri:sdmx21,https://ns1-oshub.nso.go.th/rest,sdmxdl.driver.detailSupported=true,https://oshub.nso.go.th/?lc=en,upptime:/nbbrd/sdmx-upptime/TNSO,https://nbbrd.github.io/sdmx-upptime/history/tnso,"en,th"
UIS,Unesco Institute for Statistics,,ri:dotstat,http://data.uis.unesco.org/RestSDMX/sdmx.ashx,,http://data.uis.unesco.org,upptime:/nbbrd/sdmx-upptime/UIS,https://nbbrd.github.io/sdmx-upptime/history/uis,"en,fr"
UKDS,UK Data Service,,ri:dotstat,https://stats2.digitalresources.jisc.ac.uk/restsdmx/sdmx.ashx,,https://stats2.digitalresources.jisc.ac.uk/,upptime:/nbbrd/sdmx-upptime/UKDS,https://nbbrd.github.io/sdmx-upptime/history/ukds,en
UNDATA,Data access system to UN databases,,ri:sdmx21,https://data.un.org/WS/rest,detailSupported=true,https://data.un.org/SdmxBrowser/start,upptime:/nbbrd/sdmx-upptime/UNDATA,https://nbbrd.github.io/sdmx-upptime/history/undata,en
UNICEF,UN International Children's Emergency Fund,,ri:sdmx21,https://sdmx.data.unicef.org/ws/public/sdmxapi/rest,detailSupported=true,https://data.unicef.org/,upptime:/nbbrd/sdmx-upptime/UNICEF,https://nbbrd.github.io/sdmx-upptime/history/unicef,en
WB,World Bank,,ri:sdmx21,https://api.worldbank.org/v2/sdmx/rest,"detailSupported=true,trailingSlashRequired=true",https://data.worldbank.org,upptime:/nbbrd/sdmx-upptime/WB,https://nbbrd.github.io/sdmx-upptime/history/wb,"en,es,fr"
WITS,World Integrated Trade Solution,,ri:sdmx21,http://wits.worldbank.org/API/V1/SDMX/V21/rest,trailingSlashRequired=true,https://wits.worldbank.org,upptime:/nbbrd/sdmx-upptime/WITS,https://nbbrd.github.io/sdmx-upptime/history/wits,"en,es"
UNDATA,Data access system to UN databases,,ri:sdmx21,https://data.un.org/WS/rest,sdmxdl.driver.detailSupported=true,https://data.un.org/SdmxBrowser/start,upptime:/nbbrd/sdmx-upptime/UNDATA,https://nbbrd.github.io/sdmx-upptime/history/undata,en
UNICEF,UN International Children's Emergency Fund,,ri:sdmx21,https://sdmx.data.unicef.org/ws/public/sdmxapi/rest,sdmxdl.driver.detailSupported=true,https://data.unicef.org/,upptime:/nbbrd/sdmx-upptime/UNICEF,https://nbbrd.github.io/sdmx-upptime/history/unicef,en
WB,World Bank,,ri:sdmx21,https://api.worldbank.org/v2/sdmx/rest,"sdmxdl.driver.detailSupported=true,sdmxdl.driver.trailingSlash=true",https://data.worldbank.org,upptime:/nbbrd/sdmx-upptime/WB,https://nbbrd.github.io/sdmx-upptime/history/wb,"en,es,fr"
WITS,World Integrated Trade Solution,,ri:sdmx21,http://wits.worldbank.org/API/V1/SDMX/V21/rest,sdmxdl.driver.trailingSlash=true,https://wits.worldbank.org,upptime:/nbbrd/sdmx-upptime/WITS,https://nbbrd.github.io/sdmx-upptime/history/wits,"en,es"
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@

import static org.assertj.core.api.Assertions.*;
import static sdmxdl.Languages.ANY;
import static sdmxdl.web.spi.Driver.DRIVER_PROPERTY_PREFIX;
import static tests.sdmxdl.api.TckUtil.startingWith;

@lombok.experimental.UtilityClass
public class DriverAssert {
Expand All @@ -22,7 +24,7 @@ public void assertCompliance(@NonNull Driver driver) {
.isNotBlank();

assertThat(driver.getDriverProperties())
// .are(startingWith(DRIVER_PROPERTY_PREFIX))
.are(startingWith(DRIVER_PROPERTY_PREFIX))
.doesNotHaveDuplicates();

SdmxWebSource validSource = SdmxWebSource
Expand Down
5 changes: 3 additions & 2 deletions sdmx-dl-cli/src/test/java/_test/FileSample.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package _test;

import sdmxdl.provider.ri.web.drivers.FileDriver;
import sdmxdl.web.SdmxWebSource;
import sdmxdl.format.xml.XmlWebSource;
import tests.sdmxdl.format.xml.SdmxXmlSources;
Expand Down Expand Up @@ -33,13 +34,13 @@ public static File create(Path temp) throws IOException {
return source;
}

private static SdmxWebSource sourceOf(String name, File data, File struct) throws MalformedURLException {
private static SdmxWebSource sourceOf(String name, File data, File struct) {
return SdmxWebSource
.builder()
.id(name)
.driver("ri:file")
.endpoint(data.toURI())
.property("structureURL", struct.toURI().toURL().toString())
.propertyOf(FileDriver.STRUCTURE_URI_PROPERTY, struct.toURI())
.build();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public void testContent(@TempDir Path temp) throws IOException {

assertThat(FileSample.readAll(out))
.contains("Name,SupportedProperties", atIndex(0))
.contains("ri:file,structureURL")
.contains("ri:file,sdmxdl.driver.structureURI")
.hasSizeGreaterThan(2);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,58 +22,60 @@

import java.util.concurrent.TimeUnit;

import static sdmxdl.web.spi.Driver.DRIVER_PROPERTY_PREFIX;

/**
* @author Philippe Charles
*/
@lombok.experimental.UtilityClass
public class WebProperties {
public class DriverProperties {

/**
* Defines the timeout value (in milliseconds) to be used when opening an
* Defines the timeout value (in milliseconds) to be used when opening a
* URL connection. A timeout of zero is interpreted as an infinite timeout.
* Default value is 2 minutes.
*/
public static final IntProperty CONNECT_TIMEOUT_PROPERTY =
IntProperty.of("connectTimeout", (int) TimeUnit.MINUTES.toMillis(2));
IntProperty.of(DRIVER_PROPERTY_PREFIX + ".connectTimeout", (int) TimeUnit.MINUTES.toMillis(2));

/**
* Defines the timeout value (in milliseconds) to be used when reading an
* input stream from an URL connection. A timeout of zero is interpreted as
* input stream from a URL connection. A timeout of zero is interpreted as
* an infinite timeout. Default value is 2 minutes.
*/
public static final IntProperty READ_TIMEOUT_PROPERTY =
IntProperty.of("readTimeout", (int) TimeUnit.MINUTES.toMillis(2));
IntProperty.of(DRIVER_PROPERTY_PREFIX + ".readTimeout", (int) TimeUnit.MINUTES.toMillis(2));

/**
* Defines the duration (in milliseconds) of response storage in the cache.
* A duration of zero is interpreted as an infinite duration. Default value
* is 5 minutes.
*/
public static final LongProperty CACHE_TTL_PROPERTY =
LongProperty.of("cacheTtl", TimeUnit.MINUTES.toMillis(5));
LongProperty.of(DRIVER_PROPERTY_PREFIX + ".cacheTtl", TimeUnit.MINUTES.toMillis(5));

/**
* Defines the max number of redirects to be followed by HTTP client. This
* limit is intended to prevent infinite loop. Default value is 5.
*/
public static final IntProperty MAX_REDIRECTS_PROPERTY =
IntProperty.of("maxRedirects", 5);
IntProperty.of(DRIVER_PROPERTY_PREFIX + ".maxRedirects", 5);

/**
* Defines if detail query is supported. Default value is false.
*/
public static final BooleanProperty DETAIL_SUPPORTED_PROPERTY =
BooleanProperty.of("detailSupported", false);
BooleanProperty.of(DRIVER_PROPERTY_PREFIX + ".detailSupported", false);

/**
* Defines if trailing slash is required in queries. Default value is false.
*/
public static final BooleanProperty TRAILING_SLASH_REQUIRED_PROPERTY =
BooleanProperty.of("trailingSlashRequired", false);
public static final BooleanProperty TRAILING_SLASH_PROPERTY =
BooleanProperty.of(DRIVER_PROPERTY_PREFIX + ".trailingSlash", false);

/**
* Defines if preemptive authentication should be used. Default value is false.
*/
public static final BooleanProperty PREEMPTIVE_AUTHENTICATION_PROPERTY =
BooleanProperty.of("preemptiveAuthentication", false);
public static final BooleanProperty PREEMPTIVE_AUTH_PROPERTY =
BooleanProperty.of(DRIVER_PROPERTY_PREFIX + ".preemptiveAuth", false);
}
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public final class DriverSupport implements Driver {
private final Collection<SdmxWebSource> sources;

@lombok.Singular
private final Collection<String> supportedProperties;
private final Collection<String> properties;

@lombok.NonNull
@lombok.Builder.Default
Expand Down Expand Up @@ -89,14 +89,14 @@ public boolean isDriverAvailable() {

@Override
public @NonNull Collection<String> getDriverProperties() {
return supportedProperties;
return properties;
}

public static final class Builder {

@NonNull
public Builder supportedPropertyOf(@NonNull CharSequence property) {
return supportedProperty(property.toString());
public Builder propertyOf(@NonNull CharSequence property) {
return property(property.toString());
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

import java.io.IOException;

import static sdmxdl.provider.web.WebProperties.CACHE_TTL_PROPERTY;
import static sdmxdl.provider.web.DriverProperties.CACHE_TTL_PROPERTY;

@lombok.Builder
public final class RestConnector implements WebConnector {
Expand Down
Loading

0 comments on commit 66790d3

Please sign in to comment.