repo stringclasses 1k
values | file_url stringlengths 96 373 | file_path stringlengths 11 294 | content stringlengths 0 32.8k | language stringclasses 1
value | license stringclasses 6
values | commit_sha stringclasses 1k
values | retrieved_at stringdate 2026-01-04 14:45:56 2026-01-04 18:30:23 | truncated bool 2
classes |
|---|---|---|---|---|---|---|---|---|
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/springvalidation/UserAccountIntegrationTest.java | spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/springvalidation/UserAccountIntegrationTest.java | package com.baeldung.springvalidation;
import static org.springframework.test.web.servlet.result.MockMvcResultHandlers.print;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.model;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import static org.... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/produceimage/DataProducerControllerIntegrationTest.java | spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/produceimage/DataProducerControllerIntegrationTest.java | package com.baeldung.produceimage;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.header;
import static org.sp... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/students/StudentControllerIntegrationTest.java | spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/students/StudentControllerIntegrationTest.java | package com.baeldung.students;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.delete;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post;
import static org.sprin... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/modifyrequest/EscapeHtmlInterceptorIntegrationTest.java | spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/modifyrequest/EscapeHtmlInterceptorIntegrationTest.java | package com.baeldung.modifyrequest;
import java.net.URI;
import java.util.Map;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.t... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/modifyrequest/EscapeHtmlAspectIntegrationTest.java | spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/modifyrequest/EscapeHtmlAspectIntegrationTest.java | package com.baeldung.modifyrequest;
import java.net.URI;
import java.util.Map;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.t... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/modifyrequest/EscapeHtmlFilterIntegrationTest.java | spring-boot-modules/spring-boot-mvc/src/test/java/com/baeldung/modifyrequest/EscapeHtmlFilterIntegrationTest.java | package com.baeldung.modifyrequest;
import java.net.URI;
import java.util.Map;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.t... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/ServletInitializer.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/ServletInitializer.java | package com.baeldung.springvalidation;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
public class ServletInitializer extends SpringBootServletInitializer {
@Override
protected SpringApplicationBuilder config... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/SpringValidationApplication.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/SpringValidationApplication.java | package com.baeldung.springvalidation;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class SpringValidationApplication {
public static void main(String[] args) {
SpringApplication.run(SpringValidationA... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/controller/UserAccountController.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/controller/UserAccountController.java | package com.baeldung.springvalidation.controller;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.ui.ModelMap;
import org.springframework.validation.BindingResult;
import org.springframework.validation.annotation.Validated;
import org.springframework.we... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/interfaces/AdvanceInfo.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/interfaces/AdvanceInfo.java | package com.baeldung.springvalidation.interfaces;
public interface AdvanceInfo {
// validation group marker interface
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/interfaces/BasicInfo.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/interfaces/BasicInfo.java | package com.baeldung.springvalidation.interfaces;
public interface BasicInfo {
// validation group marker interface
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/domain/UserAccount.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/domain/UserAccount.java | package com.baeldung.springvalidation.domain;
import com.baeldung.springvalidation.interfaces.AdvanceInfo;
import com.baeldung.springvalidation.interfaces.BasicInfo;
import jakarta.validation.Valid;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.co... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/domain/UserAddress.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springvalidation/domain/UserAddress.java | package com.baeldung.springvalidation.domain;
import jakarta.validation.constraints.NotBlank;
public class UserAddress {
@NotBlank
private String countryCode;
public String getCountryCode() {
return countryCode;
}
public void setCountryCode(String countryCode) {
this.coun... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/nosuchbeandefinitionexception/BeanB.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/nosuchbeandefinitionexception/BeanB.java | package com.baeldung.nosuchbeandefinitionexception;
public class BeanB {
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/nosuchbeandefinitionexception/NoSuchBeanDefinitionDemoApp.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/nosuchbeandefinitionexception/NoSuchBeanDefinitionDemoApp.java | package com.baeldung.nosuchbeandefinitionexception;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class NoSuchBeanDefinitionDemoApp {
public static void main(String[] args) {
SpringApplication.run(NoSuchBeanDef... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/nosuchbeandefinitionexception/BeanA.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/nosuchbeandefinitionexception/BeanA.java | package com.baeldung.nosuchbeandefinitionexception;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@Component
public class BeanA {
@Autowired
BeanB dependency;
} | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springbootannotations/MySQLAutoconfiguration.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/springbootannotations/MySQLAutoconfiguration.java | package com.baeldung.springbootannotations;
import java.util.Arrays;
import java.util.Properties;
import javax.sql.DataSource;
import jakarta.persistence.EntityManagerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.AutoConfigureOrder;
import org.s... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/produceimage/ImageApplication.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/produceimage/ImageApplication.java | package com.baeldung.produceimage;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.context.annotation.ComponentScan;
@EnableAutoConfiguration
@ComponentScan("com.baeldung.produceimage")
public class ImageApplication {... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/produceimage/controller/DataProducerController.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/produceimage/controller/DataProducerController.java | package com.baeldung.produceimage.controller;
import java.io.IOException;
import java.io.InputStream;
import org.apache.commons.io.IOUtils;
import org.springframework.core.io.InputStreamResource;
import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity;
import org.springframework.ster... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/responseentity/CustomResponseWithBuilderController.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/responseentity/CustomResponseWithBuilderController.java | package com.baeldung.responseentity;
import java.time.Year;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMap... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/responseentity/CustomResponseController.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/responseentity/CustomResponseController.java | package com.baeldung.responseentity;
import java.io.IOException;
import java.time.Year;
import jakarta.servlet.http.HttpServletResponse;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Contro... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/internationalization/InternationalizationApp.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/internationalization/InternationalizationApp.java | package com.baeldung.internationalization;
import jakarta.annotation.security.RolesAllowed;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class InternationalizationApp {
@RolesAllowed("*")
public static vo... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/internationalization/config/MvcConfig.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/internationalization/config/MvcConfig.java | package com.baeldung.internationalization.config;
import java.util.Locale;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.LocaleResolver;
import org.spr... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/internationalization/config/PageController.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/internationalization/config/PageController.java | package com.baeldung.internationalization.config;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
@Controller
public class PageController {
@GetMapping("/international")
public String getInternationalPage() {
return "thymeleaf/international... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/Student.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/Student.java | package com.baeldung.students;
public class Student {
private long id;
private String firstName;
private String lastName;
public Student() {}
public Student(String firstName, String lastName) {
super();
this.firstName = firstName;
this.lastName = lastName;
... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/StudentService.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/StudentService.java | package com.baeldung.students;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.concurrent.atomic.AtomicLong;
import java.util.function.Function;
import java.util.stream.Collectors;
import org.springframework.stereotype.Service;
@Service
public class StudentService {
//... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/StudentController.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/StudentController.java | package com.baeldung.students;
import java.net.URI;
import java.util.List;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.sp... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/SpringBootStudentsApplication.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/students/SpringBootStudentsApplication.java | package com.baeldung.students;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class SpringBootStudentsApplication {
public static void main(String[] args) {
SpringApplication.run(SpringBootStudentsApplicat... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/ModifyRequestApp.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/ModifyRequestApp.java | package com.baeldung.modifyrequest;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication(scanBasePackages = "com.baeldung.modifyrequest")
public class ModifyRequestApp {
public static void main(String[] args) {
Sprin... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/controller/UserController.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/controller/UserController.java | package com.baeldung.modifyrequest.controller;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
imp... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/filter/EscapeHtmlFilter.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/filter/EscapeHtmlFilter.java | package com.baeldung.modifyrequest.filter;
import java.io.IOException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.annotation.Profile;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;
import com.baeldung.modifyrequest.r... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/aop/EscapeHtmlAspect.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/aop/EscapeHtmlAspect.java | package com.baeldung.modifyrequest.aop;
import java.io.BufferedReader;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.lang.reflect.Type;
import java.nio.charset.StandardCharsets;
import org.slf4j.Logger;
import org.slf4j.Logge... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/interceptor/EscapeHtmlRequestInterceptor.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/interceptor/EscapeHtmlRequestInterceptor.java | package com.baeldung.modifyrequest.interceptor;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.servlet.HandlerInterceptor;
import com.baeldung.modifyrequest.requestwrapper.EscapeHtmlRequestWrapper;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.Ht... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/requestwrapper/EscapeHtmlRequestWrapper.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/requestwrapper/EscapeHtmlRequestWrapper.java | package com.baeldung.modifyrequest.requestwrapper;
import java.io.BufferedReader;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.Collections;
import java.util.Enumeration;
import org.springframework.http.HttpHeaders;
imp... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/config/WebMvcConfiguration.java | spring-boot-modules/spring-boot-mvc/src/main/java/com/baeldung/modifyrequest/config/WebMvcConfiguration.java | package com.baeldung.modifyrequest.config;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Profile;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframewor... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-pkl/src/test/java/com/baeldung/spring/pkl/SpringPklUnitTest.java | spring-boot-modules/spring-boot-pkl/src/test/java/com/baeldung/spring/pkl/SpringPklUnitTest.java | package com.baeldung.spring.pkl;
import static org.junit.jupiter.api.Assertions.assertAll;
import static org.junit.jupiter.api.Assertions.assertEquals;
import org.junit.jupiter.api.Test;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/ToolConfiguration.java | spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/ToolConfiguration.java | package com.baeldung.spring.pkl;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@Configuration
public class ToolConfiguration {
@Bean
public GitHubService getGitHubService(ToolIntegrationProperties toolIntegration) {
return new GitHubSe... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/GitHubService.java | spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/GitHubService.java | package com.baeldung.spring.pkl;
public class GitHubService {
private final ToolIntegrationProperties.Connection gitConnection;
public GitHubService(ToolIntegrationProperties.Connection connection) {
this.gitConnection = connection;
}
public String readIssues() {
return "Reading issue... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/SpringPklDemoApplication.java | spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/SpringPklDemoApplication.java | package com.baeldung.spring.pkl;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.context.properties.ConfigurationPropertiesScan;
@SpringBootApplication
@ConfigurationPropertiesScan
public class SpringPklDemoApplica... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/JiraService.java | spring-boot-modules/spring-boot-pkl/src/main/java/com/baeldung/spring/pkl/JiraService.java | package com.baeldung.spring.pkl;
public class JiraService {
private final ToolIntegrationProperties.Connection jiraConnection;
public JiraService(ToolIntegrationProperties.Connection connection) {
this.jiraConnection = connection;
}
public String readIssues() {
return "Reading issues ... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/test/java/com/baeldung/keycloak/KeycloakConfigurationIntegrationTest.java | spring-boot-modules/spring-boot-keycloak-adapters/src/test/java/com/baeldung/keycloak/KeycloakConfigurationIntegrationTest.java | package com.baeldung.keycloak;
import org.junit.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit.jupiter.SpringExtension;
@ExtendWith(SpringExtension.class)
@SpringBootTest(classes = { SpringBoot.class }... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/SpringBoot.java | spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/SpringBoot.java | package com.baeldung.keycloak;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.web.client.RestTemplate;
@SpringBootApplication
public class SpringBoot {
public s... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/WebController.java | spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/WebController.java | package com.baeldung.keycloak;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import java.security.Principal;
import org.springframework.beans.factory.annotation.Autowired;
import jakarta.servlet.http.HttpServletReque... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/CustomUserAttrController.java | spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/CustomUserAttrController.java | package com.baeldung.keycloak;
import java.util.Map;
import org.springframework.security.core.context.SecurityContextHolder;
import org.springframework.security.oauth2.core.oidc.OidcIdToken;
import org.springframework.security.oauth2.core.oidc.user.DefaultOidcUser;
import org.springframework.stereotype.Controller;
im... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/KeycloakLogoutHandler.java | spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/KeycloakLogoutHandler.java | package com.baeldung.keycloak;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.http.ResponseEntity;
import org.springframework.security.core.Authentication;
import org.springframework.security.oauth2.core.oidc.user.OidcUser;
import org.springframework.security.web.authentication.log... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/Customer.java | spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/Customer.java | package com.baeldung.keycloak;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
@Entity
public class Customer {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private long id;
private String... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/SecurityConfig.java | spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/SecurityConfig.java | package com.baeldung.keycloak;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.annotation.Order;
import org.springframework.security.authentication.AuthenticationManager;
import org.springframework.security.config.Customiz... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/CustomerDAO.java | spring-boot-modules/spring-boot-keycloak-adapters/src/main/java/com/baeldung/keycloak/CustomerDAO.java | package com.baeldung.keycloak;
import org.springframework.data.repository.CrudRepository;
public interface CustomerDAO extends CrudRepository<Customer, Long> {
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/test/java/com/baeldung/springbootconfiguration/SpringContextTest.java | spring-boot-modules/spring-boot-deployment/src/test/java/com/baeldung/springbootconfiguration/SpringContextTest.java | package com.baeldung.springbootconfiguration;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;
@RunWith(SpringRunner.class)
@SpringBootTest
public class SpringContextTest {
@Test
p... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/test/java/com/baeldung/springbootsimple/SpringBootTomcatApplicationIntegrationTest.java | spring-boot-modules/spring-boot-deployment/src/test/java/com/baeldung/springbootsimple/SpringBootTomcatApplicationIntegrationTest.java | package com.baeldung.springbootsimple;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;
@RunWith(SpringRunner.class)
@SpringBootTest
public class SpringBootTomcatApplicationIntegrationTest ... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootconfiguration/SpringBootConfigurationApplication.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootconfiguration/SpringBootConfigurationApplication.java | package com.baeldung.springbootconfiguration;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class SpringBootConfigurationApplication {
public static void main(String[] args) {
SpringApplication.run(Spr... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootconfiguration/controller/GreetingsController.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootconfiguration/controller/GreetingsController.java | package com.baeldung.springbootconfiguration.controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;
@RestController
public class GreetingsController {
@GetMapping("/greeting... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/compare/StartupEventHandler.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/compare/StartupEventHandler.java | package com.baeldung.compare;
import java.util.Arrays;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.function.BiFunction;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.context.event.ApplicationReadyEvent;
import org.springframework.context.event.Even... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/compare/ComparisonApplication.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/compare/ComparisonApplication.java | package com.baeldung.compare;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class ComparisonApplication {
public static void main(String[] args) {
SpringApplication.run(ComparisonApplication.class, args);
}
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootsimple/TomcatController.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootsimple/TomcatController.java | package com.baeldung.springbootsimple;
import org.springframework.web.bind.annotation.*;
import java.util.*;
import java.util.stream.*;
@RestController
public class TomcatController {
@GetMapping(value = "/hello")
public Collection<String> sayHello() {
return IntStream.range(0, 10)
.... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootsimple/SpringBootTomcatApplication.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootsimple/SpringBootTomcatApplication.java | package com.baeldung.springbootsimple;
import org.springframework.boot.*;
import org.springframework.boot.autoconfigure.*;
import org.springframework.boot.web.servlet.support.*;
@SpringBootApplication
public class SpringBootTomcatApplication extends SpringBootServletInitializer {
public static void main(String[]... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/gracefulshutdown/GracefulShutdownApplication.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/gracefulshutdown/GracefulShutdownApplication.java | package com.baeldung.gracefulshutdown;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class GracefulShutdownApplication {
public static void main(String args[]) {
SpringApplication.run(GracefulShutdownA... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/gracefulshutdown/beans/LongRunningProcessBean.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/gracefulshutdown/beans/LongRunningProcessBean.java | package com.baeldung.gracefulshutdown.beans;
import jakarta.annotation.PostConstruct;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.task.TaskExecutor;
import org.springframework.stereotype.Component;
@Component
... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/gracefulshutdown/config/SpringConfiguration.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/gracefulshutdown/config/SpringConfiguration.java | package com.baeldung.gracefulshutdown.config;
import jakarta.annotation.PreDestroy;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.task.TaskExecutor;
import org.sp... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/ShutdownHookApplication.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/ShutdownHookApplication.java | package com.baeldung.shutdownhooks;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
@EnableAutoConfiguration
public class ShutdownHookApplication {
... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/beans/Bean1.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/beans/Bean1.java | package com.baeldung.shutdownhooks.beans;
import jakarta.annotation.PreDestroy;
import org.springframework.stereotype.Component;
@Component
public class Bean1 {
@PreDestroy
public void destroy() {
System.out.println("Shutdown triggered using @PreDestroy.");
}
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/beans/Bean2.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/beans/Bean2.java | package com.baeldung.shutdownhooks.beans;
import org.springframework.beans.factory.DisposableBean;
import org.springframework.stereotype.Component;
@Component
public class Bean2 implements DisposableBean {
@Override
public void destroy() throws Exception {
System.out.println("Shutdown triggered using... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/beans/Bean3.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/beans/Bean3.java | package com.baeldung.shutdownhooks.beans;
public class Bean3 {
public void destroy() {
System.out.println("Shutdown triggered using bean destroy method.");
}
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/config/ExampleServletContextListener.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/config/ExampleServletContextListener.java | package com.baeldung.shutdownhooks.config;
import jakarta.servlet.ServletContextEvent;
import jakarta.servlet.ServletContextListener;
public class ExampleServletContextListener implements ServletContextListener {
@Override
public void contextDestroyed(ServletContextEvent event) {
System.out.println("... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/config/ShutdownHookConfiguration.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/shutdownhooks/config/ShutdownHookConfiguration.java | package com.baeldung.shutdownhooks.config;
import jakarta.servlet.ServletContextListener;
import org.springframework.boot.web.servlet.ServletListenerRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import com.baeldung.shutdownhooks.bea... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootnonwebapp/SpringBootConsoleApplication.java | spring-boot-modules/spring-boot-deployment/src/main/java/com/baeldung/springbootnonwebapp/SpringBootConsoleApplication.java | package com.baeldung.springbootnonwebapp;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
/**
* 1. Act as main class for spring boot appl... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/test/java/com/baeldung/returnnull/PostControllerIntegrationTest.java | spring-boot-modules/spring-boot-graphql-2/src/test/java/com/baeldung/returnnull/PostControllerIntegrationTest.java | package com.baeldung.returnnull;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.autoconfigure.graphql.GraphQlTest;
import org.springframework.context.annotation.Import;
import org.springframework.graphql.test.tester.GraphQlTester;
... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/test/java/com/baeldung/pagination/GraphqlPaginationIntegrationTest.java | spring-boot-modules/spring-boot-graphql-2/src/test/java/com/baeldung/pagination/GraphqlPaginationIntegrationTest.java | package com.baeldung.pagination;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.autoconfigure.graphql.tester.AutoConfigureGraphQlTester;
import org.springframework.boot.test.autoconfigure.we... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/GraphqlVsRestApplication.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/GraphqlVsRestApplication.java | package com.baeldung.graphqlvsrest;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration;
@... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/controller/OrderController.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/controller/OrderController.java | package com.baeldung.graphqlvsrest.controller;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
im... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/controller/ProductGraphQLController.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/controller/ProductGraphQLController.java | package com.baeldung.graphqlvsrest.controller;
import java.util.List;
import org.springframework.graphql.data.method.annotation.Argument;
import org.springframework.graphql.data.method.annotation.MutationMapping;
import org.springframework.graphql.data.method.annotation.QueryMapping;
import org.springframework.graphq... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/controller/ProductController.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/controller/ProductController.java | package com.baeldung.graphqlvsrest.controller;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Pageable;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.sprin... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/model/ProductModel.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/model/ProductModel.java | package com.baeldung.graphqlvsrest.model;
import java.util.List;
public class ProductModel {
private String name;
private String description;
private String status;
private String currency;
private Double price;
private List<String> imageUrls;
private List<String> videoUrls;
private In... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/configuration/GraphqlConfiguration.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/configuration/GraphqlConfiguration.java | package com.baeldung.graphqlvsrest.configuration;
import org.springframework.context.annotation.Configuration;
@Configuration
public class GraphqlConfiguration {
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/OrderRepository.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/OrderRepository.java | package com.baeldung.graphqlvsrest.repository;
import java.util.List;
import com.baeldung.graphqlvsrest.entity.Order;
public interface OrderRepository {
List<Order> getOrdersByProduct(Integer productId);
}
| java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/ProductRepository.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/ProductRepository.java | package com.baeldung.graphqlvsrest.repository;
import java.util.List;
import com.baeldung.graphqlvsrest.entity.Product;
import com.baeldung.graphqlvsrest.model.ProductModel;
public interface ProductRepository {
List<Product> getProducts(Integer pageSize, Integer pageNumber);
Product getProduct(Integer id);
... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/impl/ProductRepositoryImpl.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/impl/ProductRepositoryImpl.java | package com.baeldung.graphqlvsrest.repository.impl;
import static java.util.Collections.singletonList;
import java.util.ArrayList;
import java.util.List;
import java.util.Optional;
import java.util.stream.Collectors;
import org.springframework.stereotype.Repository;
import com.baeldung.graphqlvsrest.entity.Product;... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/impl/OrderRepositoryImpl.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/repository/impl/OrderRepositoryImpl.java | package com.baeldung.graphqlvsrest.repository.impl;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.UUID;
import java.util.stream.Collectors;
import org.springframework.stereotype.Repository;
import com.baeldung.graphqlvsrest.entity.Order;
import com.baeldung.graphqlvsrest.... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/entity/Product.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/entity/Product.java | package com.baeldung.graphqlvsrest.entity;
import java.util.List;
import com.baeldung.graphqlvsrest.model.ProductModel;
public class Product {
private Integer id;
private String name;
private String description;
private String status;
private String currency;
private Double price;
private... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/entity/Order.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphqlvsrest/entity/Order.java | package com.baeldung.graphqlvsrest.entity;
public class Order {
private Integer id;
private Integer productId;
private String customerId;
private String status;
private String address;
private String creationDate;
public Integer getId() {
return id;
}
public void setId(Int... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/MultipartVariableMapper.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/MultipartVariableMapper.java | package com.baeldung.graphql.fileupload;
import java.util.List;
import java.util.Map;
import java.util.regex.Pattern;
public class MultipartVariableMapper {
private static final Pattern PERIOD = Pattern.compile("\\.");
private static final MultipartVariableMapper.Mapper<Map<String, Object>> MAP_MAPPER = new... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/UploadCoercing.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/UploadCoercing.java | package com.baeldung.graphql.fileupload;
import graphql.schema.Coercing;
import graphql.schema.CoercingParseLiteralException;
import graphql.schema.CoercingParseValueException;
import graphql.schema.CoercingSerializeException;
import org.springframework.web.multipart.MultipartFile;
public class UploadCoercing impleme... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/FileStorageService.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/FileStorageService.java | package com.baeldung.graphql.fileupload;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;
import java.io.IOException;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.Objects;
@Service
public class FileStorageSer... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/MultipartGraphQlHttpHandler.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/MultipartGraphQlHttpHandler.java | package com.baeldung.graphql.fileupload;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpInputMessage;
import org.springframework.http.converter.GenericHttpMessageConverter;
import org.springframework.... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/GraphqlFileUploadApplication.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/GraphqlFileUploadApplication.java | package com.baeldung.graphql.fileupload;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration;
im... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/FileUploadDataFetcher.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/FileUploadDataFetcher.java | package com.baeldung.graphql.fileupload;
import graphql.schema.DataFetcher;
import graphql.schema.DataFetchingEnvironment;
import org.springframework.stereotype.Component;
import org.springframework.web.multipart.MultipartFile;
import java.io.IOException;
import java.nio.file.Files;
import java.nio.file.Path;
import ... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/MultipartGraphQlWebMvcAutoconfiguration.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/graphql/fileupload/MultipartGraphQlWebMvcAutoconfiguration.java | package com.baeldung.graphql.fileupload;
import com.fasterxml.jackson.databind.ObjectMapper;
import graphql.schema.GraphQLScalarType;
import org.springframework.boot.autoconfigure.graphql.GraphQlProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/ReturnNullApp.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/ReturnNullApp.java | package com.baeldung.returnnull;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class ReturnNullApp {
public static void main(String[] args) {
System.setProperty("spring.profiles.default", "returnnull")... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/Post.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/Post.java | package com.baeldung.returnnull;
public class Post {
private String id;
private String title;
private String text;
private String category;
private String author;
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public Strin... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/GraphQLVoidScalar.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/GraphQLVoidScalar.java | package com.baeldung.returnnull;
import graphql.schema.Coercing;
import graphql.schema.GraphQLScalarType;
public class GraphQLVoidScalar {
public static final GraphQLScalarType Void = GraphQLScalarType.newScalar()
.name("Void")
.description("A custom scalar that represents the null value")
.coe... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/PostController.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/PostController.java | package com.baeldung.returnnull;
import java.util.ArrayList;
import java.util.List;
import java.util.UUID;
import org.springframework.graphql.data.method.annotation.Argument;
import org.springframework.graphql.data.method.annotation.MutationMapping;
import org.springframework.stereotype.Controller;
@Controller
publi... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/GraphQlConfig.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/returnnull/GraphQlConfig.java | package com.baeldung.returnnull;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.graphql.execution.RuntimeWiringConfigurer;
@Configuration
public class GraphQlConfig {
@Bean
public RuntimeWiringConfigurer runtimeWirin... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/GraphqlPagination.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/GraphqlPagination.java | package com.baeldung.pagination;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class GraphqlPagination {
public static void main(String[] args) {
SpringApplication.run(GraphqlPagination.class, args);
... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/BookConnection.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/BookConnection.java | package com.baeldung.pagination.dto;
import lombok.Getter;
import java.util.List;
@Getter
public class BookConnection {
private final List<BookEdge> edges;
private final PageInfo pageInfo;
public BookConnection(List<BookEdge> edges, PageInfo pageInfo) {
this.edges = edges;
this.pageInfo ... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/BookEdge.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/BookEdge.java | package com.baeldung.pagination.dto;
import com.baeldung.pagination.entity.Book;
import lombok.Getter;
@Getter
public class BookEdge {
private final Book node;
private final String cursor;
public BookEdge(Book node, String cursor) {
this.node = node;
this.cursor = cursor;
}
} | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/PageInfo.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/PageInfo.java | package com.baeldung.pagination.dto;
import lombok.Getter;
@Getter
public class PageInfo {
private final boolean hasNextPage;
private final String endCursor;
public PageInfo(boolean hasNextPage, String endCursor) {
this.hasNextPage = hasNextPage;
this.endCursor = endCursor;
}
} | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/BookPage.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/dto/BookPage.java | package com.baeldung.pagination.dto;
import lombok.Getter;
import org.springframework.data.domain.Page;
import java.util.List;
import com.baeldung.pagination.entity.Book;
@Getter
public class BookPage {
private final List<Book> content;
private final int totalPages;
private final long totalElements;
... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/repository/BookRepository.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/repository/BookRepository.java | package com.baeldung.pagination.repository;
import org.springframework.data.repository.CrudRepository;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.stereotype.Repository;
import java.util.List;
import com.baeldung.pagination.entity.Book;
@Repository
public interf... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/resolver/BookQueryResolver.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/resolver/BookQueryResolver.java | package com.baeldung.pagination.resolver;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.domain.Pageable;
import org.springframework.graphql.data.method.annotation.Argument;
import org.springframework.graphql.data.method.annotation.Query... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
eugenp/tutorials | https://github.com/eugenp/tutorials/blob/4463e58ffb73fe599bac2479abd84598c6e70a1a/spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/entity/Book.java | spring-boot-modules/spring-boot-graphql-2/src/main/java/com/baeldung/pagination/entity/Book.java | package com.baeldung.pagination.entity;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import lombok.Getter;
import lombok.Setter;
@Entity
public class Book {
@Id
@GeneratedValue(strategy = GenerationType.... | java | MIT | 4463e58ffb73fe599bac2479abd84598c6e70a1a | 2026-01-04T14:45:57.069771Z | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.