Tag: spring

Not Loading Java Beans on Boot

Java Beans are eagerly created in Spring Boot applications by default. That includes dependency beans. This is something I need to remember always. I tend to forget it and take it for granted since Spring Boot is great at spoiling Java developers. While that is a boon in most times, it can easily become a…

continue reading
No Comments

Chaining Profiles and Additional Documents

Just recently I have been playing around with multiple active profiles. This is apart from having the main application config, plus the profile that matches the environment on which the application is running. That is quite commonplace. Instead I’m talking more of an additional profile that gets activated aside from the environment profile based on…

continue reading
No Comments

Spring Boot Apps With Spring Cloud Config

It is not uncommon for a Java application to have a number of properties that needs to be defined for it to to run smoothly at start. While these configurable parameters that are required by the app can be set in the code, placing those outside is a more logical and cleaner approach. Things like…

continue reading
No Comments

Simple SQL Query Builder

Did a simple, customized SQL query builder that’s only specific for UPDATE statements some time early last year. Thought I’d just write it down here. It was a smaller part of a bigger application. It wasn’t required for all update cases, but a number of them did. I’ve mostly re-written it from memory. It should…

continue reading
No Comments

When API Response Is In Array

From time to time I get some of this odd API response from requesting information for a specific something. I expect the response data to be a simple JSON object. Instead I am looking at a JSON array. I suppose that is still simple enough and it’s not so odd. This kind of response happens…

continue reading
No Comments

Spring OAuth2 Using Password Grant Type With Additional Headers Continued

Part 2 – Accessing a Resource Recap This is a continuation of the previous post that I made some time last month. You can start reading from there to get more context – https://www.joseyamut.xyz/2021/02/24/spring-oauth2-using-password-grant-type-with-additional-headers The first part dealt with getting the access token from a 3rd party token service provider using a password grant. The…

continue reading
1 Comment

Spring OAuth2 Using Password Grant Type With Additional Headers

Part 1 – Getting the Access Token In this example, I am using the older Spring Security library which is: spring-security-oauth2 The JAR file can be found at Maven public repositories here. Dependency For my case, I am specifically using the release version below because I am trying to match some limitations (Such as what…

continue reading
1 Comment