All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.lemfi.kest.rabbitmq.builder.RabbitMQCountMessagesExecutionBuilder.kt Maven / Gradle / Ivy

There is a newer version: 0.8.1
Show newest version
@file:Suppress("FunctionName", "unused")

package com.github.lemfi.kest.rabbitmq.builder

import com.github.lemfi.kest.core.builder.ExecutionBuilder
import com.github.lemfi.kest.core.model.Execution
import com.github.lemfi.kest.rabbitmq.executor.RabbitMQCountMessagesExecution
import com.github.lemfi.kest.rabbitmq.model.RabbitMQMessageCount
import com.github.lemfi.kest.rabbitmq.model.rabbitMQProperty

class RabbitMQCountMessagesExecutionBuilder : ExecutionBuilder {

    lateinit var queue: String

    @Suppress("MemberVisibilityCanBePrivate")
    var connection = rabbitMQProperty { managementapi.connection }

    @Suppress("MemberVisibilityCanBePrivate")
    var user = rabbitMQProperty { managementapi.user }

    @Suppress("MemberVisibilityCanBePrivate")
    var password = rabbitMQProperty { managementapi.password }

    @Suppress("MemberVisibilityCanBePrivate")
    var vhost = rabbitMQProperty { vhost }

    override fun toExecution(): Execution {
        return RabbitMQCountMessagesExecution(
            connection = connection,
            vhost = vhost,
            queue = queue,
            user = user,
            password = password,
        )
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy