- Struts2 Tutorials – Several tutorials are available to help you get started with the framework, from all-purpose “soup to nuts” tutorials to specialty tutorials on portlets and database access.
- GnilronEye 1.1, system monitoring solution, released – GnilronEye 1.1, a java-based system monitoring solution, is now available for download. GnilronEye 1.1 introduces an advanced http-monitoring feature and a new report feature that include sgraphs of the monitored items.
- A CSS styled table version 2 | Veerle’s blog – In 2005 I wrote an article about styling a table with CSS. After receiving so many requests I finally decided to give in and write another tutorial.
- Scrollovers – A New Way of Linking – Scrollovers are a way to quickly and easily add flair to your web pages, giving your users an experience they weren’t expecting.
- Death by numbers – Los Angeles Times – We’re obssessed with plane crashes and bridge collapses, yet we pay little attention to the stuff that kills the rest of us.
- Sun set on server business? | Open Source | ZDNet.com – In all the hullaballoo over Sun?s agreement to support Solaris 10 on IBM hardware I have yet to read one obvious fact. This is part of Sun?s exit strategy from the server business.
- Ajaxian » YUI Compressor: The latest minification tool – The YUI Compressor is a new JavaScript minifier. Its level of compaction is higher than the Dojo compressor, and it is as safe as JSMin. Tests on the YUI library have shown savings of about 18% compared to JSMin and 10% compared to the Dojo compressor
- Tutorials – Using Java Persistence API Within a Visual Web Application – Using NetBeans IDE 6.0 and the Visual Web tools, you can write applications that connect to database tables using the Java Persistence API (JPA) in addition to the Visual Web data provider components.
- Enterprise Java Community: Manage test data for integration tests using Spring and DBunit – This article will look at configuring integration tests using Spring and DBUnit so that test data is inserted into the database before every test. This article also looks at a utility to export/import test data in the database using DBunit.
- How to Get the Best Performance Out of a Java Persistence Implementation : Enterprise Tech Tips – If you are switching over to the Java Persistence API, be aware of the numerous options and decisions you have to make to boost your application’s performance. From Cache size, Pools to modes of operation, Rahul Biswas takes you through the steps. (via Th
- Prototype JavaScript framework: Prototype 1.6.0 release candidate – The first release candidate of Prototype 1.6.0 has arrived! The core team is continuing its tradition of bringing thoughtful incremental upgrades to the core APIs in addition to performance improvements and bug fixes. Keep reading for some of the highligh
- Citrix makes bold virtualization move with XenSource acquisition, muddies waters with Microsoft | Dana Gardner’s BriefingsDirect | ZDNet.com – Citrix Systems Inc. today roared full throttle into the ever-expanding desktop virtualization arena, when it announced its intention to acquire XenSource, Inc. of Palo Alto, Calif. The news comes right on the heels of VMWare?s huge IPO pop.
Tag Archives: optimization
Daily del.icio.us for Apr 13, 2007 through Apr 17, 2007
- The 90th percentile: MyFaces: The emperor has no clothes – My last project is going into production in a couple of weeks, and it has been implemented using JSF. I started with JSF in good faith: it should be stable by now, it is blessed by Sun and included as the de facto web framework in JEE 5.
- James Ward’s Blog » Blog Archive » My Recent Flex & Apollo Adventures – A while back Bruce Eckel and I recorded a screencast of us building a Flex application with Hibernate and XFire on the backend. I finally got around to packaging the code for that demo. You can get it from SourceForge.
- rakaz – Make your pages load faster by combining and compressing javascript and css files – Thanks to a small PHP script and some clever URL rewriting I now have an easy to maintain method to speed up the loading of pages that use many or large css and javascript files.
- Vitamin Features » Serving JavaScript Fast – The next generation of web apps make heavy use of JavaScript and CSS. We?ll show you how to make those apps responsive and quick.
- lightWindow – Another decent lightbox Javascript library (via Ajaxian) – After researching every single modal window, lightbox, slimbox, etc out there nothing fit the bill. Granted some of them were very nice but only fit a specific purpose
- Dynamic languages: More than just a quick fix | InfoWorld | Analysis | 2007-04-16 | By Andrew Binstock – IT’s rise to prominence as a core competence that delivers competitive advantage has been accompanied by a dramatic increase in the number of software development projects it must complete
- Translation From PR-Speak to English of Selected Portions of Rails Developer David Heinemeier Hansson?s Response to Alex Payne?s Interview [dive into mark] – LAUGH OUT LOUD funny take from Mark Pilgrim, John Gruber style. 🙂
- WordPress Performance: Why My Site Is So Much Faster Than Yours by Elliott Back – There?s no good reason for WordPress or your site to be slow, except your own negligence. Cache everything. Monitor performance
- Tim Sneath : Introducing Microsoft Silverlight – Silverlight (previously codenamed "WPF/E") is a lightweight subset of XAML for building rich media experiences on the web.
- Java Community News – BEA Releases JRockit R27.2 with Java 6 Support – BEA’s latest JVM release, JRockit R27.2, is the first implementation of the Java 6 VM. In addition to providing full Java 6 support, the latest JRockit VM includes many-fold performance improvements, especially for applications with short-lived objects.
- Enomalism : XEN Virtualized Server Management Console: Amazon EC2 Migration – The Enomalism Elastic migration module is a migration tool kit for the management and migration of virtual images between your local xen based enomalism environment and the remote Amazon Elastic Compute Cloud Environment.
- Everybody Hates Don Imus – Frank Rich’s brilliant column – Even in that short span, there?s been an astounding display of hypocrisy, sanctimony and self-congratulation from nearly every side of the debate
- Dev2Dev Online: Open Source and BEA – BEA believes in open source. We believe a blended strategy for application development and deployment?combining the best of open source and commercial software?provides important freedom and flexibility not available through all-or-nothing approaches
- Web Worker Daily » Blog Archive Web Worker Emergency Survival Kit « – Over the years, I?ve accumulated a variety of tools that don?t take up much space but that come in handy when an emergency comes along. On the average day, I don?t need any of these – but when I do, I?m happy to have them. Here are my suggestions
Daily del.icio.us for Apr 03, 2007
- From Java EE security to Acegi – The right way to protect your Web applications – This article is an in-depth introduction and comparison of Java EE security and Acegi. They both offer a variety of security services to make application security programming easier. The declarative and annotation-based programming methodologies let devel
- Microsoft Watch – Games & Consumer – What Apple DRM-Free Means to Microsoft – Apple will offer EMI music free of DRM for 30 cents more a track; album prices will remain the same. Apple makes the EMI catalog more attractive than other iTunes music in two ways: No DRM and higher encoding
- BEA cites Java, availability in app server upgrade | InfoWorld | News | 2007-03-30 | By Paul Krill – WebLogic Server builds on Spring internally, said Rod Johnson, founder of Spring and CEO of Interface21. "The architecture that they’ve adopted, building on Spring, enables them to move to a situation where Spring components can be deployed natively to We
- The Aquarium: GlassFish Components in BEA’s WebLogic Server 10.0 – BEA has released WebLogic Server 10.0, as a Technology Preview for their Java EE 5 support. BEA is using the GlassFish implementations for JAX-WS 2.0, and JAXB 2.0, which were part of GlassFish v1 UR1
- The Impact of Emerging Technologies: Media Viewer – Tim Berners-Lee explains how the Semantic Web works and how it will transform how we use and understand data.
- JScrape – Simple Java & Xquery based HTML Scraping API – JScrape is a simple yet powerful java api for scraping (aka screen scraping) data from a web page using XQuery. This API makes it simple to pull data from other sources and maintain them in a simple way
- Dev2Dev Editor’s Blog: WebLogic Server 10! WebLogic Portal 10 and Workshop for WebLogic 10 too! – BEA WebLogic Server 10, BEA WebLogic Portal 10 and BEA Workshop for WebLogic 10 are all available now
- Performance Research, Part 3: When the Cookie Crumbles – Yahoo! User Interface Blog – This article, co-written by Patty Chi, is the third in a series of articles describing experiments conducted to learn more about optimizing web page performance
- Performance Research, Part 2: Browser Cache Usage – Exposed! – Yahoo! User Interface Blog – This is the second in a series of articles describing experiments conducted to learn more about optimizing web page performance.
- Performance Research, Part 1: What the 80/20 Rule Tells Us about Reducing HTTP Requests – Yahoo! User Interface Blog – This is the first in a series of articles describing experiments conducted to learn more about optimizing web page performance.
- Blogbody: IDEA Really is That Good – I consistently find myself trying to explain why IDEA is so good. This is my attempt to explain my favorite "features". I say "features" because many of these aren’t the type of bullet-point features you might see in a direct comparison (ie: "EJB3 Support
Website Performance and Optimization
A couple of months ago, I noticed that I was getting pretty close to using up all of my monthly bandwidth allocation for my server and that was a surprise. I run several blogs that get quite a few hits but I didn't think I was anywhere near going over my 250 GB allotment. So I decided to spend a little time to optimize my server and figure out the best way to utilize what I had and optimize it to get the most performance out of my little box. Jeff Atwood's wonderful blog entry about Reducing Your Website's Bandwidth Usage inspired me to write about my experience and what I ended up doing to squeeze the most out of my server.
I had done some of the obvious things that people typically do to minimize traffic to their site. First and foremost was outsourcing of my RSS feeds to FeedBurner. I've been using FeedBurner for several years now after I learned the hard way how badly programmed a lot of the RSS readers were out there. I had to ban several IP addresses as they were getting my full feed every 2 seconds – Hoping that was some bad configuration on their side but who knows. Maybe it was a RSS DOS attack :). After taking a little time to see what was taking up a lot of the bandwidth, I discovered several things that needed immediate attention. First and foremost was the missing HTTP compression. Looks like an Apache or PHP upgrade I did in the past few months had ended up disabling the Apache module for GZIP compression and so all the traffic was going out in text. HTTP Compression delivers amazing speed enhancements via file size reduction and most if not all browsers support compression and so I enabled compression for all content of type text/html and all CSS and JS files.
Some older browser don't handle JS and CSS compressed files but anything of IE6 seemed to handle JS/CSS compression just fine and my usage tracking (pictured above) indicated that most of my IE users were using IE 6 and above.
Enabling HTTP Compression compressed my blog index page by 78% resulting in a statistical performance improvement of almost 4.4x. While your mileage may vary, the resulting performance improvement got me on the Top20 column at GrabPERF almost every single day.
Another issue I had was the number of images being loaded from my web server. As most of you already know, browsers will typically limit themselves to 2 connections per server and so if a webpage being loaded has 4 CSS files, 2 JS files and 10 images, you are loading a lot of content over those 2 connections. And so I used a simple CNAME trick to create an image.j2eegeek.com to complement http://www.j2eegeek.com and started serving images from image.j2eegeek.com. That did help and I considered doing something similar for CSS and JS files but decided instead to outsource image handling to Amazon's S3.
Amazon's S3 or Simple Storage Service is a highly scalable, reliable, fast, inexpensive data storage infrastructure that is fast and relatively inexpensive. S3 allows you to create a 'bucket', which is essentially a folder that must have a globally unique name and cannot have any sub-buckets or directories and so it's basically emulates a flat directory structure. Everything you put in your bucket and make publically available is accessible via http using the URL http://s3.amazonaws.com/bucketname/itemname.png. Amazon's S3 Web Service also allows you to call it using the HTTP Host header and so the URL above would become http://bucketname.s3.amazonaws.com/itemname.png. You can take this further if you have access to your DNS server. In my case, I created a bucket in S3 called s3.j2eegeek.com. I then created a CNAME in my DNS for s3.j2eegeek.com and pointed it to s3.amazonaws.com. And presto – s3.j2eegeek.com resolves to essentially http://s3.amazonaws.com/s3.j2eegeek.com/. I then used John Spurlock's NS3 Manager to get my content onto S3. NS3 Manager is a simple tool (windows only) to transfer files to/from an Amazon S3 storage account, as well as manage existing data. It is an attempt to provide a useful interface for some of the most basic S3 operations: uploading/downloading, managing ACLs, system metadata (e.g. content-type) and user metadata (custom name-value pairs). In my opinion, NS3 Manager is the best tool out there for getting data in and out of S3 and I have used close to 20 web based, browser plug-in and desktop applications.
In addition, I also decided to try out a couple of PHP Accelerators out there to see if I could squeeze a little more performance out of my web server. Compile caches are a no-brainer and I saw decent performance improvement in my PHP applications. I blogged about this topic in a little more detail and you can read that if you care about PHP performance.
The last thing I did probably had the biggest impact after enabling HTTP compression and that was moving my Tomcat application server off my current Linux box and moving it to Amazon's EC2. Amazon's EC2 or Elastic Compute Cloud is a virtualized cloud of computing available to you for $0.10 per hour of CPU utilization. I've been playing around with EC2 for a while now and just started using it for something real. I have tons of notes that I taken during my experimentation with EC2 where I took the stock Fedora Core 4 images from Amazon and made that server into my Java application server running Tomcat and Glassfish. I also created my own Fedora Core 6, CentOS 4.4 image and deployed them as my server. My current AMI running my Java applications is a Fedora Core 6 image and I am hoping to get RHEL 5.0 deployed in the next few weeks but all of that will be a topic for another blog.
In conclusion, the HTTP Compression offered me the biggest reduction in bandwidth utilization. And it is so easy to setup on Apache, IIS or virtually any Java application server that is it almost criminal not to do so. 🙂 Maybe that's overstating it a bit – but there are some really simple ways to optimize your website and you too can make your site hum and perform like you’ve got a cluster of servers behind your site.
Daily del.icio.us for Mar 10, 2007 through Mar 15, 2007
- video.onflex.org – video.onflex.org is maintained by Mike Chambers and Ted Patrick of Adobe. It is focused on providing videos about developing with Adobe Flex, ActionScript and Apollo.
- How to Use Java at a Startup – Cardsharp on Software – The embarrassment of riches in the Java Open Source movement makes it a slam dunk for startups. The fact that you can find an Open Source framework for every conceivable use means that you can focus on your core business instead of on plumbing
- InfoQ: JP Rangaswami on open source in the enterprise & the future of information – CIO JP Rangaswami explains how open source became a corporate IT strategy at investment bank Dresdner Kleinwort Wasserstein and why CIOs of major enterprises should open source for software development initiatives. JP also explains his vision of four pill
- Ajaxian » Compressed versions of Prototype – John-David Dalton has spent some time compressing Prototype in a couple of ways to keep your download time to a minimum.
- jsjuicer – jsjuicer is a free tool for safely reducing the size of your JavaScript files. Reducing the size and number of the JavaScript files included in a web page will enable it to load faster
Daily del.icio.us for Mar 09, 2007 through Mar 10, 2007
- Ajaxian – Compressed versions of Prototype – John-David Dalton has spent some time compressing Prototype in a couple of ways to keep your download time to a minimum.
- jsjuicer – jsjuicer is a free tool for safely reducing the size of your JavaScript files. Reducing the size and number of the JavaScript files included in a web page will enable it to load faster
- SDN Channel – Spotlight on Open Source – Did you know that Sun contributes more than $200 million per year of intellectual property to the open source movement, in dozens of open source projects? The company?s historical contribution tops $2 billion (Kudos to Sun)
- www.hungtang.com – Java and IDEA: deadly tandem – I have been doing Java development for about 6 years now. It?s amazing to think that I have stuck with it for this long but I strongly believe Intellij IDEA has a lot to do with my seemingly never-ending devotion. Simply put, this product rocks?just l
- FiveRuns – Web 2.0 Systems Management – FiveRuns makes monitoring, analyzing, reporting and predicting the behavior of critical business systems painless.
- A Roundup for “Developers, Developers, Developers…” – So, I decided to make a compilation of products that developers may find useful. There?s a little bit of everything in here – some are still in private beta, but still worth mentioning
Daily del.icio.us for Mar 05, 2007 through Mar 06, 2007
- Coding Horror: Reducing Your Website’s Bandwidth Usage – What can we do to reduce a website’s bandwidth usage?
- Amazon Web Services Developer Connection : Building a Struts-Based Web Application on Amazon S3 – This article provides a tutorial on integrating the Amazon S3 REST API for Java with the Struts web application framework to create a web management user interface to the Amazon Simple Storage Service (Amazon S3).
- mxGraph – JavaScript library for diagrams – mxGraph is a Javascript library that uses built-in browser capabilities to provide an interactive drawing and diagramming solution.
- AJAX Magazine: Why Can Google Not Eat Its Dogfood, While Yahoo and Microsoft Do? – What’s surprising is that Google is not using GWT for its critical online service, which almost all of them are AJAX-based or have AJAX veneer: GMail, GMaps, GReader, GDocs, GSpreadsheet, GAJAX-Search, GFinance, GHomePage, … none of them use GWT! The qu
- Ten Javascript Tools Everyone Should Have – Javascript frameworks have exploded on the scene over the last few years but they’re no replacement for a good toolbox: those little snippets of code you seem to include in every single project. Here’s my list of 10 essential Javascript tools everyone sho
- 0xCAFEBABE – Securing Spring WS Client with XWSS – In this post, I will show you how I used XWSS to add WS-Security support to web services invocations. I used XWSS 2.0 from jwsdp-2.0. I had to add xmlsec.jar from the jwsdp-shared/lib in order for the example to work.
- Tableless forms – Another nice CSS stylesheet for styling forms without tables
- Getting Started with Google Code Hosting, Subversion, and TortoiseSVN without feeling like an Idiot « //engtech – Getting Started with Google Code Hosting, Subversion, and TortoiseSVN without feeling like an Idiot
- Starbucks’ ‘venti’ problem – Los Angeles Times – Time and again in recent years, we’ve seen small, cutting-edge and quirky brands gain critical mass ? only to lose their charm and customer appeal after they engage in breakneck expansion.
- When is Scrum not Scrum? (Agile Advice) – Tobias mentions that one must insist on agile engineering practices when doing Scrum. There are two problems with this.
- Agile Thoughts » Blog Archive » When is Scrum not Scrum? – I teach what I know works and what I see as being appropriate; there are slight differences in each context of course, but there are certain practices I have found to be effective, all of which differ from standard Scrum practices
- coded ruminations – Selling Agile, a Smell? – The use of Agile must be adopted using an iterative incremental approach – a nimble approach – an Agile approach. Agile is not to be sold, it is to be used.
PHP Acceleration – Pick Your Poison
As I deployed more applications and web sites on my server, I started running into resource issues. Since most of the applications I write are in Java, I run Tomcat on my Linux server. But I also run Apache as a front-end host for Tomcat as well as several PHP applications like WordPress, Vanilla and a few other PHP applications that I’ve written. I am not an expert PHP developer by any stretch of the imagination but I tinker with enough PHP that I decided to take a look at PHP Acceleration software.
For the uninitiated, PHP is a scripting language that is interpreted and compiled on the server side. PHP Accelerators offer caching of the PHP scripts in their compiled state along with optimization. There are several PHP optimization products out there and I decided to give eAccelerator, XCache and APC a try on my Linux machine. For the record, the box is running CentOS 4.4 which is essentially a distribution that is repackaged Red Hat Enterprise Linux 4.x.
- eAccelerator – eAccelerator is a free open-source PHP accelerator, optimizer, and dynamic content cache. It increases the performance of PHP scripts by caching them in their compiled state, so that the overhead of compiling is almost completely eliminated. It also optimizes scripts to speed up their execution. eAccelerator typically reduces server load and increases the speed of your PHP code by 1-10 times.
- XCache – XCache is a fast, stable PHP opcode cacher that has been tested and is now running on production servers under high load.
- APC – The Alternative PHP Cache (APC) is a free and open opcode cache for PHP. It was conceived of to provide a free, open, and robust framework for caching and optimizing PHP intermediate code.
I compiled and installed these PHP accelerators and found APC worked the best for me. XCache seemed to work well and actually provided a nice admin application that lets you peek inside the cache to see what’s cached, the hit/miss ratio, etc. eAccelerator also seemed to work well and offered a great performance boost but caused segmentation fault and made the Apache web server unusable. It could have been bad PHP code that was causing the segmentation faults but I didn’t really spend any times getting to the root cause. APC just worked, pretty much like XCache but seemed to offer a little better performance. Now I didn’t really perform any empirical testing here – I simply relied on my website monitor GrabPERF as I ran each PHP extension for a few days. Your mileage may vary based on your server architecture, application, lunar phase, etc but PHP APC seemed to work the best for me.
Daily del.icio.us for Feb 25, 2007 through Feb 26, 2007
- New Articles/Tutorials and Presentation : jMaki Has Moved into High Gear (cld.blog-city.com) – jMaki has been making great progress. It is generating alot of excitement. What is it ? jMaki is about enabling Java developers to use JavaScript in their Java based applications as either a JSP tag library or a JSF component.
- Speed Up Your Javascript Load Time | BetterExplained – Javascript is becoming increasingly popular on websites, from loading dynamic data via AJAX to adding special effects to your page… with a price
- If you like to build easy to install JPA-applications – start with TopLink essentials – Java Persistence API (JPA) allows persisting objects in Java SE and EE environments. But JPA is only the API – the SPI (service provider) ist still needed. JPA is already supported by openJPA, Hibernate and TopLink essentials (a part of the Java EE RI).
- LINUX ON DESKTOP: 13 Things to do immediately after installing Ubuntu – In this article i describe some of the things to do immediately after installing ubuntu on your machine
- Expose Your POJO-Based Domain Apps as Web Services – This article explains how to expose existing POJO-driven J2EE applications as web services using Axis2