Home » Java » Enterprise Java

Enterprise Java

All You Need To Know About Exception Handling In Selenium

In the world of technology, exceptions are said to be as old as programming itself. Occurrence of an exception during the execution of code can result in unexpected behaviour unless the exception is properly handled in the code. Exceptions are not bad, but are a fundamental part of modern programming. Rather than having a fear of exceptions, it is important ...

Read More »

Executing Blocking calls on a Reactor based Application

spring-interview-questions-answers

Project Reactor is a fully non-blocking foundation with back-pressure support included. Although most libraries out there support asynchronous methods thus assist on its usage, there are some cases where a library contains complex blocking methods without an asynchronous implementation. Calling this methods inside a reactor stream would have bad results. Instead we need to make those method to async ones ...

Read More »

KivaKit Microservices

java-interview-questions-answers

KivaKit Microservices   KivaKit is designed to make coding microservices faster and easier. In this blog post, we will examine the kivakit-microservice module. As of this date, this module is only available for early access via SNAPSHOT builds and by building KivaKit. The final release of KivaKit 1.1 will include this module and should happen by the end of October, ...

Read More »

Signaling and waiting for concurrent state changes

java-interview-questions-answers

Java’s concurrency library (java.util.concurrent) provides a mutual-exclusion (mutex) Lock called ReentrantLock. This lock maintains a queue of threads that are waiting to own the lock, allowing access to a protected resource. A thread can be added to the lock’s wait queue by calling lock(). When the lock() method returns, the thread will own the lock. Once the thread obtains the ...

Read More »

Cloud Build and Gradle/Maven Caching

One of the pain points in all the development projects that I have worked on has been setting up/getting an infrastructure for automation. This has typically meant getting access to an instance of Jenkins. I have great respect for Jenkins as a tool, but each deployment of Jenkins tends to become a Snowflake over time with the different set of ...

Read More »

Kivakit Build

java-interview-questions-answers

A poor man’s multiple-repository build system Refactoring feature branches across multiple repositories A common use case when working with multiple, dependent repositories is to use git flow to create multiple feature branches: kivakit [feature/simplify-log-api] kivakit-extensions [feature/simplify-log-api] If project(s) in kivakit-extensions here depend on projects in kivakit, refactoring code in kivakit can propagate code changes to kivakit-extensions. Then both feature branches ...

Read More »

KivaKit deployments

java-interview-questions-answers

KivaKit applications can be configured using the settings api, but there is an easier way to configure an application for deployment built right into Application. By default, Application looks for the switch -deployment=[deployment-name]. If the switch is present and deployment settings can be found, KivaKit will load all of the settings objects in the named deployment into the global settings ...

Read More »

From layers to onions and hexagons

java-interview-questions-answers

In this post we will explore the transition from a classic layered software architecture to a hexagonal architecture. The hexagonal architecture (also called ports and adapters architecture) is a design pattern to create loosely coupled application components. This post was inspired by a German article from Silas Graffy called Von Schichten zu Ringen – Hexagonale Architekturen erklärt. Classic layers Layering ...

Read More »

KivaKit resources

java-interview-questions-answers

A resource is a stream of data that can be opened, read from or written to, and then closed. KivaKit provides a resource mini-framework that allows easy and consistent access to many types of resources, and it makes it easy to create new resources. Examples of KivaKit resources include: FilesSocketsZip or JAR file entriesS3 objectsPackage resourcesHDFS filesHTTP responsesInput streamsOutput streams ...

Read More »