-
-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
33 changed files
with
581 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
asyncapi-core/src/main/java/com/asyncapi/bindings/sns/SNSChannelBinding.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package com.asyncapi.bindings.sns; | ||
|
||
import com.asyncapi.bindings.ChannelBinding; | ||
import com.fasterxml.jackson.annotation.JsonSubTypes; | ||
import com.fasterxml.jackson.annotation.JsonTypeInfo; | ||
import lombok.Data; | ||
import lombok.EqualsAndHashCode; | ||
|
||
/** | ||
* This class MUST NOT contain any properties. Its name is reserved for future use. | ||
* <p> | ||
* Describes SNS channel binding. | ||
* | ||
* @version 0.1.0 | ||
* @see <a href="https://github.com/asyncapi/bindings/tree/master/sns#channel-binding-object">SNS channel binding</a> | ||
* @author Pavel Bodiachevskii | ||
*/ | ||
@JsonTypeInfo( | ||
use = JsonTypeInfo.Id.NAME, | ||
include = JsonTypeInfo.As.EXISTING_PROPERTY, | ||
defaultImpl = com.asyncapi.bindings.sns.v0._1_0.channel.SNSChannelBinding.class, | ||
property = "bindingVersion", | ||
visible = true | ||
) | ||
@JsonSubTypes({ | ||
@JsonSubTypes.Type(value = com.asyncapi.bindings.sns.v0._1_0.channel.SNSChannelBinding.class, names = { | ||
"0.1.0", | ||
"latest" | ||
}), | ||
}) | ||
@Data | ||
@EqualsAndHashCode(callSuper = true) | ||
public abstract class SNSChannelBinding extends ChannelBinding {} |
33 changes: 33 additions & 0 deletions
33
asyncapi-core/src/main/java/com/asyncapi/bindings/sns/SNSMessageBinding.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package com.asyncapi.bindings.sns; | ||
|
||
import com.asyncapi.bindings.MessageBinding; | ||
import com.fasterxml.jackson.annotation.JsonSubTypes; | ||
import com.fasterxml.jackson.annotation.JsonTypeInfo; | ||
import lombok.Data; | ||
import lombok.EqualsAndHashCode; | ||
|
||
/** | ||
* This class MUST NOT contain any properties. Its name is reserved for future use. | ||
* <p> | ||
* Describes SNS message binding. | ||
* | ||
* @version 0.1.0 | ||
* @see <a href="https://github.com/asyncapi/bindings/tree/master/sns#message-binding-object">SNS message binding</a> | ||
* @author Pavel Bodiachevskii | ||
*/ | ||
@JsonTypeInfo( | ||
use = JsonTypeInfo.Id.NAME, | ||
include = JsonTypeInfo.As.EXISTING_PROPERTY, | ||
defaultImpl = com.asyncapi.bindings.sns.v0._1_0.message.SNSMessageBinding.class, | ||
property = "bindingVersion", | ||
visible = true | ||
) | ||
@JsonSubTypes({ | ||
@JsonSubTypes.Type(value = com.asyncapi.bindings.sns.v0._1_0.message.SNSMessageBinding.class, names = { | ||
"0.1.0", | ||
"latest" | ||
}), | ||
}) | ||
@Data | ||
@EqualsAndHashCode(callSuper = true) | ||
public abstract class SNSMessageBinding extends MessageBinding {} |
33 changes: 33 additions & 0 deletions
33
asyncapi-core/src/main/java/com/asyncapi/bindings/sns/SNSOperationBinding.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package com.asyncapi.bindings.sns; | ||
|
||
import com.asyncapi.bindings.OperationBinding; | ||
import com.fasterxml.jackson.annotation.JsonSubTypes; | ||
import com.fasterxml.jackson.annotation.JsonTypeInfo; | ||
import lombok.Data; | ||
import lombok.EqualsAndHashCode; | ||
|
||
/** | ||
* This class MUST NOT contain any properties. Its name is reserved for future use. | ||
* <p> | ||
* Describes SNS operation binding. | ||
* | ||
* @version 0.1.0 | ||
* @see <a href="https://github.com/asyncapi/bindings/tree/master/sns#operation-binding-object">SNS operation binding</a> | ||
* @author Pavel Bodiachevskii | ||
*/ | ||
@JsonTypeInfo( | ||
use = JsonTypeInfo.Id.NAME, | ||
include = JsonTypeInfo.As.EXISTING_PROPERTY, | ||
defaultImpl = com.asyncapi.bindings.sns.v0._1_0.operation.SNSOperationBinding.class, | ||
property = "bindingVersion", | ||
visible = true | ||
) | ||
@JsonSubTypes({ | ||
@JsonSubTypes.Type(value = com.asyncapi.bindings.sns.v0._1_0.operation.SNSOperationBinding.class, names = { | ||
"0.1.0", | ||
"latest" | ||
}), | ||
}) | ||
@Data | ||
@EqualsAndHashCode(callSuper = true) | ||
public abstract class SNSOperationBinding extends OperationBinding {} |
33 changes: 33 additions & 0 deletions
33
asyncapi-core/src/main/java/com/asyncapi/bindings/sns/SNSServerBinding.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package com.asyncapi.bindings.sns; | ||
|
||
import com.asyncapi.bindings.ServerBinding; | ||
import com.fasterxml.jackson.annotation.JsonSubTypes; | ||
import com.fasterxml.jackson.annotation.JsonTypeInfo; | ||
import lombok.Data; | ||
import lombok.EqualsAndHashCode; | ||
|
||
/** | ||
* This class MUST NOT contain any properties. Its name is reserved for future use. | ||
* <p> | ||
* Describes SNS server binding. | ||
* | ||
* @version 0.1.0 | ||
* @see <a href="https://github.com/asyncapi/bindings/tree/master/sns#server-binding-object">SNS server binding</a> | ||
* @author Pavel Bodiachevskii | ||
*/ | ||
@JsonTypeInfo( | ||
use = JsonTypeInfo.Id.NAME, | ||
include = JsonTypeInfo.As.EXISTING_PROPERTY, | ||
defaultImpl = com.asyncapi.bindings.sns.v0._1_0.server.SNSServerBinding.class, | ||
property = "bindingVersion", | ||
visible = true | ||
) | ||
@JsonSubTypes({ | ||
@JsonSubTypes.Type(value = com.asyncapi.bindings.sns.v0._1_0.server.SNSServerBinding.class, names = { | ||
"0.1.0", | ||
"latest" | ||
}), | ||
}) | ||
@Data | ||
@EqualsAndHashCode(callSuper = true) | ||
public abstract class SNSServerBinding extends ServerBinding {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
asyncapi-core/src/test/kotlin/com/asyncapi/bindings/sns/SNS.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package com.asyncapi.bindings.sns; | ||
|
||
import org.junit.platform.suite.api.SelectPackages; | ||
import org.junit.platform.suite.api.Suite; | ||
import org.junit.platform.suite.api.SuiteDisplayName; | ||
|
||
@Suite | ||
@SuiteDisplayName("SNS") | ||
@SelectPackages("com.asyncapi.bindings.sns") | ||
public class SNS { | ||
} |
54 changes: 54 additions & 0 deletions
54
asyncapi-core/src/test/kotlin/com/asyncapi/bindings/sns/SNSLatestTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
package com.asyncapi.bindings.sns; | ||
|
||
import com.asyncapi.bindings.BindingTest; | ||
import com.asyncapi.bindings.sns.v0._1_0.channel.SNSChannelBinding; | ||
import com.asyncapi.bindings.sns.v0._1_0.message.SNSMessageBinding; | ||
import com.asyncapi.bindings.sns.v0._1_0.operation.SNSOperationBinding; | ||
import com.asyncapi.bindings.sns.v0._1_0.server.SNSServerBinding; | ||
import org.junit.jupiter.api.DisplayName; | ||
import org.junit.jupiter.api.Nested; | ||
|
||
@DisplayName("latest") | ||
public class SNSLatestTest { | ||
|
||
@Nested | ||
@DisplayName("channel") | ||
class ChannelTest extends BindingTest<SNSChannelBinding> {{ | ||
super.binding = SNSV0_1_0Test.channelBinding(); | ||
super.bindingTypeClass = SNSChannelBinding.class; | ||
super.pathToBindingJson = "/bindings/default implementation/latest/channel/binding.json"; | ||
super.pathToExtendedBindingJson = "/bindings/default implementation/latest/channel/binding - extended.json"; | ||
super.pathToWronglyExtendedBindingJson = "/bindings/default implementation/latest/channel/binding - wrongly extended.json"; | ||
}} | ||
|
||
@Nested | ||
@DisplayName("message") | ||
class Message extends BindingTest<SNSMessageBinding> {{ | ||
super.binding = SNSV0_1_0Test.messageBinding(); | ||
super.bindingTypeClass = SNSMessageBinding.class; | ||
super.pathToBindingJson = "/bindings/default implementation/latest/message/binding.json"; | ||
super.pathToExtendedBindingJson = "/bindings/default implementation/latest/message/binding - extended.json"; | ||
super.pathToWronglyExtendedBindingJson = "/bindings/default implementation/latest/message/binding - wrongly extended.json"; | ||
}} | ||
|
||
@Nested | ||
@DisplayName("operation") | ||
class Operation extends BindingTest<SNSOperationBinding> {{ | ||
super.binding = SNSV0_1_0Test.operationBinding(); | ||
super.bindingTypeClass = SNSOperationBinding.class; | ||
super.pathToBindingJson = "/bindings/default implementation/latest/operation/binding.json"; | ||
super.pathToExtendedBindingJson = "/bindings/default implementation/latest/operation/binding - extended.json"; | ||
super.pathToWronglyExtendedBindingJson = "/bindings/default implementation/latest/operation/binding - wrongly extended.json"; | ||
}} | ||
|
||
@Nested | ||
@DisplayName("server") | ||
class Server extends BindingTest<SNSServerBinding> {{ | ||
super.binding = SNSV0_1_0Test.serverBinding(); | ||
super.bindingTypeClass = SNSServerBinding.class; | ||
super.pathToBindingJson = "/bindings/default implementation/latest/server/binding.json"; | ||
super.pathToExtendedBindingJson = "/bindings/default implementation/latest/server/binding - extended.json"; | ||
super.pathToWronglyExtendedBindingJson = "/bindings/default implementation/latest/server/binding - wrongly extended.json"; | ||
}} | ||
|
||
} |
Oops, something went wrong.