News
How to Log Request and Response in Spring Boot
In the production environment, logging of request and response in a spring boot application is essential for understanding the request pattern. Spring Boot actuator allows you to trace the request and response using the endpoint url. The httptrace actuator endpoint’s URI only displays the last 100 requests. In this article,
How to test JPA Repository Spring Boot
The Spring Boot JPA Repository class allows you to retrieve data from a database table.The JPA Repository is used to test database CRUD operations like insert, update, delete, and select. In the spring boot JPA Repository test cases, the database connection and all database table CRUD operations on a table
Spring Boot use different database for test
Spring Boot makes use of the database specified in the application properties file. When the application is tested with test cases, the spring boot application uses the same database configuration to create and modify data. If you plan to clean and create a new database for testing purposes, this will
System out println is not working in Spring Boot Test
The system.out.println function is used to display the application output in the console window. In some cases, when you run the test methods, the System.out.println command out may not be printed in the console window. The test output was not visible in the console. If any test case failed during
Spring Boot Logger
Spring boot logging framework uses commons Logging for all internal logging and application specific logs. Log frameworks like Java Util Logging, Log4J2, and Logback are supported by the Spring Boot Logger. Spring boot log setup is preconfigured in the spring boot application. It is possible to configure other springboot loggers
Using OAuth 2 for Secure User Authentication
OAuth 2 is a widely used open-standard authorization framework that enables secure user authentication while allowing third-party applications to access user data without having to reveal the user’s password. In this blog post, we will discuss the basics of OAuth 2, how it works, and provide a Java code example
OAuth 2 for REST API Security with Java Code Examples
The rise of REST APIs has revolutionized the way we exchange data between applications. But with this rise also comes the need for proper security measures to ensure that sensitive data is protected. OAuth 2 is one of the most widely adopted solutions for securing REST APIs. In this blog
How to Implement OAuth 2 for Login with Google and
OAuth 2 is an open standard for authorization that enables third-party applications to obtain limited access to a user account on a web service. It is commonly used for sign-in purposes, allowing users to log into a website or application using their existing credentials from a different service, such as
An Introduction to OAuth 2: Understanding the Fundamentals
OAuth 2 is a widely-used open standard authorization protocol that enables applications to secure access to user data. This blog post provides an overview of OAuth 2 and its basic concepts and flow. What is OAuth 2? OAuth 2 is a protocol that allows an application to access user data
OAuth 2 for Single Sign-On: Making User Login Easy
Single sign-on (SSO) is a feature that allows users to log in to multiple applications with a single set of credentials, eliminating the need to remember multiple usernames and passwords. OAuth 2 is an open standard for authorization that provides a secure and convenient way for users to log in