Home » Tag Archives: Spring

Tag Archives: Spring

Package by layer for Spring project is obsolete

spring-interview-questions-answers

I believe Spring application shouldn’t be structured in package by layer approach. In my opinion, package by feature makes much more sense. First of all, let me describe each approach briefly. “Package by layer” (“Folder by type” in non Java world) This project structure groups source code files into packages/directories based on architecture layer they belong to: . └── net ...

Read More »

Top 20 Spring REST Interview Questions Answers for Java Programmers

spring-interview-questions-answers

Hello guys, I have been sharing some REST with Spring tutorials from last a couple of weeks and today, I am going to share some of the frequently asked Spring and REST interview questions to Java developers applying for Web developer roles. Since Spring Framework is the most popular and the standard framework for developing Java web application and RESTful Web ...

Read More »

Session Management using Spring Session with JDBC DataStore

spring-interview-questions-answers

In web applications, user session management is very crucial for managing user state. In this article, we are going to learn about what are the approaches we have been following to manage user sessions in a clustered environment and how we can use Spring Session to implement it in a much simpler and more scalable way. Typically in production environments, we will ...

Read More »

Running on time with Spring’s scheduled tasks

spring-interview-questions-answers

Do you need to run a process everyday at the exact same time like an alarm? Then Spring’s scheduled tasks are for you. Allowing you to annotate a method with @Scheduled causing it to run at the specific time or interval that is denoted inside it. In this post we will look at setting up a project that can use ...

Read More »

7 Reasons to Use Spring to develop RESTful Web Services in Java

spring-interview-questions-answers

REST has now become a standard way to develop web services and when it comes to Java, there are many frameworks and library available e.g. JAX-RS, Restlet, Jersey, RESTEasy, Apache CFX etc, but I encourage Java developers to use Spring framework to develop RESTful web services. But, some of you might ask, why use Spring Framework to develop RESTful web services ...

Read More »

How Http Basic Authentication works in Spring Security?

spring-interview-questions-answers

In the last article, you have learned how to enable Http basic authentication in Spring security based Java application and now we’ll go one step further to understand how exactly http basic authentication works in Spring security. If you remember, when you use HTTP Basic for authentication purpose the client e.g. browser or a rest client sends login credentials in http ...

Read More »

Converting HTML to RichTextString for Apache POI

spring-interview-questions-answers

1. Overview In this tutorial, we will be building an application that takes HTML as an input and creates a Microsoft Excel Workbook with a RichText representation of the HTML that was provided. To generate the Microsoft Excel Workbook, we will be using Apache POI. To analyze the HTML, we will be using Jericho. The full source code for this ...

Read More »

Bootiful Development with Spring Boot and React

spring-interview-questions-answers

“I love writing authentication and authorization code.” ~ No Java Developer Ever. Tired of building the same login screens over and over? Try the Okta API for hosted authentication, authorization, and multi-factor auth. React has been getting a lot of positive press in the last couple years, making it an appealing frontend option for Java developers! Once you learn how ...

Read More »