Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
checkpoint
  • Loading branch information
bmaidics committed Apr 17, 2024
commit b4a581c6a54a01621c7786f87e5682eef48bcafb
6 changes: 6 additions & 0 deletions cloud/docker-image/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,12 @@
<version>${project.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>catalog-filesystem</artifactId>
<version>${project.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>catalog-inline</artifactId>
Expand Down
1 change: 1 addition & 0 deletions cloud/docker-image/src/main/docker/zpm.json.template
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
"io.aklivity.zilla:binding-tls",
"io.aklivity.zilla:binding-ws",
"io.aklivity.zilla:catalog-apicurio",
"io.aklivity.zilla:catalog-filesystem",
"io.aklivity.zilla:catalog-inline",
"io.aklivity.zilla:catalog-karapace",
"io.aklivity.zilla:common",
Expand Down
5 changes: 5 additions & 0 deletions incubator/catalog-filesystem.spec/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,11 @@
<plugin>
<groupId>com.mycila</groupId>
<artifactId>license-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/mqtt.yaml</exclude>
</excludes>
</configuration>
</plugin>
<plugin>
<artifactId>maven-checkstyle-plugin</artifactId>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
asyncapi: 3.0.0
info:
title: Zilla MQTT Proxy
version: 1.0.0
license:
name: Aklivity Community License
servers:
plain:
host: mqtt://localhost:7183
protocol: mqtt
defaultContentType: application/json
Comment thread
bmaidics marked this conversation as resolved.
Outdated
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,8 @@ catalogs:
catalog0:
type: filesystem
options:
max-age: 30
subjects:
subject1:
url: asyncapi/mqtt.yaml
version: latest

Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,15 @@ telemetry:
events:
- qname: test.catalog0
id: catalog.filesystem.file.not.found
message: FILE_NOT_FOUND GET asyncapi.yaml 0
message: FILE_NOT_FOUND asyncapi/kafka.yaml
catalogs:
catalog0:
type: filesystem
options:
subjects:
subject1:
url: asyncapi/kafka.yaml
version: latest
bindings:
net0:
type: test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,34 @@
{
"properties":
{
"url":
"subjects":
{
"type": "string"
},
"max-age":
{
"title": "Max Age",
"type": "number",
"default": 300
"type": "object",
"patternProperties":
{
"^[a-zA-Z]+[a-zA-Z0-9\\._\\-]*$":
{
"title": "Subject",
"type": "object",
"properties":
{
"url":
Comment thread
bmaidics marked this conversation as resolved.
Outdated
{
"type": "string"
},
"version":
{
"type": "string",
"default": "latest"
}
},
"required":
[
"url"
],
"additionalProperties": false
}
}
}
},
"additionalProperties": false
Expand Down
28 changes: 23 additions & 5 deletions incubator/catalog-filesystem/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
<version>${project.version}</version>
<configuration>
<scopeNames>core filesystem internal</scopeNames>
<packageName>io.aklivity.zilla.incubator.catalog.filesystem.internal.types</packageName>
<packageName>io.aklivity.zilla.runtime.catalog.filesystem.internal.types</packageName>
</configuration>
<executions>
<execution>
Expand Down Expand Up @@ -109,16 +109,34 @@
<artifactId>catalog-filesystem.spec</artifactId>
<fileMappers>
<org.codehaus.plexus.components.io.filemappers.RegExpFileMapper>
<pattern>^\Qio/aklivity/zilla/incubator/catalog/filesystem/\E</pattern>
<replacement>io/aklivity/zilla/incubator/catalog/filesystem/internal/</replacement>
<pattern>^\Qio/aklivity/zilla/specs/catalog/filesystem/\E</pattern>
<replacement>io/aklivity/zilla/runtime/catalog/filesystem/internal/</replacement>
</org.codehaus.plexus.components.io.filemappers.RegExpFileMapper>
</fileMappers>
</artifactItem>
</artifactItems>
<includes>io/aklivity/zilla/incubator/catalog/filesystem/schema/filesystem.schema.patch.json</includes>
<includes>io/aklivity/zilla/specs/catalog/filesystem/schema/filesystem.schema.patch.json</includes>
<outputDirectory>${project.build.directory}/classes</outputDirectory>
</configuration>
</execution>
<execution>
<id>unpack-asyncapi</id>
<phase>generate-sources</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>${project.groupId}</groupId>
<artifactId>catalog-filesystem.spec</artifactId>
<version>${project.version}</version>
<outputDirectory>${basedir}/target/test-classes</outputDirectory>
<includes>**\/*.yaml</includes>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
Expand All @@ -142,7 +160,7 @@
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>io/aklivity/zilla/incubator/catalog/filesystem/internal/types/**/*.class</exclude>
<exclude>io/aklivity/zilla/runtime/catalog/filesystem/internal/types/**/*.class</exclude>
</excludes>
<rules>
<rule>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,6 @@ public CatalogContext supply(
@Override
public URL type()
{
return getClass().getResource("schema/apicurio.schema.patch.json");
return getClass().getResource("schema/filesystem.schema.patch.json");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
*/
package io.aklivity.zilla.runtime.catalog.filesystem.internal;

import io.aklivity.zilla.runtime.catalog.filesystem.internal.config.FilesystemOptionsConfig;
import io.aklivity.zilla.runtime.engine.EngineContext;
import io.aklivity.zilla.runtime.engine.catalog.CatalogContext;
import io.aklivity.zilla.runtime.engine.catalog.CatalogHandler;
Expand All @@ -33,6 +34,7 @@ public FilesystemCatalogContext(
public CatalogHandler attach(
CatalogConfig catalog)
{
return new FilesystemCatalogHandler(FilesystemOptionsConfig.class.cast(catalog.options), context, catalog.id);
return new FilesystemCatalogHandler(
FilesystemOptionsConfig.class.cast(catalog.options), context, catalog.id, catalog.readURL);
}
}
Loading