Archive for the 'Meta' Category

How to add support for posting multipart forms to the Play Scala WS library

For Process Street‘s Yammer integration, I needed to post file attachments to their API using the Play Scala WS library.

However, it turns out that WS does not yet support uploading files using multipart/form-data and POST. There are several workarounds on the ‘net, but they all involve getting the underlying Ning Java client and doing thing manually.

Why not harness the power of Play and Scala and write our own Writeable to do that job? Heck, we already have a MultipartFormData object for handling multipart form requests, why not use that?

Read more »

Finding out the size of localStorage

In the next update of Process Street we are adding more caching to our front end JavaScript client (named Front Street after the street in Toronto) in an effort to make the experience of using our app as fast as possible.

Front Street uses web storage (specifically localStorage) to store persistent user data. To make the cache as effective as possible, it should be able to grow to use as much space as it can. However, we also store other information in localStorage, like user session information (the user’s login token and list of teams, for example). That means if the cache grew to use all the localStorage space, the app couldn’t function properly. Thus, we needed a way to detect the size of localStorage so we could partition localStorage between cache and session information.

Read more »


Welcome to my blog.  It’s still under construction so, uh, look out for falling rocks!  Ouch, one just hit me.