Web Summary of the Day

On dynamic versus static typing: “fully expressive language is one that supports the delicate interplay between static and dynamic techniques. Languages that force only one perspective on you, namely the dynamic languages, hobble you; languages that admit both modes of reasoning enable you and liberate you from the tyranny of a single type. Let a thousand flowers bloom!” (https://existentialtype.wordpress.com/2011/03/19/dynamic-languages-are-static-languages/)

Agile was never meant to be commercialized. Agile is a set of values, not a certification. One blogger boils it down to: “Being resolute to work with others to always steer to the next possible “better” seems to work nicely.” (http://zuill.us/WoodyZuill/2014/03/31/to-me-this-is-agile/)

Learn to negotiate well behind the keyboard.

For fun, here is an API for insulting people: http://pleaseinsult.me
If you don’t have a Mac, but need one, you can now run one on the cloud: http://www.macincloud.com


Not So Liberated Yelp API

Recently, I wanted to develop a mobile app that displayed a walking city tour of your bookmarked places on Yelp so that if you are in a new city and want waypoints generated for the nearest favorite locations, you can quickly get them on the fly. This was harder than I thought because of the limitations of the Yelp API.

I wanted to produce a final solution all Node JS and Angular JS. This meant learning about Node JS, Angular JS and how to wire the two together. The implementation would utilize Google Maps and Geocoding services. I ran into several limitations with their free service, mostly OVER_QUERY_LIMIT errors which would require me to rewrite my code to handle these errors, wait a few seconds and then retry.

The NodeJS server returns some JSON with bookmarked locations which were queried directly from a Yelp URL using request and then parsed with cherrio. The reason I couldn’t use their API is that they did not include retrieving bookmarks!

[{title: "Pyramid Alehouse",
streetAddress: "1201 1st Ave S Seattle, WA 98134"
},{title: "Elysian Fields",
streetAddress: "542 1st Ave S Seattle, WA 98104"
},{title: "The Brooklyn Seafood, Steak & Oyster House",
streetAddress: "1212 2nd Ave Seattle, WA 98101"}]

The results were a list of waypoints starting from the user’s location.


Unfortunately, after deploying the site to OpenShift, I encountered rejects from Yelp. Even after trying several popular proxies, Yelp would not let me call their site.


Therefore, I sent an plea to Yelp, suggesting they open their API a bit more:

“I am a avid user of Yelp and an active reviewer. I am also a developer and would like to write a mobile app that integrated with Yelp. However, I’ve found the Yelp API to be limiting. For example, I cannot query a list of my bookmarks for a particular city. I plan on displaying these bookmarks on a Google map with waypoints indicating the ideal path to take from my starting point. This way, I can create a walking tour of my favorite Yelp bookmarks within walking distance from me. This appears to be an important feature which Yelp currently lacks. Upon discovery, I’ve found that I cannot even query my open public bookmarks from my web server as I get a 403: Forbidden error. Is there a legal reason for rejecting my server request? Please add the ability to query bookmarks from the API or provide a way I can get a list of bookmarks from a url such as “http://www.yelp.com/user_details_bookmarks?cc=US&city=Seattle&state=WA&userid=XXX&neighborhood=Downtown” from my web server without getting blocked.”

If you’re curious, you can find the implemtation here: https://github.com/szahn/YelpItinerary. It’s not finished yet and there is still a ton of refactoring to do.

Enterprise Applications Need to Leverage Both the Power of WPF and WCF

One of the complaints I get from IT administrators is that when they run a background task such as a Windows Service, they have no user interface to show them what’s happening in real time. I have to admit that most of the utilities and applications I’ve seen that administrators use don’t do a good job of providing an easy to use interface to view service activity. You either get a clunky windows application where all the processing happens to be within that executable itself or a Windows service that doesn’t tell you what it’s doing. I’m not sure whose to blame for this kind of design.

My conviction is that applications should be structured such that all the heavy-lifting (serious processes) are made in a separate windows service. All other aspects of an application such as the user interface should be packaged into a separate executable. As the service is running, it can use WCF (windows communication foundation) or .NET remoting to update an activity log on the screen without causing delay in the interaction of the UI itself.

The benefits of separting process from user interface is huge. If the window closes, the process will still finish because another service is doing all the work. Therefore, I highly urge developers and architects to begin to make business user interfaces that make the IT admin feel good and separate out the business layer from the presentation layout by taking full advantage of .NET messaging platforms.

WPF (Windows Presentation Foundation), is a great framework for building interfaces that make you feel good, which is one of my core values when building user experiences. Keep everyone happy with a great presentation platform and use WCF or other messaging frameworks to ensure long running tasks are completed successfully.

Spreadsheet Logic in the Cloud

Is your company in the cloud? Too afraid to implement Windows Azure or Amazon Cloud Services? Well, If you Google Docs offers a basic cloud-based document management system. Using Google Spreadsheet, a business can automate certain tasks like document queue, reporting and approval. For example, using Google’s Data API, a .NET application can be written to process files and move them from one location to another on the network, starting with a simple Google form submission. One can use a spreadsheet where each row represents a datagroup and it’s status. The datagroup is managed from a Windows service that updates it’s status in the Google doc everytime a process occurs.

No need to have dozens of spreadsheet files scattered across the network. It’s very easy to integrate the Google Data API into a .NET application. There shouldn’t be a need for Excel files and VB macros when you can manage all of that Google’s Cloud.