2021-08-17 17:23:34 +02:00
|
|
|
import database.DatabaseFactory
|
|
|
|
import database.dao.ResultObjects
|
2021-08-12 15:59:28 +02:00
|
|
|
import di.databasemodule
|
2021-08-13 12:58:06 +02:00
|
|
|
import mq.ConsumerWrapper
|
2021-08-17 17:23:34 +02:00
|
|
|
import org.jetbrains.exposed.sql.SchemaUtils
|
|
|
|
import org.jetbrains.exposed.sql.transactions.transaction
|
2021-08-12 15:59:28 +02:00
|
|
|
import org.koin.core.context.GlobalContext.startKoin
|
|
|
|
|
|
|
|
fun main(vararg args: String) {
|
|
|
|
|
|
|
|
startKoin {
|
|
|
|
printLogger()
|
|
|
|
modules(databasemodule)
|
|
|
|
}
|
|
|
|
|
2021-08-17 17:23:34 +02:00
|
|
|
DatabaseFactory.init()
|
|
|
|
transaction{
|
|
|
|
SchemaUtils.create(ResultObjects)
|
|
|
|
}
|
|
|
|
|
2021-08-13 12:58:06 +02:00
|
|
|
val consumerWrapper = ConsumerWrapper();
|
|
|
|
consumerWrapper.recieve();
|
2021-08-12 15:59:28 +02:00
|
|
|
}
|