Kotlin + SpringBoot JPA + MySQL- Save/retrieve Files/Images with @Lob annotation
In the tutorial, JavaSampleApproach will show you how to create a SpringBoot Kotlin project that uses SpringJPA with @Lob
annotation to save Files/Images to MySQL database.
I. Technologies
– Kotlin 1.2.20
– Apache Maven 3.5.2
– Spring Tool Suite – Version 3.9.0.RELEASE
- MySQL
– Spring Boot – 1.5.10.RELEASE
II. Goal
– We create a SpringBoot project to save files/images to MySQL database as below structure:
Create MySQL table:
-> Run and check results:
III. Practice
Step to do:
– Create SpringBoot Kotlin project
– Create data model
– Create JPA Repository
– Implement Client to save/retrieve files/images
– Configure JPA connection & MySQL script
1. Create SpringBoot Kotlin project
Using SpringToolSuite to create a SpringBoot project with dependencies:
More at:
Top comments (0)