The Java ExecutorService interface, java.util.concurrent.ExecutorService, represents an asynchronous execution mechanism which is capable of executing tasks concurrently in the background. In this post, We would discuss list of interfaces to run task in parallel in Java using Concurrency utilities. public interface Executor – An Executor that provides methods to manage termination and methods that can produce a Future for tracking progress of
Browsing category Java
Software architect should select proper architecture to develop an software system. For external stakeholders and customers, it is only functional requirement. There are many factors helps to decide the architecture for an application. Let us explore the factors decide the software architecture, Architectural drivers. Architecture requirements are not only functional requirements Architectural drivers are formally
Static program analysis(Static Code Analysis) is the analysis of computer software that is performed without actually executing programs — Wikipedia. This blog, we would discuss on Static Code Analysis. Static code analysis refers to the technique of approximating the runtime behavior of a program. In other words, it is the process of predicting the output
In last post, we discussed on exception handling, checked exception. try…catch block helps to handle the exception. Let us discuss DRY principle before discuss on finally block. The DRY(Don’t Repeat Yourself) is a principle of software development aimed to avoid repetition of same code in multiple places.. The DRY principle is stated as, “Every piece
Java provides framework to catch the exception and handle the exception by try…catch block. Java exceptions are grouped into two major categories checked exception and unchecked exception. Checked exception are caused by undesirable or unexpected condition. It can be recoverable by handling the issue in catch block such as one of the server port in
In last discussion, we discussed on Exceptions and handling the exception. Now we would discuss one level up in the exception hierarchy Throwable and Error. Throwable class provides basic implementation for handling serious issue or recoverable issue in the code. All the Throwable and child of Throwable class objects can be thrown and handled
In software industry, 80% of the effort spend on debugging and resolving the issues in the application. So identifying the issues, finding the problematic code block and handling the issues are important. It would greatly reduce the programmer’s effort to debug and fix the issue. Java provides elegant way to identify and handle the issue
In previous blog, we discussed on String and string constant pool. It highlighted the issue in String manipulation and how it fill the pool memory. We not recommended to use String for temporary string statement formation, logger statement, updatable string values, large file I/O stream of input processing. We can process these operation using String
Manipulation of String (Sequence of characters) is most important aspect of programming language. Name, id, address, role and username all manipulated as String in programming world. Java is no different from other language while using the String. In Java, String is sequence of characters and handled to make efficient use of memory. Strings are managed
In the previous post, we discussed on inner class for “one and only for” relationship among the classes. But static nested class not for same purpose, it is to add namespace to the class. It can be instantiated just with top class name (without top class instance). Static nested class is class scoped within another.