Welcome!

Weblogic Authors: Yeshim Deniz, Elizabeth White, Michael Meiner, Michael Bushong, Avi Rosenthal

Related Topics: Weblogic, Java IoT

Weblogic: Article

Putting Enerjy Software Tools To The Test at JavaOne 2005

From set top boxes to wireless messaging

As an independent software developer/consultant starting my career in the early '90s, I was exposed to a large number of different working environments and challenges. My specialty for a while was HP C++ and Motif (often using Interface Architect) on HP-UX, but over the years I migrated towards Sun's C++ and GCC compilers along with X Designer on Solaris. Regardless of the compiler or platform or challenge, there were a couple of tools I always had to have on hand Purify and Quantify (now available from IBM Rational), because they were absolutely invaluable in helping identify subtle problems in C and C++ code.

However, as the '90s drew to a close, I became an independent Java developer, and things like memory analysis, for example, wasn't necessary. Java's got a garbage collector after all, so we don't have to worry about that sort of thing, do we? Some of you are smirking as you read this, because you know the sarcasm with which I wrote that.

Before I let go of my C++ analogies, there was another tool that I carried around with me in my C/C++ days, but this one was a stack of paper rather than a piece of software. It was a document called "Programming in C++, Rules and Recommendations" by Ellemtel Telecommunication System Laboratories, and was an excellent starting point for getting a new team of disparate software developers coding in a standard fashion. Without any intervention, different developers will write code in different styles, leading to delays and potential comprehension problems. Setting coding standards makes it easier for developers to read and understand each other's code.

I'm sharing my past experiences with C/C++ tools with you as a backdrop to a discovery I made a couple of years ago after I forayed into the world of Java development...a discovery that I'll share with you in this product review.

Early in 2002, I stumbled across the Enerjy Software exhibit at a Sun TechDays event in London and was instantly impressed. This article will tell you about my experience using Enerjy's four Java development tools: Enerjy Code Analyzer, Enerjy Memory Profiler, Enerjy Performance Profiler, and Enerjy Thread Profiler. For any Java developer looking to eliminate coding inconsistencies and establish coding best practices, or wanting to combat memory, performance, and thread deadlock issues with Java, this review is for you.

Before I give you the lowdown on the tools, let me describe the development environment in which I work and the sort of Java applications I write. I use Sun's JDK 1.4.2 with Eclipse 3.0 to write real-time data presentation applications (live data feeds). These apps often involve either an Oracle or Sybase database and/or a Web site. In all cases, I'm working on data presentation, graphics, Java3D, and the like. When I wrote this, I reviewed Edition 6 of the Enerjy tools.

Now on to my review of the tools...

Enerjy Code Analyzer
Enerjy describes Enerjy Code Analyzer as a "best-practices audit tool," but I prefer to think of it in terms of a tool that pinpoints deviations from a "fully configurable" set of rules and recommendations. It's a feature-rich, powerful, low-cost Java code analyzer that I use to rapidly validate the code contributions from the half-dozen Java developers on my project, some of whom are in a different country, making it hard to look over their shoulder as I would if they sat near me.

Enerjy Code Analyzer goes beyond pointing out issues with syntax, layout, and style; it's also extremely language-aware. By that, I mean that it identifies omissions and potential errors such as "Switch statement missing default," "Inner class does not use outer class," and "Field hides a superclass field"; mistakes that even the most experienced developer can make. In all, it identifies violations of over 200 Java and J2EE rules and lets you write your own rules for Java code analysis and reporting if there's something unusual that you want it to watch out for.

Enerjy Code Analyzer integrates tightly with most common IDEs: Eclipse, WebSphere Studio Application Developer, JBuilder, JDeveloper, NetBeans and Sun ONE on Windows, Solaris, and Linux (x86). Alternately, it can be run as an Ant process - as part of a nightly build, for example - producing a text, HTML, or XML report by project or by each developer. Whether looking at the output in report form or highlighting it directly in the IDE (as shown by the tooltip and problem pane in Figure 1), the problems are well described and located for easy identification and resolution.

Code Analyzer's other features include rule prioritization and file filtering.

