Tag: Java
-
How to check if YouTube video is a SHORT
YouTube and Google do not allow to check if a YouTube video is a Short or a long form video in a simple way. Even the YouTube Data V3 does not provide this information. Yes, you can get a video length (ISO8601 formatted duration) and assume that videos shorter then 60 seconds are Shorts. But…
-
Hibernate could not initialize proxy – no Session
The org.hibernate.LazyInitializationException: could not initialize proxy error is a common issue that can occur when working with the Hibernate ORM (Object-Relational Mapping) framework in a Spring Boot application. This error occurs when Hibernate is unable to initialize a proxy object, which is an object that is used to lazily load data from the database. When…
-
How to create and register Spring Boot custom request filter
Creating a custom request filter in Spring Boot is a relatively simple process that can be accomplished by following a few basic steps. To apply the filter to specific URLs, use a @Bean annotation to assign the filter only to request that meet criteria. For example, the code below attaches the MyCustomFilter.class only to request…