diff --git a/.gitignore b/.gitignore index e75c88cf..a7721135 100644 --- a/.gitignore +++ b/.gitignore @@ -54,3 +54,12 @@ buildNumber.properties # Mac .DS_Store + +# Eclipse +asyncapi-plugin/asyncapi-plugin-maven/.settings/org.eclipse.jdt.core.prefs +asyncapi-plugin/asyncapi-plugin-maven/.project +asyncapi-plugin/.project +asyncapi-core/.project +.vscode/settings.json +asyncapi-core/.settings/org.eclipse.jdt.core.prefs +.project diff --git a/.idea/compiler.xml b/.idea/compiler.xml index 4b90cc4b..357c521d 100644 --- a/.idea/compiler.xml +++ b/.idea/compiler.xml @@ -8,8 +8,6 @@ - - diff --git a/.idea/gradle.xml b/.idea/gradle.xml deleted file mode 100644 index 88201fca..00000000 --- a/.idea/gradle.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - - - - \ No newline at end of file diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml index d20b5975..33ddc2f8 100644 --- a/.idea/jarRepositories.xml +++ b/.idea/jarRepositories.xml @@ -3,13 +3,8 @@ - - + + + + \ No newline at end of file diff --git a/.idea/kotlinc.xml b/.idea/kotlinc.xml new file mode 100644 index 00000000..2b8a50fc --- /dev/null +++ b/.idea/kotlinc.xml @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/.sdkmanrc b/.sdkmanrc new file mode 100644 index 00000000..b9c96b0b --- /dev/null +++ b/.sdkmanrc @@ -0,0 +1,2 @@ +java=8.0.362-amzn +maven=3.9.0 \ No newline at end of file diff --git a/README.md b/README.md index 5de158f9..db0a567e 100644 --- a/README.md +++ b/README.md @@ -1,91 +1,46 @@ -

-
- AsyncAPI logo -

-

Building the future of event-driven architectures

