Framework/🍃 Spring
-
🔥 Question 👉 How to replace all specific strings within a project? 🧙 Answer1. CTRL + H2. Enter the string you want to change (ex, btnSearch)3. Click the [Replace..] button located at the bottom right4. Enter a string to replace in With: (ex, btnUpdate)5. And click the [OK] button 6. Done!If I was of any help to you, please buy me coffee 😿😢😥If you have any questions, please leave them in th..
[Eclipse] How to replace all specific strings within a project🔥 Question 👉 How to replace all specific strings within a project? 🧙 Answer1. CTRL + H2. Enter the string you want to change (ex, btnSearch)3. Click the [Replace..] button located at the bottom right4. Enter a string to replace in With: (ex, btnUpdate)5. And click the [OK] button 6. Done!If I was of any help to you, please buy me coffee 😿😢😥If you have any questions, please leave them in th..
2024.11.19 -
🔥 Problem 👉 The method contentSecurityPolicy(String) is undefined for the type HeadersConfigurer🧙 Solution👉 I suggest you try different versions of springframework security I use this version of spring security :) org.springframework.security spring-security-web 4.1.2.RELEASE org.springframework.security spring-security-config 4.1.2.RELEASE🧭References👉 https://mvnreposito..
[Spring] The method contentSecurityPolicy(String) is undefined🔥 Problem 👉 The method contentSecurityPolicy(String) is undefined for the type HeadersConfigurer🧙 Solution👉 I suggest you try different versions of springframework security I use this version of spring security :) org.springframework.security spring-security-web 4.1.2.RELEASE org.springframework.security spring-security-config 4.1.2.RELEASE🧭References👉 https://mvnreposito..
2024.11.15 -
To resolve the issue where neither the JAVA_HOME nor the JRE_HOME environment variable is defined, you need to set these environment variables to point to your Java Development Kit (JDK) or Java Runtime Environment (JRE) installation directories. Here’s how you can do it on different operating systems:On WindowsFind the JDK/JRE Installation Path:Locate your JDK or JRE installation directory. By ..
How to solved Neither the JAVA_HOME nor the JRE_HOME enviroment variable is defined?To resolve the issue where neither the JAVA_HOME nor the JRE_HOME environment variable is defined, you need to set these environment variables to point to your Java Development Kit (JDK) or Java Runtime Environment (JRE) installation directories. Here’s how you can do it on different operating systems:On WindowsFind the JDK/JRE Installation Path:Locate your JDK or JRE installation directory. By ..
2024.06.11 -
🔥 Problem 👉 org.springframework.web.HttpMediaTypeNotSupportedExceptionorg.springframework.web.HttpMediaTypeNotSupportedExceptionResolved [org.springframework.web.HttpMediaTypeNotSupportedException:Content-Type 'multipart/form-data;boundary=--------------------------407531386842205423562378;charset=UTF-8' is not supported] ☔ Cause of error 👉 I'll pretend I didn't see your mistake :)Maybe you ..
[Spring] org.springframework.web.HttpMediaTypeNotSupportedException🔥 Problem 👉 org.springframework.web.HttpMediaTypeNotSupportedExceptionorg.springframework.web.HttpMediaTypeNotSupportedExceptionResolved [org.springframework.web.HttpMediaTypeNotSupportedException:Content-Type 'multipart/form-data;boundary=--------------------------407531386842205423562378;charset=UTF-8' is not supported] ☔ Cause of error 👉 I'll pretend I didn't see your mistake :)Maybe you ..
2024.01.25 -
🔥 Problem 👉 SEO의 강화를 위해 404 에러가 발생하였을 경우, 404 페이지로 이동시킬 필요가 있습니다. 🧙 Solution 👉 ErrorPageController를 하나 제작합시다. 아래의 소스코드를 참고하여 작업하시면 됩니다. package com.ointex.noticeboard.controller; import org.springframework.boot.web.servlet.error.ErrorController; import org.springframework.http.HttpStatus; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.GetMapping;..
[Spring boot] 에러 혹은 404 페이지로 이동시키는 방법🔥 Problem 👉 SEO의 강화를 위해 404 에러가 발생하였을 경우, 404 페이지로 이동시킬 필요가 있습니다. 🧙 Solution 👉 ErrorPageController를 하나 제작합시다. 아래의 소스코드를 참고하여 작업하시면 됩니다. package com.ointex.noticeboard.controller; import org.springframework.boot.web.servlet.error.ErrorController; import org.springframework.http.HttpStatus; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.GetMapping;..
2024.01.16 -
🔥 Problem 👉 nested exception is java.lang.IllegalStateException: Can't configure antMatchers after anyRequest 🧙 Solution 👉 .anyRequest().authenticated() to be used only once! Please check if you used them once. http .httpBasic() .and() .authorizeRequests() .antMatchers("/test/**").permitAll() .and() .authorizeRequests() .antMatchers("/admin/**").hasAnyRole("ADMIN") .anyRequest().authenticated() ..
[Solved] Can't configure antMatchers after anyRequest🔥 Problem 👉 nested exception is java.lang.IllegalStateException: Can't configure antMatchers after anyRequest 🧙 Solution 👉 .anyRequest().authenticated() to be used only once! Please check if you used them once. http .httpBasic() .and() .authorizeRequests() .antMatchers("/test/**").permitAll() .and() .authorizeRequests() .antMatchers("/admin/**").hasAnyRole("ADMIN") .anyRequest().authenticated() ..
2024.01.12