Quantcast
Channel: JPA – NixMash
Browsing all 39 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

GUI Generated Entities for Spring-Data GitHub App v0.0.6

The Spring-Data GitHub App we’ve been covering on NixMash goes to v0.0.6 with Entities generated with the Persistence View Tools in IntelliJ IDEA. We covered the Persistence View ER Diagram and...

View Article



Image may be NSFW.
Clik here to view.

Spring-Data GitHub App at v0.0.7 with Profiles

My Spring-Data App on GitHub goes to v0.0.7 with the addition of profiles and a few other things. The JPA Configuration in v0.0.7 has been redesigned to support multiple Profiles, with DevConfig and...

View Article

Image may be NSFW.
Clik here to view.

A Spring JPA Configuration for Multiple Profiles

My Spring-Data application on GitHub goes to v0.0.8 with the JPA Configuration redesigned to support multiple profiles with a bonus extensible design. Version 0.0.7 of the app supported multiple...

View Article

Image may be NSFW.
Clik here to view.

Approaches to JPA Lazy Loading

The data schema used in my Spring-Data app on GitHub, like most apps, provides plenty of opportunities to retrieve relationship data with Lazy loading. In this post we’ll cover a few approaches found...

View Article

Image may be NSFW.
Clik here to view.

Flexible H2 Database Persistence For Testing With Gradle

We talked about the database-oriented Profiles in my Spring-Data GitHub app, MySQL for production and development, H2Database for testing. On the testing side, typically an H2 Database is configured...

View Article


Image may be NSFW.
Clik here to view.

Updating the Many in a JPA @OneToMany

We’re adding, updating and deleting data in v0.1.0 of my Spring-Data GitHub app. Schema recap is Contacts with a @OneToMany Contact Phones and a @ManyToMany Contact Hobbies relationship. Here we’re...

View Article

Image may be NSFW.
Clik here to view.

Adding a JPA Entity and its @OneToMany Children

We just covered how to update an Entity and its @OneToMany Children in Spring JPA. Now we’ll look at how to add a record and its multiple children. The source we’re using is found in the v0.1.0 branch...

View Article

Image may be NSFW.
Clik here to view.

Working with the Many in a JPA @ManyToMany

We previously worked with the Many in a @OneToMany relationship using Contact Entities and multiple Contact Phones. Today we’ll look at @ManyToMany JPA processing by adding Hobbies into the mix. If you...

View Article


Image may be NSFW.
Clik here to view.

An IntelliJ Multi Module Spring Boot MVC Configuration

Version 0.1.2 of my Spring-Data app on GitHub adds a new MVC and Web Module. Because I wanted to continue having the option of working with the Spring Data JPA processes in a console I separated the...

View Article


Image may be NSFW.
Clik here to view.

Pretty Formatted JSON in Spring Web MVC

I’m focused on the REST APIs in my Spring-Data MVC App at the moment and less on doing anything with the data in the Presentation Layer, so I’m generating a lot of JSON. And even though it’s just...

View Article

Image may be NSFW.
Clik here to view.

Using the H2 Console in Spring and IntelliJ

Like many developers I use H2 Database for building and testing Spring Boot apps. Using an In-Memory database for creating and destroying data with each build is efficient, but viewing the data while...

View Article

Image may be NSFW.
Clik here to view.

Beware Your Spring Security Principal’s Authorities Format

This can beat you up pretty badly when putting a Spring Security configuration in place. Everything is going great until you test your Intercept-Url filterings with user roles and see Not Authorized...

View Article

Image may be NSFW.
Clik here to view.

Spring Security in NixMash Spring App: The Parts You Can See

I subtitled this post “The Parts You Can See” because the more I work with Spring Boot it becomes clear how much is done for you behind the scenes. Spring Security is no exception, because as you’ll...

View Article


Image may be NSFW.
Clik here to view.

Saving Multiple Authorities to Database on New User in Spring

In NixMash Spring we’re using both MySQL and H2Database (two different profiles by environment) for saving user and user authority information. The schema consists of three tables, users,...

View Article

Adding MySQL Spring Security to Existing H2 App

I put NixMash Spring v0.1.6 on GitHub with H2Database Spring Security support only. MySQL is now supported and this post will cover the highlights, though as you’ll see there isn’t much to cover. All...

View Article


Image may be NSFW.
Clik here to view.

Object Child Lists in Thymeleaf Forms and Spring MVC

We’re going to cover the issues involved with processing a list of Object Children in a Thymeleaf Form with Spring MVC as demonstrated in the NixMash Spring screenshot below. Put another way, we’re...

View Article

Image may be NSFW.
Clik here to view.

Spring JPA Auditing with ZonedDateTime and MySQL

Spring JPA Auditing makes it easy to track data activity. And since we have this cool new DateTime API in Java 8 we might as well use it! Instead of a standard DateTime for Creation and Modification...

View Article


Image may be NSFW.
Clik here to view.

Solr No Facet Property in Model Exception Fix in Eclipse

When using a Facets method in a Solr Repository in Eclipse you might encounter an exception telling you there is no facet[PropertyName] found in your Model. Here’s an example. We’re told there’s no...

View Article

Image may be NSFW.
Clik here to view.

A Spring Solr Criteria API Query Example

Last time we covered Solr CRUD operations in Spring Data Solr. Today we’re going to begin a series on Custom Solr Query types, beginning with the Java Criteria API. Here’s a quick definition of...

View Article

Image may be NSFW.
Clik here to view.

Spring Solr Named and Annotated Query Examples

We’re looking at Custom Spring Solr Queries, so after using the Java Criteria API in our last post we’re going to move on to Spring Solr Named and Annotated Queries. We’re going to perform the same...

View Article
Browsing all 39 articles
Browse latest View live




Latest Images