Rule prioritization lets you prioritize the existing rules as well as the ones you custom-build. And because of its tight IDE integration, the assigned priority looks just like your IDE's prioritization convention. If necessary, you can choose to fail a build if certain rules have been violated.

File filtering is a neat feature that lets a developer ignore certain code...like auto-generated code that will be overwritten later on. Code Analyzer lets you remove single files or entire packages from consideration.

Whether used by a team leader to check that all team members are obeying the coding standard or used by oneself as a constant reminder that there can be no slacking in professional software development, Enerjy Code Analyzer is great for focusing on quality. Over the years I've come to believe that if you establish coding standards with every development project, you'll pre-empt bugs, save time, and develop more stable and reliable applications. And it doesn't make a difference if you're working in a large team for a big corporation or on your own, making a small application for a client - the need for quality and consistency is the same.

Enerjy Profilers
I'll break down the individual profiling tools in a minute, but there are some common features shared by all three of Enerjy's profilers that are worth pointing out upfront.

First of all, just as with Enerjy Code Analyzer, all of the profilers integrate tightly with the IDE. In the case of the profilers, they work with Eclipse, WebSphere Studio Application Developer, and JBuilder on Windows, Solaris, and Linux (x86). Each tool profiles existing launches with minimal configuration from the IDE directly.

All three profilers feature graphical representations of the data and display real-time status views of heap and thread activity while profiling. Finally, the data from the profilers can be exported in tab-delimited or comma-separated format, letting you view, print, or chart your progress.

Enerjy Memory Profiler
Enerjy Memory Profiler exists to help you understand what's really going on behind the scenes of your memory allocation calls. Integrated with the IDEs outlined above, it can display a real-time status view of heap and thread activity, and it associates heap and object graph artifacts directly back to the relevant methods. Figure 2 shows an example of Memory Profiler with the change in memory usage of a particular application over time.

Do you really know how much memory your application or even a particular method is allocating? Memory Profiler can tell you. By monitoring individual methods, it can tell you how often they're called and the number and size of the objects actually being allocated.

Are you certain that you're not leaking any memory every time you use a certain method? Don't forget that the garbage collector can only recycle memory if nothing is holding a reference to it. Memory Profiler identifies Java memory leaks that survive method boundaries, showing where the object was allocated and how it escaped garbage collection.

A cool feature of Memory Profiler - something I haven't seen in other Java profilers - is something called "on-the-fly profiling." Basically a developer can change configuration settings on-the-fly - while the application is being profiled - without having to restart the application. Any developer who's had to do this knows how frustrating it is and the time it takes away from the curly braces and semicolons.

More Stories By Alan Barclay

Alan Barclay holds an honors degree in electronic and information engineering, and is a hardware and software engineer at Electric Scribe. He has been writing Java applications since the beginning of 1998, and is a Sun Certified Programmer for the Java 2 Platform 1.4.

Comments (2) View Comments

Share your thoughts on this story.

Add your comment
You must be signed in to add a comment. Sign-in | Register

In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.


Most Recent Comments
WLDJ News Desk 07/28/05 07:44:02 AM EDT

Putting Enerjy Software Tools To The Test at JavaOne 2005. As an independent software developer/consultant starting my career in the early '90s, I was exposed to a large number of different working environments and challenges. My specialty for a while was HP C++ and Motif (often using Interface Architect) on HP-UX, but over the years I migrated towards Sun's C++ and GCC compilers along with X Designer on Solaris.

Alan Barclay 06/27/05 06:25:44 PM EDT

Putting Enerjy Software Tools to the Test. As an independent software developer/consultant starting my career in the early '90s, I was exposed to a large number of different working environments and challenges. My specialty for a while was HP C++ and Motif (often using Interface Architect) on HP-UX, but over the years I migrated towards Sun's C++ and GCC compilers along with X Designer on Solaris. Regardless of the compiler or platform or challenge, there were a couple of tools I always had to have on hand Purify and Quantify (now available from IBM Rational), because they were absolutely invaluable in helping identify subtle problems in C and C++ code.

However, as the '90s drew to a close, I became an independent Java developer, and things like memory analysis, for example, wasn't necessary. Java's got a garbage collector after all, so we don't have to worry about that sort of thing, do we? Some of you are smirking as you read this, because you know the sarcasm with which I wrote that.

