Skip to main content
View Archives: Homepage | Spotlights | Articles | Weblogs

java.net Spotlight

Interfaces are completely abstract classes in Java that provide you with a uniform way to properly delineate the structure or inner workings of your program from its publicly available interface, with the consequence being a greater amount of flexibility and reusable code as well as more control over how you create and interact with other classes. More precisely, they are a special construct in Java that allows you to perform a kind of multiple inheritance i.e. classes that can be upcast to more than one class...

[01/20/2014]

The most popular technical articles published on OTN in 2013 shows the variety in Java technologies. The top article, by a large margin, was about the internet of things. The rest of the list shows lots of interest in the new Java EE 7 functionality. In honor of the upcoming Java SE 8 release, here are the top 8 articles of 2013...

[01/19/2014]

Lambda expressions have taken the programming world by storm in the last few years. Most modern languages have adopted them as a fundamental part of functional programming. JVM based languages such as Scala, Groovy and Clojure have integrated them as key part of the language. And now, Java 8 is (finally) joining in on the fun...

[01/17/2014]

The JCP 2014 Calendar has been published with some key dates for the coming year. Look for the 2013 Year in Review next week! There were four Java SE 8 JSRs that passed their JSR Public Review ballots, and subsequently published Proposed Final Draft milestones as of yesterday, and eight JSR Maintenance Review ballots that passed JCP EC vote. Also this week, the JSR 354, Money and Currency API, Public Review, led by Credit Suisse, is on the JCP EC ballot...

[01/15/2014]

The Java Development Kit 7 Update 51 (JDK 7u51) release with JavaFX 2.2.51 is available and can be downloaded from the Java SE Downloads page. For information about this release, see the JDK 7u51 Release Notes. Documentation has been updated for the following changes to the JDK...

[01/14/2014]

The second part of the Java EE 8 Community Survey is now open! During the last 5 weeks, we have been positively surprised by the community responses on the first part of the survey. We have received a lot of valuable feedback! Thanks to all who participated! If you haven't, there still time to answer Part 1. Thanks in advance for helping us to set the initial directions of Java EE 8 by participating in Part 2 of the Community Survey...

[01/13/2014]

Google Guava is an useful library that offers many different but unrelated features... However, this article is not about those features but about offering a single heavyweight Uber JAR for all. From Google’s point-of-view, providing an Uber library for all projects makes sense... However, from my point of view, this is just making my applications heavier. Cohesion is at the root of good software development...

[01/12/2014]

At Data Geekery, we love Java. And as we’re really into jOOQ’s fluent API and query DSL, we’re absolutely thrilled about what Java 8 will bring to our ecosystem. We have blogged a couple of times about some nice Java 8 goodies, and now we feel it’s time to start a new blog series, the… Java 8 Friday. Every Friday, we’re showing you a couple of nice new tutorial-style Java 8 features, which take advantage of lambda expressions, extension methods, and other great stuff...

[01/10/2014]

On December 27th, I did a virtual session via Google Hangout on the Java API for WebSocket (JSR 356) for JogloCon 2013. Organized by JUG Joglosemar, JogloCon is one of the largest Java conferences in the Yogyakarta area of Indonesia. This year, the conference focused on everything Java EE! Enjoy the slideshow below of the conference...

[01/08/2014]

What you should know before installing an agent, and how it affects your code - When building a scalable server-side application we spend considerable amount of time thinking about how we’ll monitor, operate and update our code in production. A new breed of tools have evolved to help Java and Scala developers do just that. Many of them are built on one of the most powerful ways in which external code can integrate with the JVM at runtime – Java agents.

[01/07/2014]

Twitter4J is a Java wrapper around Twitter API. While Twitter supports simple request-response interactions, in this article we will explore streaming APIs. In contrary to request-response model which is always initiated by the client, streaming API pushes data from Twitter server to the clients as soon as they are available... The question is, how would you design a Java API for streaming purposes? No surprise here: callbacks...

[01/06/2014]

An essential part of a well-written unit test is a well-written assertion. The assertion states the behavior you expect out of the system. It should tell you at a glance what a test is trying to demonstrate. It should be simple and obvious. You should not have to decipher conditional logic or sift through for loops to understand what it is doing. In addition, any non-trivial logic in a test case increases the risk of the test itself being wrong...

[01/05/2014]

It's around this time of year that people ask you to make predictions for what'll happen in the middleware market in the New Year. There's something about Christmastime that makes you throw away your usual caution and allow yourself to make predictions about technology futures, something that is fraught with danger and the potential for personal humiliation a year from now. Well, here go my predictions for Java middleware in 2014...

[01/04/2014]

We’re all used to employing reflection in our everyday work, either directly, or through frameworks that leverage it. Its a main aspect of Java and Scala programming that enables the libraries we use to interact with our code without hard-coded knowledge of it. But our use of reflection is only limited to Java and Scala code that runs inside the JVM. What if we could use reflection to look not only into our code at run-time, but into the JVM’s code as well? When we began building Takipi...

[01/02/2014]

At the end of each calendar year, I like to summarize some of the most significant developments in the software development industry that happened during the year that is ending. The choice of these is entirely subjective and obviously colored by my own experience, background, perceptions, and preferences... I now present the developments in software development that I consider most significant in 2013...

[01/01/2014]

