update: solved adding this code to `build.gradle`...
# announcements
m
update: solved adding this code to `build.gradle`:
Copy code
configure<SourceSetContainer> {
    named("main") {
        java.srcDir("src/main/kotlin")
    }
}
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- spring_boot
Copy code
@PostMapping("/my-endpoint")
fun createProject(@RequestParam request: Map<String, String>): ResponseEntity<Map<String, String>> {
    val filePath = request["filepath"]

    try {
        val thread = thread {

            try {
                MyCustomClass(filePath)
            } catch (e: Exception) {
                when (e) {
                    is IOException, is SAXException, is ParserConfigurationException, is SQLException -> {
                        println(e)
                    }
                    else -> throw e
                }
            } // end of thread's try

        }

        thread.start()

        return ResponseEntity.ok().body(
            mapOf(
                "message" to "success"
            )
        )
    } catch (e: java.lang.Exception) {
        return ResponseEntity.badRequest().body(
            mapOf(
                "message" to "error"
            )
        )
    }
}
why does spring boot give me noclassdeffound on
MyCustomClass
?
t
Pretty hard to tell, has nothing to do with spring, but pretty much everything with your build system / environment you are building and running your application with