Before I let go of my C++ analogies, there was another tool that I carried around with me in my C/C++ days, but this one was a stack of paper rather than a piece of software. It was a document called "Programming in C++, Rules and Recommendations" by Ellemtel Telecommunication System Laboratories, and was an excellent starting point for getting a new team of disparate software developers coding in a standard fashion. Without any intervention, different developers will write code in different styles, leading to delays and potential comprehension problems. Setting coding standards makes it easier for developers to read and understand each other's code.

I'm sharing my past experiences with C/C++ tools with you as a backdrop to a discovery I made a couple of years ago after I forayed into the world of Java development...a discovery that I'll share with you in this product review.

Early in 2002, I stumbled across the Enerjy Software exhibit at a Sun TechDays event in London and was instantly impressed. This article will tell you about my experience using Enerjy's four Java development tools: Enerjy Code Analyzer, Enerjy Memory Profiler, Enerjy Performance Profiler, and Enerjy Thread Profiler. For any Java developer looking to eliminate coding inconsistencies and establish coding best practices, or wanting to combat memory, performance, and thread deadlock issues with Java, this review is for you.

Before I give you the lowdown on the tools, let me describe the development environment in which I work and the sort of Java applications I write. I use Sun's JDK 1.4.2 with Eclipse 3.0 to write real-time data presentation applications (live data feeds). These apps often involve either an Oracle or Sybase database and/or a Web site. In all cases, I'm working on data presentation, graphics, Java3D, and the like. When I wrote this, I reviewed Edition 6 of the Enerjy tools.

Now on to my review of the tools...

Enerjy Code Analyzer
Enerjy describes Enerjy Code Analyzer as a "best-practices audit tool," but I prefer to think of it in terms of a tool that pinpoints deviations from a "fully configurable" set of rules and recommendations. It's a feature-rich, powerful, low-cost Java code analyzer that I use to rapidly validate the code contributions from the half-dozen Java developers on my project, some of whom are in a different country, making it hard to look over their shoulder as I would if they sat near me.

Enerjy Code Analyzer goes beyond pointing out issues with syntax, layout, and style; it's also extremely language-aware. By that, I mean that it identifies omissions and potential errors such as "Switch statement missing default," "Inner class does not use outer class," and "Field hides a superclass field"; mistakes that even the most experienced developer can make. In all, it identifies violations of over 200 Java and J2EE rules and lets you write your own rules for Java code analysis and reporting if there's something unusual that you want it to watch out for.

Enerjy Code Analyzer integrates tightly with most common IDEs: Eclipse, WebSphere Studio Application Developer, JBuilder, JDeveloper, NetBeans and Sun ONE on Windows, Solaris, and Linux (x86). Alternately, it can be run as an Ant process - as part of a nightly build, for example - producing a text, HTML, or XML report by project or by each developer. Whether looking at the output in report form or highlighting it directly in the IDE (as shown by the tooltip and problem pane in Figure 1), the problems are well described and located for easy identification and resolution.

Code Analyzer's other features include rule prioritization and file filtering.

Rule prioritization lets you prioritize the existing rules as well as the ones you custom-build. And because of its tight IDE integration, the assigned priority looks just like your IDE's prioritization convention. If necessary, you can choose to fail a build if certain rules have been violated.

File filtering is a neat feature that lets a developer ignore certain code...like auto-generated code that will be overwritten later on. Code Analyzer lets you remove single files or entire packages from consideration.

Whether used by a team leader to check that all team members are obeying the coding standard or used by oneself as a constant reminder that there can be no slacking in professional software development, Enerjy Code Analyzer is great for focusing on quality. Over the years I've come to believe that if you establish coding standards with every development project, you'll pre-empt bugs, save time, and develop more stable and reliable applications. And it doesn't make a difference if you're working in a large team for a big corporation or on your own, making a small application for a client - the need for quality and consistency is the same.

Enerjy Profilers
I'll break down the individual profiling tools in a minute, but there are some common features shared by all three of Enerjy's profilers that are worth pointing out upfront.

