Quantcast
Channel: Tech Tutorials
Browsing all 862 articles
Browse latest View live

BeanFactoryAware Interface in Spring Framework

If a class implements org.springframework.beans.factory.BeanFactoryAware interface, then the class bean is provided with a reference to their owning BeanFactory.BeanFactoryAware interface has a single...

View Article


Excluding Bean From Autowiring in Spring

You can exclude a bean from autowiring at per-bean basis in Spring framework. If you are using Spring XML configuration then you can exclude a bean from autowiring by setting the autowire-candidate...

View Article


JDBCTemplate with ResultSetExtractor Example in Spring

In the post Select Query Using JDBCTemplate in Spring Framework we have already seen an example of extracting data from ResultSet using RowMapper. A RowMapper is usually a simpler choice for ResultSet...

View Article

BeanFactoryPostProcessor in Spring Framework

BeanFactoryPostProcessor interface in Spring resides in org.springframework.beans.factory.config package. BeanFactoryPostProcessor implementation is used to read the configuration metadata and...

View Article

How to Create Password Protected Zip File in Java

This post shows how to create a password protected zip file in Java and also how to unzip a password protected zip file in Java.Though Java provides an API (java.util.zip) for compressing and...

View Article


Benefits, Disadvantages And Limitations of Autowiring in Spring

Though autowiring in Spring makes life easy by wiring the dependencies automatically thus requiring less code to write but at the same time autowiring has few limitations and disadvantages too and that...

View Article

ServiceLocatorFactoryBean in Spring Framework

ServiceLocatorFactoryBean in Spring framework as the name suggests is an implementation of service locator design pattern and helps with locating the service at run time.ServiceLocatorFactoryBean helps...

View Article

@Import Annotation in Spring JavaConfig

If you are using JavaConfig in Spring to configure the bean definitions then, in order to modularize your configurations you can use @Import annotation.@Import annotation in Spring JavaConfig allows...

View Article


Image may be NSFW.
Clik here to view.

Internationalization (i18n) Using MessageSource in Spring

In an interview if difference between BeanFactory and ApplicationContext is asked one of the reason to use ApplicationContext is given as the support for internationalization provided by...

View Article


Image may be NSFW.
Clik here to view.

YARN in Hadoop

YARN (Yet Another Resource Negotiator) is the cluster resource management and job scheduling layer of Hadoop. YARN is introduced in Hadoop 2.x version to address the scalability issues in MRv1, it also...

View Article

Capacity Scheduler in YARN

In the post YARN in Hadoop we have already seen that it is the scheduler component of the ResourceManager which is responsible for allocating resources to the running jobs. The scheduler component is...

View Article

Uber Mode in Hadoop

When a MapReduce job is submitted, ResourceManager launches the ApplicationMaster process (For MapReduce the ApplicationMaster is MRAppMaster) on a container. Then ApplicationMaster retrieves the...

View Article

Fair Scheduler in YARN

In the post YARN in Hadoop we have already seen that it is the scheduler component of the ResourceManager which is responsible for allocating resources to the running jobs. The scheduler component is...

View Article


Speculative Execution in Hadoop

Speculative execution in Hadoop is an option to run a duplicate map or reduce task for the same input data on an alternative node. This is done so that any slow running task doesn’t slow down the whole...

View Article

Image may be NSFW.
Clik here to view.

MapReduce Flow in YARN

How a MapReduce job runs in YARN is different from how it used to run in MRv1. This post shows how MapReduce v2 runs internally in YARN Hadoop.Submitting the job First step is of course submitting the...

View Article


Data Compression in Hadoop

When we think about Hadoop, we think about very large files which are stored in HDFS and lots of data transfer among nodes in the Hadoop cluster while storing HDFS blocks or while running map reduce...

View Article

Image may be NSFW.
Clik here to view.

Data Locality in Hadoop

In this post we’ll see what is data locality in Hadoop and how it helps in minimizing the network traffic and increases the overall throughput of the cluster.Data locality optimizationTo understand...

View Article


Wildcards in Java Generics

In Java generics there is also an option of giving question mark (?) as type which is called wildcard in generics. This question mark(?) represents an unknown type.The wildcard can be used in a variety...

View Article

Bounded Type Parameter in Java Generics

In the post generics in Java you would have already seen examples where type parameters are replaced by any class type. But there are times when you want to restrict the types that can be used as type...

View Article

Compressing File in bzip2 Format in Hadoop - Java Program

This post shows how to compress an input file in bzip2 format in Hadoop. The Java program will read input file from the local file system and copy it to HDFS in compressed bzip2 format.Input file is...

View Article
Browsing all 862 articles
Browse latest View live