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

com.blr19c.falowp.bot.system.Application.kt Maven / Gradle / Ivy

The newest version!
package com.blr19c.falowp.bot.system

import com.blr19c.falowp.bot.system.adapter.AdapterApplication
import com.blr19c.falowp.bot.system.plugin.PluginManagement
import com.blr19c.falowp.bot.system.scheduling.Scheduling
import com.blr19c.falowp.bot.system.web.WebClient
import com.blr19c.falowp.bot.system.web.WebServer
import com.blr19c.falowp.bot.system.web.Webdriver
import kotlinx.coroutines.launch
import kotlinx.coroutines.runBlocking
import org.slf4j.LoggerFactory

/**
 * 启动
 */
fun start() = runBlocking {
    try {
        Resources.configure()
        Webdriver.configure()
        WebClient.configure()
        PluginManagement.configure()
        Scheduling.configure()
        launch { AdapterApplication.configure() }
        launch { WebServer.configure() }
    } catch (ex: Throwable) {
        val log = LoggerFactory.getLogger(this::class.java)
        log.error("启动失败", ex)
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy