
This is an introduction of me as an instructor. You will hear about my past experience and you will understand why I am a good person to talk about database versioning.
I present a high level plan of the course. You will know which subjects we will be talking about and practicing.
You will get a basic overview of technology that we will use during the course.
I will tell you what is the application that we will be working on during the course.
I reveal the plan for this section.
I talk more about the sample application architecture and functionality. It will be easier for you to modify the code later.
I talk about not obvious but necessary software that you must have to complete exercises for this course.
If you do not have Git, Java and MySQL installed and configured on your computer yet, you should have it after this lecture.
Commands used during this lecture
git --version
It prints the current version of Git. It does not have to be a specific version but Git must be installed and the command should work.
I show how to get the application source code from the Git repository, how to configure it and how to run it. After this lecture you should be able to do the same and have the dating platform for dogs configured and working on your computer.
I define new feature requirement that involves updating the database structure. You will understand why we have to modify the database.
You will understand the difference between deployment of new application version and new database structure and why it requires different solutions. I will present you the database versioning concept that Liquibase follows.
You will be able to download, install and configure Liquibase and MySQL JDBC driver. After this lecture you should repeat my steps to have Liquibase ready on your computer.
You will be able to define a basic database structure in Liquibase XML format. You will learn changeset syntax and some change types: table creation with columns, a primary key, autoincrement, not nullable constraints.
You will get a chance to upgrade a database using update Liquibase command. You will also see a sample error during execution and a solution to it.
You will learn how to make data changes using Liquibase changesets.
You will understand Liquibase internals - how Liquibase knows which changesets have to be applied on a database.
I will define a task for you to practice changeset creation. You will be able to practice your knowledge.
You will understand special needs of development database in software companies and why a single one shared with many developers is not a good solution.
I will show you how to add H2 database to the project, integrate it with Spring Boot and use it instead of MySQL database.
We will add Liquibase to the project to be configured by Spring Boot. You will learn how to use it to upgrade H2 database during each application start.
You will learn how to add various types of data through a changeset: text, numbers and use subqueries in insert Liquibase changes. You will be able to split changesets across multiple files and nest one file in the other.
You will know why having a possibility of rolling back a database structure change is important.
You will be able to revert changes from the database taking advantage of autorollback feature of Liquibase.
What to do if autorollback does not work? You will learn how to create a custom rollback for a changeset.
You will realize that the production environment often have its own requirements and you cannot avoid SQL scripts.
You learn how to apply a tag on the database and how to roll back to that tag. You will also see how to rollback to a specific timestamp.
You will learn how to prepare upgrade and rollback SQL scripts for a database when you cannot use Liquibase XML changesets directly.
You get familiar with a fast and automatic way of testing changesets for update and rollback procedures.
Would you like to use Liquibase but you do not know how to start using it in an existing project? You have a few options. At least one of them should work for you.
The first choice option of adding Liquibase to an existing project is to ignore the history of changes. Watch how easily it can be done.
Cannot you afford to loose historical changes? Do not worry, option 2 describes how to create historical changesets in Liquibase.
Scared of creating historical changesets manually? There is a way of generating it automatically. See how to do that.
I will tell you when to look for information about Liquibase.
I will explain you why you should create new changesets instead of modifying existing ones. I will show you how Liquibase checks this rule using a hash. And in the mean time you will also learn a new command - dropAll.
You will understand why you should never mix more than one change per changeset.
I will invite you to a series of exercises to practice using Liquibase.
You will practice Liquibase commands.
You will practice creating various types of changes while preserving existing data and securing rollback possibility for the future.
You will practice creating custom not obvious rollbacks.
Do you want to stop frustration caused by manual database updates? Do you know that there is a free tool to help you out? If your answer is YES, it means that you might benefit from this course.
I start from the very beginning of using Liquibase. You should have some database and SQL knowledge. Basics of Java will increase your final satisfaction as I will also show you Liquibase integration with Spring Boot. I believe in practice so there will be mostly coding with some necessary theory. You will have many chances to try using Liquibase yourself because I included some exercises for you as well.
Get ready for an exiting journey to through Liquibase functionalities.