Home » Java » Enterprise Java

Enterprise Java

Quickly creating URIs with UriBuilder

java-interview-questions-answers

If you have access to the JAX-RS API and an implementation in your projects (many do), then you can use JAX-RS’ UriBuilder to conveniently create URIs via builder pattern using resolvable placeholder. Have a look at the following example: 1 2 3 4 5 6 7 String host = System.getProperty("host", "localhost"); String port = System.getProperty("port", "8080");   URI uri = ...

Read More »

Quarkus’ additional (non-standard) CDI features

java-interview-questions-answers

Quarkus supports CDI (Contexts and Dependency Injection) 2.0, but not all of it, only the most common features. However, Quarkus does include some non-standard features that can come in quite handy to developers which I want to show in the following video. Whether or not you’re familiar with CDI, if you use Quarkus you should have a look at the ...

Read More »

Invoking Secure WCF SOAP Service using SoapUI – Part 1, The service

java-interview-questions-answers

In this saga divided into three-part, I will demonstrate how to use the SoapUI API tool to invoke a secured SOAP service. Firstly, I will focus on creating a service where in the next posts it will serve as the system under test. The access to the resource in this service is maintained using Basic Authentication transport security mechanisms. One of many provided by ...

Read More »

Spring Boot tests with Testcontainers and PostgreSQL, MySQL or MariaDB

Testcontainers is a Java library that allows integrating Docker containers in JUnit tests with ease. In a Containerized World, there is little sense to complicate the tests configuration with embedded databases and services. Instead, use run your services in Docker and let the Testcontainers manage this for you. In this blog post you will learn how to configure Testcontainers to ...

Read More »

All You Need To Know About UI Testing

Let’s start with a question. What is the first thing that a user interacts with on a website? The interface, of course. The look and feel of the website is the first thing that creates the “First Impression” on the users. An interactive web application can make or break the deal for users, this is why more and more people ...

Read More »

Complete Guide To Selenium Locators In Protractor (Examples)

While testing the functionality for your website, especially web elements such as radio button, text boxes, drop-down, etc., you need to make sure that you are able to access these elements. Selenium locators serve this exact purpose, by using this command we can identify these web elements, DOM (Document Object Model), to perform Selenium test automation through our scripts. These ...

Read More »

Clean Unit Testing

It’s easy to write “unit test” tests that use JUnit and some mocking library. They may produce code coverage that keeps some stakeholders happy, even though the tests aren’t even unit tests and provide questionable value. It can also be very easy to write unit tests that are — in theory — units test but are more complex than the ...

Read More »

AWS Lambda to save data in DynamoDB

java-interview-questions-answers

In this tutorial, we will see how using AWS Lambda we can save data in Dynamo DB. Here are the steps which are required : –Create a table in the Dynamo DB with the name Employee– Create a AWS Lambda function which can save firstName and surName of an employee using a Employee POJO in the Dynamo DB– Create a ...

Read More »