Showing posts with label spring. Show all posts
Showing posts with label spring. Show all posts

Monday, December 16, 2024

Inversion of control(IOC) and Dependency Injection(DI) in Spring Framework

In this tutorial, we will learn the basic concept of Inversion of control and Dependency Injection. The core of the spring framework is based on the IOC principle. IOC and DI are closely related concepts. They describe the different aspects of how the spring manages the objects and their interaction. Let's look into each concept. Inversion of Control(IOC) IOC is a design principle where the control...
Share:

Saturday, January 22, 2022

Grails 3 Download Saved Documnets/Files (.pdf, .txt, .docx and others) Example.

How to Download different types of files using Grails 3. If you want to use server-side file download for different types of files like pdf, txt, docx etc then there are different ways to do it. We can use ServletOutputStream object for it as below: def download(){ def filePath = "/opt/tomcat/webapps/savedFile/filename.pdf" //I am saving files on tomcat. def...
Share:

Tuesday, June 2, 2020

Hot reloading the resources file for changes in Grails.

How to hot reload the resources file when the changes happened in Grails. I was working on Grails 3.3.0 and hot reloading was not working while changing in the resources files. So, I found some workaround which is worth sharing here. There are the following steps to resolve the issue.Configure to watch the directory.Watch the directory for code changesReload spring resources configLoad from the...
Share:

Monday, December 24, 2018

Create Simple Secured Restful Web Services Application Using Spring Boot.​

How to create simple restful web services with spring security using Spring Boot. Table Of Contents - Prerequisites - Introduction - Project Structure - Run the application - Create End Point - Test Prerequisites: Java JDK 1.8 IDE  Introduction: In this tutorial, we are going...
Share: