Tuesday Sep 01, 2015

Java 8 Date & Time

Want to learn the intricacies of the new Java 8 Date and Time API? Learn how to simplify your programming of date and time and use Java 8 Date and Time API. In the next VTS, Simon Ritter discusses how the previous APIs treated the date and time and explains the much need improvements of the new API. For example, the classes java.util.Date and SimpleDateFormatter were not thread-safe.

Java 8 introduced the JSR 310, Date and Time API, which is based on the very popular open source Joda time API. The new Java library handles the format and schedule of time and date in a much more intuitive and flexible way. Simon explains in detail how to use the new API with different formats for setting future dates, dealing with time zones, adding temporal adjustors and much more.  

VTS is a series of interactive online events with hands-on sessions and presenters answering technical questions. The events are sponsored by the Oracle Technology Network (OTN). They are free events but you must register. Join the next exclusive events near you: 

  • Americas - September 16th- 9:30am to 12:30 PST - Register 
  • EMEA - September 23rd - 9:30am to 12:30pm BST - Register
  • APAC - September 30th- 3pm to 6:30pm AU/SYD - Register

Thursday Aug 27, 2015

Just-in-Time Compilation with JITWatch

Want to optimize the performance of your code? Ben Evans and Chris Newland wrap up their three-part series about using JITWatch to understand the just-in-time (JIT) compilation techniques used by the dynamic compiler in Oracle’s Java HotSpot VM. JITWatch is a free, open source tool developed by Newland that analyzes the complex compilation log file output generated by Java HotSpot VM. Among other things, it can help you visualize and understand the optimization decisions made by Java HotSpot VM.

Part 3 describes how to use JITWatch to see the effects that even small source code changes can have on Java HotSpot VM switches. Learn about Sandbox and VM switches features. Sandbox will let you edit code and then compile, execute, and analyze the Java HotSpot VM JIT logs. The VM switches are used to control JIT compilation.

In the September/October edition of Java Magazine Ben and Chris wrote part 2, which focuses on how to examine JIT logs to see what the JIT compiler is doing (and why). Part 1 provides a primer on JIT compilation.

Wednesday Aug 26, 2015

New Java Champion Vinicius Senger

Welcome to the new Java Champion: Vinicius Senger 

Vinicius Senger is the founder of Globalcode, a company teaching programming to trainers and professionals.

He has 20 years of experience in programming. His first Java app ran in HPUX capturing SNMP data from the network and storing in Sybase. He did a number of projects with J2EE for financial services and banks using web components, EJB, JMS and many different types of architectures using JSF, Seam, Spring, etc.

In addition, he wrote programs on embedded devices and created the 2011 Duke's Choice Award project called jHome Automation that uses Java EE to provide home automation using different devices and communication protocols. He is dedicated to developing Java Embedded and Java EE projects. Last year, he implemented Java Embedded for a sailboat for JavaOne 2014. He just launched Combike project, which is a Smart Helmet for bikers using camera, GPS, accelerometer and a social network behind.

He is a frequent speaker at many Java conferences around the world including Devoxx, JFokus, and The Developer Conference in Brazil that he co-organizes. He has been a JavaOne rockstar speaker for several years.

He is a regular contributor to the Java Magazine and wrote an article about device I/O for the November 2014 issue. He also authored an IoT video series in English and Portuguese on YouTube.com/java 

Java champions are an exclusive group of passionate Java technologists and community leaders who are community-nominated. Learn more about Java Champions.   

Thursday Aug 20, 2015

DevOps, Docker, Chef…

What problems does DevOps solve, how is it used, and what are some of the tools? This new issue of the Java Magazine focuses on all things DevOps. 'DevOps has given developers more insight into how their code runs and helped admins become less risk-averse’  explains Patrick Debois, who created DevOps. Consider the example of Netflix, which reaped the benefits of using DevOps. Combine the implementation of Docker, Puppet and Vagrant to create a successful continuous delivery (CD).  


 The articles in this new issue of Java Magazine are: 
- How Dev Vs Ops became DevOps, an interview with Patrick Debois 
- Continuous Delivery of Microservices at Netflix 
- Building and Managing Lightweight Containers with Docker, Puppet and Vagrant 
- Putting the continuous in Continous Delivery with Chef 
- Functional Programming in Java: Using Collections 
- Contexts and Dependency Injection: the New Java EE Toolbox  
- Inside the CPU: the Unexpected Effects of Instruction Execution

Register for the magazine. It is free!

Wednesday Aug 19, 2015

From Technical Debt to Software Development Analytics

You’ve surely heard the term ‘technical debt’ and the many ways it has been defined, but do you know when and how it is appropriate to apply technical debt as an analytical technique? In this article, Israel Gat gives a refresher on the three of the technical debt metaphors and how you should use those metaphors.

He makes the case that technical debt can be viewed as three types of analytics. Technical Debt as a Form of:

  • Descriptive Analytics
  • Predictive Analytics
  • Prescriptive Analytics 

He also discusses when it is advantageous to apply technical debt analysis depending on the type of software project you are working on. He presents 3 kinds of projects and their  corresponding kinds of analytics. Read the full article



Tuesday Aug 18, 2015

Java 8 Update 60 Release

This latest Java 8 release includes Nashorn enhancements, and improvements to Deployment Rule Set functionality.  It also has ARM support and the Java Development Kit for ARM is part of the release 8u60 (JDK 8u60 for ARM). A substantial number of bug fixes are available in this release. Make sure to check the release notes for details. The download is available here

Quick note on another release, which is part of the Java SE Advanced and Suite. The release is Java Advanced Management Console (AMC) 2.0, a Java application usage tracking tool. New to this release is the auto detecting windows agent that assists with auto configuration of details across a wide user base. The release note is available here.   

Lizard Selfies with Raspberry Pi and Java EE

By guest blogger Roberto Marquez 

I wrote a Java EE app to manage the enclosure lighting for Chinese water dragons.  It uses servlets and cron to control relays attached to the Raspberry Pi GPIO pins.

Recently, I revisited the project to make use of the Raspberry Pi camera for lizard selfies.  The application listens for changes on GPIO pin connected to a momentary capacitive touch sensor.  When the selfie sensor pin goes high, a  photo is taken. Watch his demo series on YouTube. 

You can find the capacitive touch sensor on Adafruit. I did not find a Raspberry Pi camera cable in Fritzing, but a standard ribbon cable was used.  Here is a wiring diagram:

The source code is available on Github: https://github.com/onebeartoe/lizard-enclosure

The continuous integration server is here: https://onebeartoe.ci.cloudbees.com/job/lizard-enclosure/


Thursday Aug 13, 2015

Bytecode and Generics

At the JVM Language Summit this week,  Java VM architect John Rose presented a session called ‘New Bytecodes, New Objects.’ He discussed the state of the JVM, as well as challenges and the future of the JVM



Java Language Architect Brian Goetz presented the Adventures on the Road to Valhalla. In the past year, he has worked on prototypes for generics over primitives and generics over values. In the presentation is goes over what he has learned, the design progress and the design implementation  

The JVM Language Summit videos are available on Youtube Java Channel

Wednesday Aug 12, 2015

Solving Problems Using the Stream API

Play a game while learning about Lambdas and Stream API!  Jose Paumard introduces Shakespeare Plays Scrabble game in a Java Magazine article of the same name. He shows how you can use the Stream API, which was introduced in Java SE 8, to solve a map/filter/reduce problem that is built on the Scrabble game. As Jose points out, Java SE 8 requires developers to think differently about their coding solutions. 

By following his Scrabble example, you can learn how to use the Stream API to address some common tasks in business applications--such as building histograms, comparing histograms, and handling corner cases raised by empty streams--efficiently and without using much code. 

Jose presented the same topic in a Virtual Technology Summit session. The session is now available online as a replay


About sun.misc.Unsafe

During the JVM Language Summit this week, Java architect Mark Reinhold presented 'The Secret History and Tragic Fate of sun.misc.Unsafe' session. The API is a low level library designed strictly for use within the JDK. Mark laid out the plan for the safe replacement of the library over time. It will still be available in Java 9. 



In a second session, Paul Sandoz explains potential replacements for some usage of sun.misc.Unsafe. His presentation is 'Safety First' mentioned below 



For more information on the topic, check out: 

  • Project Jigsaw: http://openjdk.java.net/projects/jigsaw
  • JEP 260, Encapsulate Most Internal APIs: http://openjdk.java.net/jeps/260

About

Insider News from the Java Team at Oracle!

duke
Links


Search

Categories
Archives
« September 2015
SunMonTueWedThuFriSat
  
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today