Skip to content

Commit 8f61e1d

Browse files
authored
Merge pull request #828 from TNO/102-remove-all-tno-references-ie-kb-ontology-uri
102 remove all tno references ie kb ontology uri
2 parents 342b6df + 3ffcdaf commit 8f61e1d

64 files changed

Lines changed: 662 additions & 1044 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ nohup java -cp "smart-connector-rest-dist-1.4.0.jar:dependency/*" eu.knowledge.e
254254
The Knowledge Engine can also start in distributed mode, where it connects with a remote knowledge directory and where different instances of the Knowledge Engine (each instance hosting one or more smart connectors) can communicate with each other. More information about starting the Knowledge Engine in distributed mode can be found in the [documentation](docs/docs/distributed_mode.md).
255255

256256
### Configuration
257-
TNO Knowledge Engine uses the [MicroProfile Config 3.1](https://microprofile.io/specifications/config/) specification to configure its behaviour and we use [SmallRye](https://smallrye.io/smallrye-config/) as the implementation of this specification. The default configuration values can be found in the [microprofile-config.properties](./smart-connector/src/main/resources/META-INF/microprofile-config.properties) configuration file. And, as described in the specification, these configuration values can be overridden by [environment variables and system properties](https://download.eclipse.org/microprofile/microprofile-config-3.1/microprofile-config-spec-3.1.html#default_configsources). Note that environment variables can use underscores and capital letters to adhere to their naming conventions and the MicroProfile Config automatically maps those to corresponding configuration properties using [specific rules](https://download.eclipse.org/microprofile/microprofile-config-3.1/microprofile-config-spec-3.1.html#default_configsources.env.mapping).
257+
Knowledge Engine uses the [MicroProfile Config 3.1](https://microprofile.io/specifications/config/) specification to configure its behaviour and we use [SmallRye](https://smallrye.io/smallrye-config/) as the implementation of this specification. The default configuration values can be found in the [microprofile-config.properties](./smart-connector/src/main/resources/META-INF/microprofile-config.properties) configuration file. And, as described in the specification, these configuration values can be overridden by [environment variables and system properties](https://download.eclipse.org/microprofile/microprofile-config-3.1/microprofile-config-spec-3.1.html#default_configsources). Note that environment variables can use underscores and capital letters to adhere to their naming conventions and the MicroProfile Config automatically maps those to corresponding configuration properties using [specific rules](https://download.eclipse.org/microprofile/microprofile-config-3.1/microprofile-config-spec-3.1.html#default_configsources.env.mapping).
258258

259259
A description of all configuration properties can be found in the [`SmartConnectorConfig`](./smart-connector-api/src/main/java/eu/knowledge/engine/smartconnector/api/SmartConnectorConfig.java) class. The rest of this section highlights some of these configuration properties.
260260

admin-ui/src/main/resources/example_result.json

Lines changed: 0 additions & 306 deletions
This file was deleted.

admin-ui/src/test/java/eu/knowledge/engine/admin/TestUtils.java

Lines changed: 0 additions & 27 deletions
This file was deleted.

admin-ui/src/test/java/eu/knowledge/engine/admin/api/TestApiRoutes.java

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -159,8 +159,13 @@ public void testConnections() throws InterruptedException {
159159

160160
assertNotNull(list);
161161
assertEquals(2, list.size());
162-
assertEquals(0, list.get(0).getKnowledgeInteractions().get(0).getConnections().size());
163-
assertEquals(1, list.get(1).getKnowledgeInteractions().get(0).getConnections().size());
162+
163+
for (eu.knowledge.engine.admin.model.SmartConnector sc : list)
164+
if (sc.getKnowledgeBaseId().equals("https://www.example.org/kb1"))
165+
assertEquals(0, sc.getKnowledgeInteractions().get(0).getConnections().size());
166+
else if (sc.getKnowledgeBaseId().equals("https://www.example.org/kb2"))
167+
assertEquals(1, sc.getKnowledgeInteractions().get(0).getConnections().size());
168+
164169
assertEquals(200, response.statusCode());
165170

166171
} catch (IOException | InterruptedException | URISyntaxException e) {
@@ -247,7 +252,7 @@ public void cleanup() {
247252
public void startKbs() throws InterruptedException {
248253
PrefixMappingMem prefixes = new PrefixMappingMem();
249254
prefixes.setNsPrefixes(PrefixMapping.Standard);
250-
prefixes.setNsPrefix("ex", "https://www.tno.nl/example/");
255+
prefixes.setNsPrefix("ex", "https://www.example.org/example/");
251256
kb1 = null;
252257
int wait = 2;
253258
final CountDownLatch kb2ReceivedData = new CountDownLatch(1);
@@ -259,16 +264,16 @@ public void smartConnectorReady(SmartConnector aSC) {
259264
}
260265
};
261266

262-
GraphPattern gp1 = new GraphPattern(prefixes, "?a <https://www.tno.nl/example/b> ?c.");
267+
GraphPattern gp1 = new GraphPattern(prefixes, "?a <https://www.example.org/example/b> ?c.");
263268
AnswerKnowledgeInteraction aKI = new AnswerKnowledgeInteraction(new CommunicativeAct(), gp1);
264269
kb1.register(aKI, (AnswerHandler) (anAKI, anAnswerExchangeInfo) -> {
265270
assertTrue(anAnswerExchangeInfo.getIncomingBindings().isEmpty(),
266271
"Should not have bindings in this binding set.");
267272

268273
BindingSet bindingSet = new BindingSet();
269274
Binding binding = new Binding();
270-
binding.put("a", "<https://www.tno.nl/example/a>");
271-
binding.put("c", "<https://www.tno.nl/example/c>");
275+
binding.put("a", "<https://www.example.org/example/a>");
276+
binding.put("c", "<https://www.example.org/example/c>");
272277
bindingSet.add(binding);
273278

274279
return bindingSet;
@@ -288,7 +293,7 @@ public void smartConnectorReady(SmartConnector aSC) {
288293

289294
};
290295

291-
GraphPattern gp2 = new GraphPattern(prefixes, "?x <https://www.tno.nl/example/b> ?y.");
296+
GraphPattern gp2 = new GraphPattern(prefixes, "?x <https://www.example.org/example/b> ?y.");
292297
AskKnowledgeInteraction askKI = new AskKnowledgeInteraction(new CommunicativeAct(), gp2);
293298

294299
kb2.register(askKI);

0 commit comments

Comments
 (0)