First of all, just as with Enerjy Code Analyzer, all of the profilers integrate tightly with the IDE. In the case of the profilers, they work with Eclipse, WebSphere Studio Application Developer, and JBuilder on Windows, Solaris, and Linux (x86). Each tool profiles existing launches with minimal configuration from the IDE directly.

All three profilers feature graphical representations of the data and display real-time status views of heap and thread activity while profiling. Finally, the data from the profilers can be exported in tab-delimited or comma-separated format, letting you view, print, or chart your progress.

Enerjy Memory Profiler
Enerjy Memory Profiler exists to help you understand what's really going on behind the scenes of your memory allocation calls. Integrated with the IDEs outlined above, it can display a real-time status view of heap and thread activity, and it associates heap and object graph artifacts directly back to the relevant methods. Figure 2 shows an example of Memory Profiler with the change in memory usage of a particular application over time.

Do you really know how much memory your application or even a particular method is allocating? Memory Profiler can tell you. By monitoring individual methods, it can tell you how often they're called and the number and size of the objects actually being allocated.

Are you certain that you're not leaking any memory every time you use a certain method? Don't forget that the garbage collector can only recycle memory if nothing is holding a reference to it. Memory Profiler identifies Java memory leaks that survive method boundaries, showing where the object was allocated and how it escaped garbage collection.

A cool feature of Memory Profiler - something I haven't seen in other Java profilers - is something called "on-the-fly profiling." Basically a developer can change configuration settings on-the-fly - while the application is being profiled - without having to restart the application. Any developer who's had to do this knows how frustrating it is and the time it takes away from the curly braces and semicolons.

