Logging SQL as it’s executed is a fairly common desire when developing applications. Perhaps an ORM (such as Hibernate) is being used, and you want to see the actual SQL being executed. Or maybe you’re tracking down a performance problem and need to know if it’s in the application or the database, so step #1 … Continue reading Log4jdbc Spring Boot Starter
Month: March 2017
Working around HHH-9663: Orphan removal does not work for OneToOne relations
HHH-9663 means that orphan removal doesn’t work for OneToOne relationships. For example, given File and FileContent as below (taken from the bug report): package pl.comit.orm.model; import javax.persistence.Entity;import javax.persistence.FetchType;import javax.persistence.Id;import javax.persistence.OneToOne; @Entitypublic class File { private int id; private FileContent content; @Id public int getId() { return id; } public void setId(int id) { this.id = id; } … Continue reading Working around HHH-9663: Orphan removal does not work for OneToOne relations
Spring Boot, HTTPS required, and Elastic Beanstalk health checks
Spring Boot can be very easily configured to require HTTPS for all requests. In application.properties, simply set security.require-ssl=true And that works great – until you’re running the Spring Boot application on AWS Elastic Beanstalk with both HTTP and HTTPS listeners: In that case, Elastic Beanstalk’s health check is always done over HTTP. The configuration page … Continue reading Spring Boot, HTTPS required, and Elastic Beanstalk health checks