JAX-RS 2.0 aka JSR 339 not also specifies the API to build up a RESTful webservice but also enhances the client side API to easen up the process of writing a client for a REST service. In the following tutorial we’re building up a client for a ready-to-play REST service and explore the different new options, e.g. ...

[12/30/2013]

In this post we’ll take a deeper look at acceptance testing as a practice and see what the tools gain us. Acceptance Testing is an agile practice that refers to functional testing a user story. Sometimes it is referred to as Agile Acceptance Testing or Specification by Example. Acceptance testing addresses one of the most significant problems in software development: the requirements...

[12/29/2013]

Java EE 7 includes the new JSR 344 (JSF 2.2) standard and provides developers with new features like Resource Library Contracts, HTML5 Friendly Markup, and Faces Flows. The Liferay Faces team is hard at work at providing 1st class support for JSF 2.2 in Liferay Faces 4.x including the following new portlet demos...

[12/28/2013]

Java 8 will go GA in March 2014. The first proposed final draft of Java 8 JSR 337 was released early this week. One of the main components of this JSR is Lambda Expressions for the language (JSR 337). This brings the functional constructs to the language, which will undeniably make Java a top contender among other functional peers (Scala, Groovy, Clojure) on the JVM for Java developers. Conciseness is only part of the story...

[12/25/2013]

All of the Java.next languages include functional programming constructs, which enable you to think at a higher level of abstraction. However, differences in terminology among the languages can make it difficult to see similar constructs. This installment shows how common functional programming constructs manifest in the Java.next languages, pointing out some subtle differences in the implementation details of those features...

[12/24/2013]

2013 was a year of Java releases, good news, less good news, and a community that just keeps on truckin'. Thanks for a great year! Release of Java EE 7: Java EE 7 was the result of industry-wide development involving open review, ongoing builds, and extensive collaboration between hundreds of engineers from more than 30 companies. Key features included better support for HTML5, websockets, JAX-RS 2.0, an update to JMS 2.0 and more. Java and the Internet of Things: From Forbes to Business Insider, everyone was waking up to the Internet of Things (IoT)...

[12/23/2013]

Let's set up NetBeans IDE 7.4 to use Python. Go to Tools | Plugins and the Plugin Manager opens. In the Settings tab of the Plugin Manager, add a new update center with this URL: http://bit.ly/1fzL5mF Then go to the "Available Plugins" tab of the Plugin Manager and you'll find Python...

[12/22/2013]

That is the agile lean goal, to deliver value at a constant pace with minimum manual intervention right? I have written before about continuously releasing snapshots but in reality what you want to make sure is that once something is tested it can be deployed and that can only be achieved if what you have tested and verified is a release. Here is how to use Maven and Jenkins to help the team with continuous releases of maven projects. The proposal here is...

[12/20/2013]

We decided to pick five of today’s most prominent logging engines, and see how they perform in a number of races. Now, before you take out the torches and pitchforks, I wanted to clarify that the point is not to say which is better, but to give a sense of the differences in throughput between the engines across a number of common logging tasks...

[12/18/2013]

WebSocket is a cool new(ish) technology that allows real-time, two-way communication between the browser and the server, with almost no overhead. What I want to do here, is to provide a very succinct, but sufficient overview of how to start using the technology. So, a few things to start with: * a tcp socket connection is opened between the browser and the server, and each party can send messages to the other...

[12/17/2013]

IT is all about streamlining and automation, so it is somewhat ironic that we developers still tolerate repetitive and boring manual tasks, such as deployment. Also, our ignorance about easily accessible information for application servers, such as monitoring data, is surprising... This article describes the GlassFish management API, which allows you to manipulate the GlassFish application server's configuration, including its monitoring capabilities. It also describes the GlassFish monitoring API, which provides a read-only facility for accessing the Java Virtual Machine (JVM), the GlassFish application server, and the GlassFish application server's metrics and counters...

[12/16/2013]

Just recently I was engaged to assist with an application that wasn’t behaving. The application, running in a 1.7.0_45 JVM, relied heavily on a 3rd party SAAS framework. That vendor provided my client with a list of 26 different JVM flags that should be set. When faced with this long list of flags I couldn’t resist asking why all the flags and why these flags. After all there are more than 700 product flags defined in the JVM and to be honest, I’ve only a vague idea of the effect may have on a runtime. Take the flag AggressiveOpts for example...

[12/15/2013]

It has been a busy month in the JCP program. Many updates to share with you below... Star Spec Lead nominations are still open for 2013 until Monday, 16 December. This is a great opportunity to recognize your favorite JSR Specification Lead. The November EC meeting summary and materials are available. This was the first EC Meeting with the newly elected 2013-2014 EC...

[12/13/2013]

There’s been a number of nice articles written about graphs, graph databases, and, more specifically, Neo4j in the past couple of months. Each one jumping on the hype train and brimming with ‘revelations’ about the coolness of graph databases in general - especially Neo4j. In this article, we would like to continue this love-in by shining a spotlight on a couple of fantastic new features that are part of Neo4j 2.0...

[12/11/2013]

In this video interview, Java Evangelist Jim Weaver, Senior Engineer Gerrit Grunwald and Community Manager Yolande Poirier discussed the Internet of Things(IoT), Java Embedded, and the new IoT community page on Java.net. The page gathers blogs, resources and many sample applications from Java developers who create embedded applications with Java...

[12/10/2013]