Java

TestNG Listners: ITestlistners in TestNG(Part 1)

Reading Time: 3 minutes TestNG provides the @Listeners annotation which heedfully auricularly discerns every event that occurs in a selenium code. Listeners are activated either afore the test or after the test case. It is an interface that modifies the TestNG comportment. For example, when you are running a test case either through selenium or appium and suddenly a test case fails. We require a screenshot of the test Continue Reading

Configuration file for log4j: An introduction

Reading Time: 3 minutes Log4j.xml is nothing but configuration file of log4j means you can customize loggers, in this blog we will be looking into this file to now the nuts and bolts of it. Log4j is a java based logging utility used for logging. Logging is an essential add on for any application. It not just printing the messages but also gives you detailed information about the messages. Continue Reading

Different ways of Handling Exceptions in CompletableFutures

Reading Time: 3 minutes Hi Folks! As part of this blog, we will explore how we can handle exception in the different computing stages when we use CompletableFuture. We assume the read has the basic idea of the CompletableFuture. Nonethless, will start with the basic introduction of the CompletableFuture. What is CompletableFuture A CompletableFuture is used for asynchronous programming which was introduced as an improvement of the java Future API in Continue Reading

Is Logback the Solution to Your Logging Problems?

Reading Time: 4 minutes What do you do when you get an error/issue with the code? What is the first thought that comes to your mind? What if you are trying to fix a code that was written by someone else?   That’s right. We check the logs. We all know that Useful logs can provide the developer ( especially when someone has to debug/maintain someone else’s code ) Continue Reading

Reactive Java: Handling Errors in Reactive Streams

Reading Time: 4 minutes  If errors and failures are passed to the right component, which can handle them as notifications, the application can become more fault-tolerant or resilient. So if we build our system to be event-driven, we can more easily achieve scalability and failure tolerance, and a scalable, decoupled, and error-proof application is fast and responsive to users.” Nickolay Tsvetinov Reactive in layman’s language says how quickly the client Continue Reading

Functional Java: Should I really start using the functional paradigm in Java?

Reading Time: 5 minutes I am pretty sure, at some point, you must have had this question in your mind because everywhere, it is functional programming, immutability, higher-order functions, and blah blah. As a java developer, you must have confused, whether should I move to the functional programming paradigm? What are the benefits it provide to us? People are talking about it everywhere. So let’s give it a try Continue Reading

Test report for Rest Assured

Reading Time: 3 minutes Test report is generally a communication bridge between test manager and stakeholder. The stakeholder can understand the project situation with test report only. One of the use case will be evaluating the quality using test report. It is because you want to make decisions based on those reports for example if there are number of defects remaining the project, we simply not release the project. Continue Reading

Aspect Oriented Programming with Spring

Reading Time: 4 minutes What is AOP? Applications are generally developed with multiple layers. A typical Java application has Web Layer – Exposing the services to the outside world using REST or a web application Business Layer – Business Logic Data Layer – Persistence Logic While the responsibilities of each of these layers are different, there are a few common aspects that apply to all layers Logging Security These Continue Reading

Composition over Inheritance: Part 1

Reading Time: 4 minutes Inheritance Inheritance happens to be one of the prime features of the Java language and is one of the key requirements for Object-Oriented Programming. It provides a lot of help in reducing code repetition, helps in designing the application and whatnot. However, for the best use of this feature, we must also know when we shall avoid using it. Just like any other feature of Continue Reading