@ThingsExpo Stories
SYS-CON Events announced today that Yuasa System will exhibit at the Japan External Trade Organization (JETRO) Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Yuasa System is introducing a multi-purpose endurance testing system for flexible displays, OLED devices, flexible substrates, flat cables, and films in smartphones, wearables, automobiles, and healthcare.
SYS-CON Events announced today that Taica will exhibit at the Japan External Trade Organization (JETRO) Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Taica manufacturers Alpha-GEL brand silicone components and materials, which maintain outstanding performance over a wide temperature range -40C to +200C. For more information, visit http://www.taica.co.jp/english/.
Enterprises have taken advantage of IoT to achieve important revenue and cost advantages. What is less apparent is how incumbent enterprises operating at scale have, following success with IoT, built analytic, operations management and software development capabilities – ranging from autonomous vehicles to manageable robotics installations. They have embraced these capabilities as if they were Silicon Valley startups. As a result, many firms employ new business models that place enormous impor...
SYS-CON Events announced today that SourceForge has been named “Media Sponsor” of SYS-CON's 21st International Cloud Expo, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. SourceForge is the largest, most trusted destination for Open Source Software development, collaboration, discovery and download on the web serving over 32 million viewers, 150 million downloads and over 460,000 active development projects each and every month.
SYS-CON Events announced today that Dasher Technologies will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Dasher Technologies, Inc. ® is a premier IT solution provider that delivers expert technical resources along with trusted account executives to architect and deliver complete IT solutions and services to help our clients execute their goals, plans and objectives. Since 1999, we'v...
As popularity of the smart home is growing and continues to go mainstream, technological factors play a greater role. The IoT protocol houses the interoperability battery consumption, security, and configuration of a smart home device, and it can be difficult for companies to choose the right kind for their product. For both DIY and professionally installed smart homes, developers need to consider each of these elements for their product to be successful in the market and current smart homes.
SYS-CON Events announced today that MIRAI Inc. will exhibit at the Japan External Trade Organization (JETRO) Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. MIRAI Inc. are IT consultants from the public sector whose mission is to solve social issues by technology and innovation and to create a meaningful future for people.
SYS-CON Events announced today that Massive Networks, that helps your business operate seamlessly with fast, reliable, and secure internet and network solutions, has been named "Exhibitor" of SYS-CON's 21st International Cloud Expo ®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. As a premier telecommunications provider, Massive Networks is headquartered out of Louisville, Colorado. With years of experience under their belt, their team of...
SYS-CON Events announced today that TidalScale, a leading provider of systems and services, will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. TidalScale has been involved in shaping the computing landscape. They've designed, developed and deployed some of the most important and successful systems and services in the history of the computing industry - internet, Ethernet, operating s...
Widespread fragmentation is stalling the growth of the IIoT and making it difficult for partners to work together. The number of software platforms, apps, hardware and connectivity standards is creating paralysis among businesses that are afraid of being locked into a solution. EdgeX Foundry is unifying the community around a common IoT edge framework and an ecosystem of interoperable components.
Coca-Cola’s Google powered digital signage system lays the groundwork for a more valuable connection between Coke and its customers. Digital signs pair software with high-resolution displays so that a message can be changed instantly based on what the operator wants to communicate or sell. In their Day 3 Keynote at 21st Cloud Expo, Greg Chambers, Global Group Director, Digital Innovation, Coca-Cola, and Vidya Nagarajan, a Senior Product Manager at Google, will discuss how from store operations...
In a recent survey, Sumo Logic surveyed 1,500 customers who employ cloud services such as Amazon Web Services (AWS), Microsoft Azure, and Google Cloud Platform (GCP). According to the survey, a quarter of the respondents have already deployed Docker containers and nearly as many (23 percent) are employing the AWS Lambda serverless computing framework. It’s clear: serverless is here to stay. The adoption does come with some needed changes, within both application development and operations. Tha...
SYS-CON Events announced today that IBM has been named “Diamond Sponsor” of SYS-CON's 21st Cloud Expo, which will take place on October 31 through November 2nd 2017 at the Santa Clara Convention Center in Santa Clara, California.
In his Opening Keynote at 21st Cloud Expo, John Considine, General Manager of IBM Cloud Infrastructure, will lead you through the exciting evolution of the cloud. He'll look at this major disruption from the perspective of technology, business models, and what this means for enterprises of all sizes. John Considine is General Manager of Cloud Infrastructure Services at IBM. In that role he is responsible for leading IBM’s public cloud infrastructure including strategy, development, and offering ...
Infoblox delivers Actionable Network Intelligence to enterprise, government, and service provider customers around the world. They are the industry leader in DNS, DHCP, and IP address management, the category known as DDI. We empower thousands of organizations to control and secure their networks from the core-enabling them to increase efficiency and visibility, improve customer service, and meet compliance requirements.
Join IBM November 1 at 21st Cloud Expo at the Santa Clara Convention Center in Santa Clara, CA, and learn how IBM Watson can bring cognitive services and AI to intelligent, unmanned systems. Cognitive analysis impacts today’s systems with unparalleled ability that were previously available only to manned, back-end operations. Thanks to cloud processing, IBM Watson can bring cognitive services and AI to intelligent, unmanned systems. Imagine a robot vacuum that becomes your personal assistant tha...
With major technology companies and startups seriously embracing Cloud strategies, now is the perfect time to attend 21st Cloud Expo October 31 - November 2, 2017, at the Santa Clara Convention Center, CA, and June 12-14, 2018, at the Javits Center in New York City, NY, and learn what is going on, contribute to the discussions, and ensure that your enterprise is on the right path to Digital Transformation.
Recently, REAN Cloud built a digital concierge for a North Carolina hospital that had observed that most patient call button questions were repetitive. In addition, the paper-based process used to measure patient health metrics was laborious, not in real-time and sometimes error-prone. In their session at 21st Cloud Expo, Sean Finnerty, Executive Director, Practice Lead, Health Care & Life Science at REAN Cloud, and Dr. S.P.T. Krishnan, Principal Architect at REAN Cloud, will discuss how they b...
SYS-CON Events announced today that mruby Forum will exhibit at the Japan External Trade Organization (JETRO) Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. mruby is the lightweight implementation of the Ruby language. We introduce mruby and the mruby IoT framework that enhances development productivity. For more information, visit http://forum.mruby.org/.
Digital transformation is changing the face of business. The IDC predicts that enterprises will commit to a massive new scale of digital transformation, to stake out leadership positions in the "digital transformation economy." Accordingly, attendees at the upcoming Cloud Expo | @ThingsExpo at the Santa Clara Convention Center in Santa Clara, CA, Oct 31-Nov 2, will find fresh new content in a new track called Enterprise Cloud & Digital Transformation.