Do you want to know how to develop your skillset to become a Java Rockstar?

Subscribe to our newsletter to start Rocking right now!

To get you started we give you our best selling eBooks for FREE!

 

1. JPA Mini Book

2. JVM Troubleshooting Guide

3. JUnit Tutorial for Unit Testing

4. Java Annotations Tutorial

5. Java Interview Questions

 

and many more ....

 

 

Watch Out For Recursion in Java 8’s [Primitive]Stream.iterate()

An interesting question by Tagir Valeev on Stack Overflow has recently caught my attention. To keep things short (read the question for details), while the following code works: public static Stream<Long> longs() { return Stream.iterate(1L, i -> 1L + longs().skip(i - 1L) .findFirst() .get()); } longs().limit(5).forEach(System.out::println); printing 1 2 3 4 5 The following, similar code won’t work: public static ...

Read More »

Java 8: Declare Private and Protected Methods in Interfaces

When Java 8 was introduced, we could use default methods in interfaces. The main driver for this feature was to allow expansion of an interface while retaining backward compatibility for older interface versions. One example is the introduction of the stream() method in the existing Collection classes. Sometimes, when we want to introduce several default methods, they may share some ...

Read More »

Put Your Java 8 Method References to Work

Method References As we all know by now, we can use Method References, like String::isEmpty, in Java 8 to reference a method that is being used when we, for example, stream over elements. Take a look at this code snippet: Stream.of("A", "", "B").filter(Stream::isEmpty).count(); which will produce the result 1 (because there is just one empty element in the stream). But, ...

Read More »

Create UML diagrams with simple DSL – PlantUML

Historically I disliked creating design UML diagrams, because the tooling for it mostly requires drawing boxes and connecting them with lines or arrows. I find such workflow very time consuming and wasteful. This short blog post will describe much better way to create UML diagrams. But first of all, you may argue that UML importance in today’s agile software development ...

Read More »

Verifying DateTime and Date with Hamcrest

Since I started diving into automated testing and practicing TDD, verification of date values was pain. Luckily there is nice library for legacy Date and new Java 8 DateTime APIs, which cures this pain. If you belong to healthier part of Java development community and practicing unit testing on daily basis, you probably are aware of Hamcrest Java library. It ...

Read More »

Time for some Funky SQL: Prefix Sum Calculation

This Stack Overflow question has yet again nerd-sniped me: [finding the] maximum element in the array that would result from performing all M operations Here’s the question by John that was looking for a Java solution: With an array of N elements which are initialized to 0. we are given a sequence of M operations of the sort (p; q; ...

Read More »

Just Drag and Drop to Install

The Eclipse Marketplace is a pretty cool bit of software. It provides a great place for organizations and individuals to make their software available to the community. Even cooler, however, is the Eclipse Marketplace Client which lets you browse the Eclipse Marketplace and directly install new features from within the comfort of your Eclipse IDE.           ...

Read More »

Five Essential Evaluation Criteria to choose the best Scrum Master Certifications (Infographics & Career Guide Toolkit)

Introduction I have been working with Agile methodologies for a long time (~10 years), and have had the opportunity to work with a variety of agile methodologies. In this time, I have seen the common myths around Agile been busted and I have also seen -up-close- the hype that agile purists create. The beauty of iterative methodologies is that learning ...

Read More »

Key Steps for Removing the Hive Metastore Password from the Hive Configuration

In a typical Hive installation with metadata in a MySQL configuration, a password is configured in a configuration file in clear text. This presents a few risks: 1) Unauthorized access could destroy/modify Hive metadata and disrupt workflows. A malicious user could alter Hive permissions or damage metadata. 2) This password permits hiveserver2-thrift-MySQL communication. To avoid this problem, you should use ...

Read More »

How Docker Makes Testing More Efficient

Testing your software is important. Automating your testing and having continuous integration for your project in place is a matter of best practice nowadays. Often it’s one of the first things a software team works on when starting a new project. A good test suite allows you to push changes to your product in a safe way without breaking things ...

Read More »

Want to take your Java skills to the next level?

Grab our programming books for FREE!

Here are some of the eBooks you will get:

  • Spring Interview QnA
  • Multithreading & Concurrency QnA
  • JPA Minibook
  • JVM Troubleshooting Guide
  • Advanced Java
  • Java Interview QnA
  • Java Design Patterns