Monday, February 27, 2012

Testing RESTful Web Services


Recently, a lot of companies have been moving towards RESTful web services. REST has a lot of benefits compared to SOAP, XML RPC in terms of performance and ease of development. You can read more about these here:
In development while testing RESTful Web Services, I have found the following tools helpful:
  • curl - Comes in the Cygwin distribution for windows. You can find linux installables for your flavor of linux here. Sample uses of curl to make REST calls:
    • curl -v http://flickr.com/rogermenezes/photos/61 -H 'Content-Type:application/json' -H 'X-FlickrAPI-Version:1.0' -X DELETE
    • curl -v http://flickr.com/rogermenezes/albums -H 'Content-Type:application/json' -H 'X- FlickrAPI -Version:1.0' -X POST -d '{"name": "hawaii 2011", "tags": "vacation, hawaii, ", "creation_date": "2012-02-22T13:42Z"}'
  • Chrome Plugin - Advance REST Client
    • You can install this plugin through the Chrome Web Store. You can save past requests and the plugin also maintains a history of previous calls you had made.
  • Fiddler2 [I'll add another introductory post in the future for Fiddler.]
    • Fiddler2 snoops your network traffic. As soon as you start Fiddler, it creates a proxy through which all of your traffic gets routed. It provides a great interface for digging thought the network traffic. It also provides a way to "reissue and edit" past requests. Here, you can edit your past REST requests and execute them repeatedly.
Enhanced by Zemanta

Wednesday, February 15, 2012

Synergy - Controlling multiple computers with a single mouse and keyboard

Every company that I have worked for in recent years, RIM, AMZN, MSFT, alloted two machines to devs - a laptop and a desktop. People had different options on using a single mouse and keyboard to control both machines at all places. At MSFT, we would remote desktop to the desktop machine and control everything via the laptop peripherals. Folks at AMZN used Synergy as the configuration over there used to be a linux desktop and windows laptop.

Synergy lets you share your mouse and laptop between multiple computers (cross platform - works on Windows, Mac OS X and Linux). The setup instructions are here. The windows config UI is pretty cool. Choosing the desktop as the server has worked well for me in the past. Also, Synergy has evolved quite a lot in the last few years - a lot of the basic issues are gone. Also, the clipboard works flawlessly across the computers.

Matt Cutts also has good instructions to configure Synergy. Looks like Google devs use it too :-)

More people writing about configuring Synergy:
  • http://lifehacker.com/254648/how-to-control-multiple-computers-with-a-single-keyboard-and-mouse
  • http://www.labnol.org/software/two-computers-one-keyboard-mouse/20134/