diff --git a/README.md b/README.md index 10956b9..8167af6 100644 --- a/README.md +++ b/README.md @@ -161,7 +161,7 @@ In this case the IP address is one of the nodes running the distributed mode wor { "class": "com.solace.connector.kafka.connect.sink.SolaceSinkConnector", "type": "sink", - "version": "3.0.0" + "version": "3.0.1" }, ``` diff --git a/build.gradle b/build.gradle index c72c894..9265db0 100644 --- a/build.gradle +++ b/build.gradle @@ -76,6 +76,16 @@ spotbugs { reportLevel 'high' // Decrease to medium once medium errors are fixed } +// Generate manifest.json file to be compliant with Confluent Hub client +tasks.register('generateConfluentConnectManifest', Copy) { + def templateContext = [ + "project": project.properties + ] + from 'src/template/manifest' + into "${buildDir}/generated/manifest" + expand templateContext +} + spotbugsIntegrationTest { enabled = false } @@ -116,13 +126,13 @@ project.integrationTest { maxRetries = 3 } afterSuite { desc, result -> - if (!desc.parent) - println("${result.resultType} " + - "(${result.testCount} tests, " + - "${result.successfulTestCount} successes, " + - "${result.failedTestCount} failures, " + - "${result.skippedTestCount} skipped)") - } + if (!desc.parent) + println("${result.resultType} " + + "(${result.testCount} tests, " + + "${result.successfulTestCount} successes, " + + "${result.failedTestCount} failures, " + + "${result.skippedTestCount} skipped)") + } } project.test { @@ -167,7 +177,7 @@ task('pmdMainSarif') { } Provider reportsDir = project.getLayout() - .file(project.getProviders().provider({a -> extension.getReportsDir()}) as Provider) + .file(project.getProviders().provider({ a -> extension.getReportsDir() }) as Provider) formatter(type: 'sarif', toFile: new File(reportsDir.get().getAsFile(), 'main.sarif')) formatter(type: 'html', toFile: new File(reportsDir.get().getAsFile(), 'main.html')) @@ -230,6 +240,7 @@ distributions { from('doc/distribution-readme.md') { into 'doc' } from('LICENSE') { into 'doc' } from('THIRD-PARTY-LICENSES') { into 'doc' } + from(generateConfluentConnectManifest) {into ''} into('lib') { from jar from(project.configurations.runtimeClasspath) @@ -310,7 +321,7 @@ signing { tasks.withType(Sign) { onlyIf { - gradle.taskGraph.allTasks.any {task -> + gradle.taskGraph.allTasks.any { task -> task.name.startsWith("publish") && task.name.contains('Sonatype') } } diff --git a/doc/distribution-readme.md b/doc/distribution-readme.md index 582ac26..3d7f4b2 100644 --- a/doc/distribution-readme.md +++ b/doc/distribution-readme.md @@ -8,4 +8,5 @@ Package directory contents: - doc: this readme and license information - lib: Sink Connector jar file and dependencies -- etc: sample configuration properties and JSON file +- etc: sample configuration properties and JSON file +- manifest.json: manifest file for kafka-connect to be installable via confluent-hub client diff --git a/gradle.properties b/gradle.properties index f4bdd6f..67e1778 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,2 +1,2 @@ group=com.solace.connector.kafka.connect -version=3.0.0 \ No newline at end of file +version=3.0.1 \ No newline at end of file diff --git a/src/template/manifest/manifest.json b/src/template/manifest/manifest.json new file mode 100644 index 0000000..dec38fc --- /dev/null +++ b/src/template/manifest/manifest.json @@ -0,0 +1,43 @@ +{ + "component_types": [ + "sink" + ], + "description": "The PubSub+ Kafka Sink Connector consumes Kafka topic records and streams them to the PubSub+ Event Mesh as topic and/or queue data events.", + "documentation_url": "https://github.com/SolaceProducts/pubsubplus-connector-kafka-sink", + "features": { + "confluent_control_center_integration": false, + "kafka_connect_api": true, + "single_message_transforms": true, + "supported_encodings": [ + "any" + ] + }, + "license": [ + { + "name": "Apache License, Version 2.0", + "url": "https://github.com/SolaceProducts/pubsubplus-connector-kafka-sink/blob/master/LICENSE" + } + ], + "name": "${project.name}", + "owner": { + "name": "Solace", + "type": "organization", + "url": "https://solace.community", + "username": "solace" + }, + "release_date": "${new Date().format('yyyy-MM-dd')}", + "source_url": "https://github.com/SolaceProducts/pubsubplus-connector-kafka-sink", + "support": { + "provider_name": "Solace", + "summary": "", + "url": "https://github.com/SolaceProducts/pubsubplus-connector-kafka-sink/issues" + }, + "tags": [ + "solace", + "kafka", + "sink", + "connector" + ], + "title": "Solace PubSub+ Connector for Kafka: Sink", + "version": "${project.version}" +} \ No newline at end of file