-
We're on a mission to standardize message-based communication and increase interoperability of the different systems out there.
+[![AsyncAPI Logo](./assets/logo.png)](https://www.asyncapi.com) -> ⚠️ This project doesn't support AsyncAPI 1.x - -This monorepo stores modules, which simplifies interacting with AsyncAPI in `jvm` ecosystem. +

Building the future of event-driven architectures

+
We're on a mission to standardize message-based communication and increase interoperability of the different systems out there.
-# Index +--- +> ⚠️ This project doesn't support AsyncAPI 1.x +--- -* [Monorepo structure](#monorepo-structure) - * [core](#core) - * [plugin](#plugin) -* [Release](#release) - * [maven artifacts](#release-maven-artifacts) - * [gradle artifacts](#release-gradle-artifacts) - * [relese to maven central](#release-to-maven-central) - * [release to gradle plugins](#release-to-gradle-plugins) +[![Version](https://img.shields.io/maven-central/v/com.asyncapi/asyncapi-core?logo=apache-maven)](https://search.maven.org/artifact/io.quarkiverse.asyncapi/quarkus-asyncapi) -## Monorepo structure -Currently here it's splitted on two submodules: -* [core](#core) -* [plugin](#plugin) +## Overview +JVM-friendly bindings for AsyncAPI. It allows you to read or write specifications for your asynchronous API through code -### core -This submodule stores projection of AsyncAPI specification to java classes. Each class is being properly annotated with `jsr-305` annotations, -which allows to use it in null-safety languages like `kotlin` without extra headache. +Hints: +- If you are working with AsyncAPI specification in JetBrains IDE, check out our [AsyncAPI - IDEA plugin](https://github.com/asyncapi/jasyncapi-idea-plugin) +- If you are working with AsyncAPI specification in VSCode, check out our [AsyncAPI - VSCode plugin](https://github.com/asyncapi/vs-asyncapi-preview) -``` - - com.asyncapi - asyncapi-core - 1.0.0-EAP - -``` +## Known consumers: +- [Springwolf Core](https://github.com/springwolf/springwolf-core) - Automated documentation for async APIs built with Spring Boot +- [AsyncAPI Quarkus](https://github.com/quarkiverse/quarkus-asyncapi) - Generates AsyncAPIRegistry and configuration classes for Quarkus -### plugin -This submodule stores plugins, which automatizes work with AsyncAPI specification. +## Contributors section -Currently here are three plugins: -* [maven plugin](#maven) -* [gradle plugin](#gradle) -* [IDEA plugin](#idea) +### Build -#### maven -Maven plugin helps to generate AsyncAPI specification from hand-crafted AsyncAPI class at choosed build cycle step. +#### Prerequisites +1. JDK 1.8 +2. Maven 3+ +If you are using SDKMAN! use [env](https://sdkman.io/usage#env) to prepare environment +```shell +sdk env ``` - - com.asyncapi - asyncapi-maven-plugin - 1.0.0-EAP - maven-plugin - -``` - -**[Source code with description and example](asyncapi-plugin/asyncapi-plugin-maven)** - -#### gradle -Gradle plugin helps to generate AsyncAPI specification from hand-crafted AsyncAPI class at choosed build cycle step. - -**[Source code with description and example](asyncapi-plugin/asyncapi-plugin-gradle)** -#### IDEA -IDEA plugin simplifies work with AsyncAPI specification not only in Intellij IDEA, but in others IDE from JetBrains +### Publish new release -[JetBrains plugin marketplace](https://plugins.jetbrains.com/plugin/15673-asyncapi) +#### Prerequisites +1. Request credentials for one of AsyncAPI's account on [Sonatype Jira](https://issues.sonatype.org), which is synced + with [Sonatype nexus](https://oss.sonatype.org) +2. Generate pgp key if it was not generated yet +3. Create `/Users/{userName}/.m2/settings.xml` -**[Source code with description and example](asyncapi-plugin/asyncapi-plugin-idea)** - -## Release - -**[Sonatype Instruction with references and clarifications](https://central.sonatype.org/pages/apache-maven.html)** - -**⚠️ WARNING: next artifacts MUST always have common version at release. Because of dependency of plugins from core** -* **[asyncapi-core](./asyncapi-core)** -* **[asyncapi-plugin-maven](./asyncapi-plugin/asyncapi-plugin-maven)** -* **[asyncapi-plugin-gradle](./asyncapi-plugin/asyncapi-plugin-gradle)** - -### Release maven artifacts: - -* Request credentials for one of AsyncAPI's account on [Sonatype's Jira](https://issues.sonatype.org), which is synced -with [Sonatype's nexus](https://oss.sonatype.org) -* Generate pgp key if it was not generated yet -* Create `/Users/{userName}/.m2/settings.xml` ```xml @@ -112,101 +67,11 @@ with [Sonatype's nexus](https://oss.sonatype.org) ``` -* Choose new release version and set it to root [pom.xml](./pom.xml). - -_Example:_ -```xml - - - 4.0.0 - - com.asyncapi - asyncapi - {new release version} - - - - -``` - -* Don't forget to update parent version in all submodules. - * [asyncapi-core](./asyncapi-core/pom.xml) - * [asyncapi-plugin](./asyncapi-plugin/pom.xml) - * [asyncapi-plugin-core](./asyncapi-plugin/asyncapi-plugin-core/pom.xml) - * [asyncapi-plugin-maven](./asyncapi-plugin/asyncapi-plugin-maven/pom.xml) - -_Example_ -```xml - - - - asyncapi-plugin - com.asyncapi - {new release version} - - - - - -``` - -* Build it, test it and release it to maven central repository -```shell script -➜ async-api git:(1.0.0-EAP) ✗ mvn clean deploy -P release +Release +```shell +mvn clean deploy -P release ``` -### Release gradle artifacts: - -#### release to maven central -**[gradle gpg instruction](https://docs.gradle.org/current/userguide/signing_plugin.html#signing_plugin)** -
-**[sonatype's instruction for deployment releasing](https://central.sonatype.org/pages/releasing-the-deployment.html)** - -* Request credentials for one of AsyncAPI's account on [Sonatype's Jira](https://issues.sonatype.org), which is synced -with [Sonatype's nexus](https://oss.sonatype.org) -* Generate pgp key if it was not generated yet - * export secret key ring file containing your private key - ```shell script - gpg --keyring secring.gpg --export-secret-keys > ~/.gnupg/secring.gpg - ``` -* Create `/Users/{userName}/.gradle/gradle.properties` -```properties -# gpg -signing.keyId={key name} -signing.password={key passphrase} -signing.secretKeyRingFile=/Users/{userName}/.gnupg/secring.gpg - -# oss.sonatype.org -ossrhUsername={Jira username} -ossrhPassword={Jira password} -``` -* Choose new release version and set it to root [build.gradle.kts](./asyncapi-plugin/asyncapi-plugin-gradle/build.gradle.kts). -_Example_ -```kotlin -version = "{new release version}" -``` -* Build it, test it and release it to maven central repository -```shell script -➜ asyncapi-plugin-gradle git:(1.0.0-EAP) ✗ ./gradlew publishPluginMavenPublicationToMavenRepository -``` -* Go to [stagin repositories](https://oss.sonatype.org/#stagingRepositories) and release it manually - * Select repository - * Click `close` and wait some time - * Click `release` - -#### release to gradle plugins - -* Request `key` and `secret` for gradle account -* Update `/Users/{userName}/.gradle/gradle.properties` with gradle credential -```properties -gradle.publish.key={key} -gradle.publish.secret={secret} -``` -* Release plugin to [gradle plugins](https://plugins.gradle.org/) -```shell script -➜ asyncapi-plugin-gradle git:(1.0.0-EAP) ✗ ./gradlew publishPlugins -``` \ No newline at end of file +references: +- [Sonatype Instruction with references and clarifications](https://central.sonatype.org/pages/apache-maven.html) +- [Sonatype Instruction for deployment releasing](https://central.sonatype.org/pages/releasing-the-deployment.html) \ No newline at end of file diff --git a/assets/logo.png b/assets/logo.png index dce43812..a1b53667 100644 Binary files a/assets/logo.png and b/assets/logo.png differ diff --git a/asyncapi-core/asyncapi-core.iml b/asyncapi-core/asyncapi-core.iml index 390a3d87..c65d84c6 100644 --- a/asyncapi-core/asyncapi-core.iml +++ b/asyncapi-core/asyncapi-core.iml @@ -1,5 +1,5 @@ - +