About Vlad Mihalcea

Vlad Mihalcea is a software architect passionate about software integration, high scalability and concurrency challenges.

The data knowledge stack

Concurrency is not for the faint-hearted

We all know concurrency programming is difficult to get it right. That’s why threading tasks are followed by extensive design and code reviewing sessions.

You never assign concurrent issues to inexperienced developers. The problem space is carefully analysed, a design emerges and the solution is both documented and reviewed.

That’s how threading related tasks are usually addressed. You will naturally choose a higher level abstraction, since you don’t want to get tangled up in low level details. That’s why the java.util.concurrent is usually better (unless you build a High Frequency Trading system) than hand-made producer/consumer Java 1.2 style thread-safe structures.

Is database programming any different?

In a database system the data is spread across various structures (SQL tables or NoSQL collections) and multiple users may select/insert/update/delete whatever they choose to. From a concurrency point of view this is a very challenging task and it’s not just the database system developer’s problem. It’s our problem as well.

A typical RDBMS data layer requires you to master various technologies and your solution is only as strong as your team’s weakest spot.

A recipe for success

When it comes to database programming you shouldn’t ever remain untrained. Constantly learning is your best weapon, there’s no other way.

For this I came up with my own data knowledge stack:

datastack

You should always master the bottom layers prior to advancing to upper ones.

So these are the golden rules for taming the data layer:

  • The database manual was not only meant for Database AdministratorsIf you are doing any database related task than reading your current database manual is not optional. You should be familiar with both the SQL standard and your database specific traits. Break free from the SQL-92 mindset. Don’t let the portability fear make you reject highly effective database specific features. It’s more common to end-up with a sluggish database layer than to port an already running system to a new database solution.
  • Fully read “Patterns of Enterprise Application ArchitectureI’ll give you a great investment tip. You are 50$ away from understanding the core concepts of any available ORM tool. Martin Fowler‘s book is a must for any enterprise developer. The on-line pattern catalogue is a great teaser.
  • Read your ORM documentationSome argue that their ORM tool is the root of all evil. Unless you spend your time and read all the available documentation, you are going to have a very hard time taming your ORM data layer. The object to relational mismatch has always been a really complex problem, yet it simplifies the CREATE/UPDATE/DELETE operations of complex object tree structures. The ORM’s optimistic locking feature is a great way of dealing with the “lost update” problem.
  • Pick and mixJPA/Hibernate are not a substitute for SQL. You should get the best of JPA and SQL and combine them into one winning solution. Because SQL is unavoidable on any non-trivial application, it’s wise to invest some time (and maybe a license) for using a powerful querying framework. If you fear that database portability is holding you back from using proprietary database querying features than a JPA/JOOQ medley is a recipe for success.

A Hibernate Master class

I’ve been using Hibernate for almost a decade and I admit it wasn’t an easy journey. The StackOverflow Hibernate related questions are pouring on a daily basis.

That’s why I decided to come up with my own Hibernate material that I’ll share on this blog and my GitHub account, because if you are willing to spend your time to learn it you shouldn’t be charged for your effort. For those who want an intensive and personalized Hibernate Master class training, feel free to contact me. We’ll find a way to get you trained.

Reference: The data knowledge stack from our JCG partner Vlad Mihalcea at the Vlad Mihalcea’s Blog blog.

Do you want to know how to develop your skillset to become a Java Rockstar?

Subscribe to our newsletter to start Rocking right now!

To get you started we give you two of our best selling eBooks for FREE!

JPA Mini Book

Learn how to leverage the power of JPA in order to create robust and flexible Java applications. With this Mini Book, you will get introduced to JPA and smoothly transition to more advanced concepts.

JVM Troubleshooting Guide

The Java virtual machine is really the foundation of any Java EE platform. Learn how to master it with this advanced guide!

Given email address is already subscribed, thank you!
Oops. Something went wrong. Please try again later.
Please provide a valid email address.
Thank you, your sign-up request was successful! Please check your e-mail inbox.
Please complete the CAPTCHA.
Please fill in the required fields.

Leave a Reply


two × 1 =



Java Code Geeks and all content copyright © 2010-2014, Exelixis Media Ltd | Terms of Use | Privacy Policy
All trademarks and registered trademarks appearing on Java Code Geeks are the property of their respective owners.
Java is a trademark or registered trademark of Oracle Corporation in the United States and other countries.
Java Code Geeks is not connected to Oracle Corporation and is not sponsored by Oracle Corporation.
Do you want to know how to develop your skillset and become a ...
Java Rockstar?

Subscribe to our newsletter to start Rocking right now!

To get you started we give you two of our best selling eBooks for FREE!

Get ready to Rock!
You can download the complementary eBooks using the links below:
Close