Post details
Decorates stack traces with source code snippets. Contribute to laech/java-stacksrc development by creating an account on GitHub.
Decorates stack traces with source code snippets. Contribute to laech/java-stacksrc development by creating an account on GitHub.
Say goodbye to checked exceptions forever. Contribute to rogerkeays/unchecked development by creating an account on GitHub.
POM bears, the preferred snack of the Apache Maven project.
Scarlet (@NekomimiScience)Sun, 02 Apr 2023 09:31 +0000
Command Line toolkit for developing Spring Boot applications
Kubernetes allows us to restrict the resources that the containers can use. But key challenges remain in running Java apps efficiently on Kubernetes.
I am trying to configure a CloseableHttpClient from httpclient 4.5 with mutual TLS authentication. The server certificate is self-signed. Here is the code I use (inpired by various StackOverflow po...
Maybe it is a not a common usecase, but I've just had need to know the content type of a bare byte[ ]. After been searching the whole Internet and ...
💡 Did you know that with Groovy 4, you can write a code that can be run as a @Java program without even adding Groovy libraries to the classpath? 😮 For more Groovy 4 features, check this video: youtube.com/watch?v=fTxFa2… #groovylang #java #programming #learning #programmingtipsSzymon Stepniak 🇺🇦 (@wololock)Fri, 22 Apr 2022 04:56 +0000
The long-running BBC sci-fi show Doctor Who has a recurring plot device where the Doctor manages to get out of trouble by showing an identity card which is actually completely blank. Of course, this …
This post is written by Mark Sailes, Senior Specialist Solutions Architect. This blog post shows how to optimize the performance of AWS Lambda functions written in Java, without altering any of the function code. It shows how Java virtual machine (JVM) settings affect the startup time and performance. You also learn how you can benchmark […]
Avoiding Spring context issues when parallelising @Nested
Spring integration tests (3 mins read).
Using abstract base classes to reduce risk of Spring context overall issues with Spring (Boot) integration tests.
Integration Testing Your Spring WebClient
s with Wiremock (4 mins read).
How to write integration tests using Wiremock, for use with WebClient
s.
Solving ConnectException
s with the Kubernetes Java ApiClient
(1 mins read).
How I solved ConnectException
s in my Kubernetes Java client usage, by moving to cluster mode.
Is the idea after the first resolution it'll rely on OS caching? Still this seems inefficient and in cases of multiple domains resolving to the same IP, incorrect. What am I missing?
I'm thrilled to announce the release of part 1 of my Java 17 course! 🎉 This course provides a comprehensive overview of Java basics, decision and repetition structures, methods, and objects. There's lots of examples and some fun independent challenges! linkedin.com/learning/java-…Angie Jones (@techgirl1908)Tue, 15 Mar 2022 18:52 GMT
Gotcha: checked and unchecked exception handling from Spring WebFlux WebClient
(2 mins read).
How checked and unchecked exceptions may appear when testing your WebClient
code.
Accessing the response body with Spring WebFlux WebClient
with onStatus
(1 mins read).
How to access the body of an (error) response when using WebClient
's onStatus
method.
After I drink coffee I show my empty cup to the IT guy and say that I have successfully installed Java. He hates me.
Jay Humor (@jayweingarten)Tue, 01 Mar 2022 17:54 GMT
After so many years, I learned the format of console logging in Java can be defined in logging properties config file. See docs.oracle.com/en/java/javase… for clear explanation. The "Since 1.4" makes me feel very dumb, but better late than never!Johan Vos (@johanvos)Sun, 27 Feb 2022 16:21 GMT
How to interpolate a property inside Spring Security @PreAuthorize
/ @PostAuthorize
(3 mins read).
How to use the value of a property in a Spring Security authorization statement.
If you don't write Javadoc cause "it ages", better not update to #JDK18 because that excuse goes out the window. Now you can just write... /** * Here's how it works: * { example-code } */ ... while having your build compile and test `example-code`. youtube.com/watch?v=m2cVOY…Nicolai Parlog (@nipafx)Thu, 10 Feb 2022 16:35 GMT
Ha! There's a Java tool called Jar Jar Links code.google.com/p/jarjar/Stuart Sierra (@stuartsierra)Mon, 13 May 2013 20:28 +0000
Adding a Wiretap to a Spring WebFlux WebClient
to Log All Request/Response Data (2 mins read).
How to log all request/response data from a Spring Webflux WebClient
.
Determining if the Spring Boot Application is Running in Debug or Trace Mode (3 mins read).
How to determine if your Spring Boot application is running in debug mode, for instance to selectively enable other features of your application.
Simplifying Spring (Boot) ExceptionHandler
s by extending ResponseStatusException
(1 mins read).
How to drive HTTP response status codes from exceptions by extending Spring's ResponseStatusException
.
Interesting. I've been using Toolchains plugin for Gradle https://www.jvt.me/posts/2021/06/09/gradle-toolchain/ and Maven https://www.jvt.me/posts/2020/08/24/maven-toolchains/ to manage this for me
Excluding Filter
s When using WebMvcTest
(1 mins read).
How to exclude specific Filter
s from running when performing WebMvcTest
s.
Capturing HTTP Requests with okhttp's MockWebServer.takeRequest
(1 mins read).
How to use MockWebServer
's takeRequest
method to verify that HTTP request(s) are sent correctly.
Integration Testing Your Spring WebClient
s with okhttp's MockWebServer
(5 mins read).
How to write integration tests using MockWebServer
with Spring Boot, for use with WebClient
s.
Generate Plain Old Java Objects (POJOs) from OpenAPI Model Definitions with Gradle (2 mins read).
How to generate POJOs really quickly and easily, with no manual work, using the Gradle openapi-generator Plugin.
Who knew that a @Java developer as the best job in the UK according to @Glassdoor. Feel lucky to be in the industry!George Adams (@gdams_)Thu, 03 Feb 2022 17:56 GMT
Sharat Chander 💜🦦 (@Sharat_Chander)Tue, 01 Feb 2022 21:53 GMT
Integration Testing Your Spring RestTemplate
s with RestClientTest
, using spring-test (8 mins read).
How to write integration tests using RestClientTest
with Spring Boot, for use with RestTemplate
and RestTemplateBuilder
s.
Getting Started with jMolecules and the (Classical) Onion Architecture, with a Spring Boot project (6 mins read).
A guided example of converting a Spring Boot project to the Onion Architecture pattern.
How to Create and Unit Test Java Bean Validation Annotations (12 mins read).
A guided example through what the different type of annotation ElementType
s are, with respect to Bean Validation, and how to write unit tests for them.
Codifying Your Technical / Architectural Standards with ArchUnit (7 mins read).
How to use ArchUnit to codify your technical standards to reduce code review requirements, and arrive at a more consistent codebase.
Simplifying Spring (Boot) ExceptionHandler
s with ResponseStatus
Annotations (2 mins read).
How to use annotations to drive HTTP response codes from a Spring ExceptionHandler
.
Use SLF4J, not Log4J, as Your Logging Interface (3 mins read).
Why we should be using the interface API for logging, rather than the underlying implementation's API.
Using the Facade Pattern to More Easily Test static
or Complex Classes (2 mins read).
How to use the Facade design pattern to more easily test classes that are more complex than our tests need to understand.
You're currently viewing page 1 of 4, of 199 posts.