summaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/modules/commons/message-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/message/MessagePropertiesDSL.kt
diff options
context:
space:
mode:
Diffstat (limited to 'ms/blueprintsprocessor/modules/commons/message-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/message/MessagePropertiesDSL.kt')
-rw-r--r--ms/blueprintsprocessor/modules/commons/message-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/message/MessagePropertiesDSL.kt94
1 files changed, 47 insertions, 47 deletions
diff --git a/ms/blueprintsprocessor/modules/commons/message-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/message/MessagePropertiesDSL.kt b/ms/blueprintsprocessor/modules/commons/message-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/message/MessagePropertiesDSL.kt
index 527374f02..8b31de9b9 100644
--- a/ms/blueprintsprocessor/modules/commons/message-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/message/MessagePropertiesDSL.kt
+++ b/ms/blueprintsprocessor/modules/commons/message-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/message/MessagePropertiesDSL.kt
@@ -17,8 +17,8 @@
package org.onap.ccsdk.cds.blueprintsprocessor.message
import com.fasterxml.jackson.databind.JsonNode
-import org.onap.ccsdk.cds.controllerblueprints.core.BlueprintConstants
-import org.onap.ccsdk.cds.controllerblueprints.core.BlueprintTypes
+import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintConstants
+import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintTypes
import org.onap.ccsdk.cds.controllerblueprints.core.asJsonPrimitive
import org.onap.ccsdk.cds.controllerblueprints.core.asJsonType
import org.onap.ccsdk.cds.controllerblueprints.core.data.RelationshipType
@@ -30,48 +30,48 @@ import org.onap.ccsdk.cds.controllerblueprints.core.dsl.relationshipType
/** Relationships Types DSL for Message Producer */
fun ServiceTemplateBuilder.relationshipTypeConnectsToMessageProducer() {
- val relationshipType = BlueprintTypes.relationshipTypeConnectsToMessageProducer()
+ val relationshipType = BluePrintTypes.relationshipTypeConnectsToMessageProducer()
if (this.relationshipTypes == null) this.relationshipTypes = hashMapOf()
this.relationshipTypes!![relationshipType.id!!] = relationshipType
}
-fun BlueprintTypes.relationshipTypeConnectsToMessageProducer(): RelationshipType {
+fun BluePrintTypes.relationshipTypeConnectsToMessageProducer(): RelationshipType {
return relationshipType(
- id = BlueprintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_PRODUCER,
- version = BlueprintConstants.DEFAULT_VERSION_NUMBER,
- derivedFrom = BlueprintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO,
+ id = BluePrintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_PRODUCER,
+ version = BluePrintConstants.DEFAULT_VERSION_NUMBER,
+ derivedFrom = BluePrintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO,
description = "Relationship connects to through message producer."
) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintConstants.DATA_TYPE_MAP,
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintConstants.DATA_TYPE_MAP,
true,
"Connection Config details."
)
- validTargetTypes(arrayListOf(BlueprintConstants.MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT))
+ validTargetTypes(arrayListOf(BluePrintConstants.MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT))
}
}
fun ServiceTemplateBuilder.relationshipTypeConnectsToMessageConsumer() {
- val relationshipType = BlueprintTypes.relationshipTypeConnectsToMessageConsumer()
+ val relationshipType = BluePrintTypes.relationshipTypeConnectsToMessageConsumer()
if (this.relationshipTypes == null) this.relationshipTypes = hashMapOf()
this.relationshipTypes!![relationshipType.id!!] = relationshipType
}
-fun BlueprintTypes.relationshipTypeConnectsToMessageConsumer(): RelationshipType {
+fun BluePrintTypes.relationshipTypeConnectsToMessageConsumer(): RelationshipType {
return relationshipType(
- id = BlueprintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_CONSUMER,
- version = BlueprintConstants.DEFAULT_VERSION_NUMBER,
- derivedFrom = BlueprintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO,
+ id = BluePrintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_CONSUMER,
+ version = BluePrintConstants.DEFAULT_VERSION_NUMBER,
+ derivedFrom = BluePrintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO,
description = "Relationship type connects to message consumer."
) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintConstants.DATA_TYPE_MAP,
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintConstants.DATA_TYPE_MAP,
true,
"Connection Config details."
)
- validTargetTypes(arrayListOf(BlueprintConstants.MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT))
+ validTargetTypes(arrayListOf(BluePrintConstants.MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT))
}
}
@@ -90,46 +90,46 @@ fun TopologyTemplateBuilder.relationshipTemplateMessageProducer(
class MessageProducerRelationshipTemplateBuilder(name: String, description: String) :
RelationshipTemplateBuilder(
name,
- BlueprintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_PRODUCER, description
+ BluePrintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_PRODUCER, description
) {
fun kafkaBasicAuth(block: KafkaBasicAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaBasicAuthMessageProducerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaBasicAuthMessageProducerProperties(block)
)
}
fun kafkaSslAuth(block: KafkaSslAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaSslAuthMessageProducerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaSslAuthMessageProducerProperties(block)
)
}
fun kafkaScramSslAuth(block: KafkaScramSslAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaScramSslAuthMessageProducerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaScramSslAuthMessageProducerProperties(block)
)
}
}
-fun BlueprintTypes.kafkaBasicAuthMessageProducerProperties(block: KafkaBasicAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaBasicAuthMessageProducerProperties(block: KafkaBasicAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaBasicAuthMessageProducerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaBasicAuthMessageProducerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_BASIC_AUTH.asJsonPrimitive()
return assignments.asJsonType()
}
-fun BlueprintTypes.kafkaSslAuthMessageProducerProperties(block: KafkaSslAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaSslAuthMessageProducerProperties(block: KafkaSslAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaSslAuthMessageProducerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaSslAuthMessageProducerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_SSL_AUTH.asJsonPrimitive()
return assignments.asJsonType()
}
-fun BlueprintTypes.kafkaScramSslAuthMessageProducerProperties(block: KafkaScramSslAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaScramSslAuthMessageProducerProperties(block: KafkaScramSslAuthMessageProducerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaScramSslAuthMessageProducerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaScramSslAuthMessageProducerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_SCRAM_SSL_AUTH.asJsonPrimitive()
@@ -245,88 +245,88 @@ fun TopologyTemplateBuilder.relationshipTemplateMessageConsumer(
class MessageConsumerRelationshipTemplateBuilder(name: String, description: String) :
RelationshipTemplateBuilder(
name,
- BlueprintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_CONSUMER, description
+ BluePrintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_MESSAGE_CONSUMER, description
) {
fun kafkaBasicAuth(block: KafkaBasicAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaBasicAuthMessageConsumerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaBasicAuthMessageConsumerProperties(block)
)
}
fun kafkaSslAuth(block: KafkaSslAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaSslAuthMessageConsumerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaSslAuthMessageConsumerProperties(block)
)
}
fun kafkaScramSslAuth(block: KafkaScramSslAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaScramSslAuthMessageConsumerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaScramSslAuthMessageConsumerProperties(block)
)
}
fun kafkaStreamsBasicAuth(block: KafkaStreamsBasicAuthConsumerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaStreamsBasicAuthConsumerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaStreamsBasicAuthConsumerProperties(block)
)
}
fun kafkaStreamsSslAuth(block: KafkaStreamsSslAuthConsumerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaStreamsSslAuthConsumerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaStreamsSslAuthConsumerProperties(block)
)
}
fun kafkaStreamsScramSslAuth(block: KafkaStreamsScramSslAuthConsumerPropertiesAssignmentBuilder.() -> Unit) {
property(
- BlueprintConstants.PROPERTY_CONNECTION_CONFIG,
- BlueprintTypes.kafkaStreamsScramSslAuthConsumerProperties(block)
+ BluePrintConstants.PROPERTY_CONNECTION_CONFIG,
+ BluePrintTypes.kafkaStreamsScramSslAuthConsumerProperties(block)
)
}
}
-fun BlueprintTypes.kafkaBasicAuthMessageConsumerProperties(block: KafkaBasicAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaBasicAuthMessageConsumerProperties(block: KafkaBasicAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaBasicAuthMessageConsumerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaBasicAuthMessageConsumerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_BASIC_AUTH.asJsonPrimitive()
return assignments.asJsonType()
}
-fun BlueprintTypes.kafkaSslAuthMessageConsumerProperties(block: KafkaSslAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaSslAuthMessageConsumerProperties(block: KafkaSslAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaSslAuthMessageConsumerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaSslAuthMessageConsumerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_SSL_AUTH.asJsonPrimitive()
return assignments.asJsonType()
}
-fun BlueprintTypes.kafkaScramSslAuthMessageConsumerProperties(block: KafkaScramSslAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaScramSslAuthMessageConsumerProperties(block: KafkaScramSslAuthMessageConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaScramSslAuthMessageConsumerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaScramSslAuthMessageConsumerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_SCRAM_SSL_AUTH.asJsonPrimitive()
return assignments.asJsonType()
}
-fun BlueprintTypes.kafkaStreamsBasicAuthConsumerProperties(block: KafkaStreamsBasicAuthConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaStreamsBasicAuthConsumerProperties(block: KafkaStreamsBasicAuthConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaStreamsBasicAuthConsumerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaStreamsBasicAuthConsumerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_STREAMS_BASIC_AUTH.asJsonPrimitive()
return assignments.asJsonType()
}
-fun BlueprintTypes.kafkaStreamsSslAuthConsumerProperties(block: KafkaStreamsSslAuthConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaStreamsSslAuthConsumerProperties(block: KafkaStreamsSslAuthConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaStreamsSslAuthConsumerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaStreamsSslAuthConsumerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_STREAMS_SSL_AUTH.asJsonPrimitive()
return assignments.asJsonType()
}
-fun BlueprintTypes.kafkaStreamsScramSslAuthConsumerProperties(block: KafkaStreamsScramSslAuthConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
+fun BluePrintTypes.kafkaStreamsScramSslAuthConsumerProperties(block: KafkaStreamsScramSslAuthConsumerPropertiesAssignmentBuilder.() -> Unit): JsonNode {
val assignments = KafkaStreamsScramSslAuthConsumerPropertiesAssignmentBuilder().apply(block).build()
assignments[KafkaStreamsScramSslAuthConsumerProperties::type.name] =
MessageLibConstants.TYPE_KAFKA_STREAMS_SCRAM_SSL_AUTH.asJsonPrimitive()