Spring Boot H2 In-Memory Database Java Demo

Last Updated on



Views: 11238 , Video Rating: 4.26 , View Time: 18:16 Minutes, # of Likes: 69, # of Disslikes: 12

In this video we have explained how to use In Memory database H2 in spring boot , we have done a demo with Java Spring boot and Using STS. We also have explained about its advantages and disadvantages.

Sample project github code :

Microservices Demo in Spring Boot java:

Spring cloud java :

Spring cloud discovery service Eureka :

Spring cloud config demo :

Spring cloud reverse proxy zuul and zuulfilters:

Spring boot tutorial basics

Spring boot rest base web service

-~-~~-~~~-~~-~-
Please watch: “TWO WAY SSL DEMO WITH SPRING BOOT ”

-~-~~-~~~-~~-~-

Spring Boot H2 In-Memory Database Java Demo

8 thoughts on “Spring Boot H2 In-Memory Database Java Demo”

  1. Now after resolving all the error due to missing jars, I am getting the error while deploying the application. The error is: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'demoController': Unsatisfied dependency expressed through field 'jdbcTemplate'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.springframework.boot.autoconfigure.jdbc.JdbcTemplateAutoConfiguration$JdbcTemplateConfiguration': Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Hikari.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.zaxxer.hikari.HikariDataSource]: Factory method 'dataSource' threw exception; nested exception is java.lang.IllegalStateException: Cannot load driver class: org.h2.driver
    at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:587) ~[spring-beans-5.0.5.RELEASE.jar:5.0.5.RELEASE]
    at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:91) ~[spring-beans-5.0.5.RELEASE.jar:5.0.5.RELEASE]

    Any help is appreciable.
    Thanks

  2. I was getting the error – Spring-boot-starter-jdbc jars are missing. Added the jars into the build path and resolved. When tried to add the jars through the changes in pom.xml, the jars are missing error was coming.

Leave a Comment