Measuring Web Mapping Application Performance using YSlow – part 2

Sorry for the long delay in writing this post. Lots of you have emailed me asking for the concluding part of the performance analysis and here it is. This is a continuation from the last post so its highly recommended you read the earlier post first (Click here for part1)

Here is the listing of YSlow 13 performance rules along with the ratings given to the default web mapping application template.

1. Make Fewer HTTP requests (F)
2. Use a CDN (F)
3. Add an Expires header (F)
4. Gzip components (F)
5. Put CSS at the top (B)
6. Move scripts to the bottom (C)
7. Avoid CSS expressions (A)
8. Make JS and CSS external (-)
9. Reduce DNS lookups (A)
10. Minify JS (A)
11. Avoid redirects (A)
12. Remove duplicate scripts (A)
13. Configure ETags (A)

Now lets analyze a few rules and its ratings to see where we as web developers or front end engineers can contribute to improve the performance of the web mapping application. Read the rest of this entry »

Configure Routing Task

In one of my recent teaching trips to St. Louis, MO the discussion came up as to how to use the network analyst extension capabilities in the web mapping application. While looking through the Web ADF Java Doc surprisingly I did find the Routing task and an associated taskinfo class. Java Web ADF has a ready to use Routing Task but is not configurable through the manager.

Out of curiosity and with help of fellow employee (Thanks Lloyd) we figured out that if you have ArcGIS Server Service with Network Analysis capability enabled and a Geocode service then you can use these services with the Routing task in your web mapping application. The only thing missing is documentation on how to configure and use the task. Here are the steps to add this task to your application :

Read the rest of this entry »

Measuring Web Mapping Application Performance using YSlow – part 1

I am big fan of Yahoo Developer Network and one of the sections in the site is the “Exceptional Performance” headed until recently by Steve Souders – performance Guru previously at Yahoo and now at Google. Recently Yahoo has come out with a new firefox add-on called YSlow. YSlow is a tool that follows the 13 Rules for High Performance Web Sites as listed on the Yahoo Exception Performance site and analyzes those 13 aspects on your site, giving you a grade (A-F) for each of the rules, and an overall grade for the site. The tool is free to download and installed as an add-on into Firefox firebug plugin.

The 13 benchmarks are listed here

  1. Make fewer HTTP requests
  2. Use a CDN
  3. Add an Expires header
  4. Gzip components
  5. Put CSS at the top
  6. Move scripts to the bottom
  7. Avoid CSS expressions
  8. Make JS and CSS external
  9. Reduce DNS lookups
  10. Minify JS
  11. Avoid redirects
  12. Remove duplicate scripts
  13. Configure ETags

If you are new to YSlow or the 13 rules for high performance, I strongly recommend reading the links above first before following the article. My mission after reading the articles and installing the plugin was to figure out what does these performance rules mean from a web mapping application perspective.

Read the rest of this entry »

Creating a deployable WAR file from Eclipse Project

Recently I was posed with a challenge of coming up with a solution to a seemingly simple problem “I want to use Eclipse to create by web mapping project and then deploy the solution directly into my Tomcat instance”

Sounds simple right, I started exploring ways to coming up with a solution. Eclipse allows us to run the application and then export the application to a standard WAR file. But then someone has to manually do the following steps :

  • Export the project to a WAR file using Eclipse Interface
  • Copy the WAR file from the location created to the Tomcat webapps folder

Here is a better alternative and a solution to the question :

Create an ANT script that will look at the Eclipse Project structure and build the WAR file and copy over the WAR file to the destination (Tomcat WebApps folder)

Read the rest of this entry »

Adding labels to GeoRSSViewer Sample

I was recently working on the sample posted on EDN website showing how to plot the Recent Earthquake GeoRSS feed from USGS. Before I go any further here is the link to the sample : Custom Task – GeoRSS

I wanted to modify the sample to not only plot the earthquake points on the map using Graphics layer but also show me the information associated with the point such as magnitude and location. Here are the steps involved :

  • Add a new command to the existing custom task (GeorssTask.java) to plot both points and show labels
  • Add a new TaskDescriptor entry for the command in the TaskInfo class (GeorssTaskInfo.java)

This new method will take the current extent of the map and plot all the Georss points within the extent using both a symbol and a label.

Lets look at the code :

Read the rest of this entry »