Patrick Mueller

March 10, 2015

Node.js debugging starts with better logging!

It's very often the case that when a Bluemix app doesn't work the way you expect it to, you don't have any idea WHY it doesn't work the way you expect it to. How can you diagnose this? With logging and lots of it. This article will explain how to access your logs in Bluemix, suggest general logging techniques, and then go in-depth on logging frameworks/libraries specific to Node.js.

Continue reading

January 20, 2015

Hints for Node.js developers using io.js on Bluemix

If you're interested in Node.js, but haven't been following all the latest excitement around io.js and ECMAScript 6 (ES6), here's the executive summary: It's a fork of node.js which is shipping with a newer version of the V8 JavaScript engine and features available in ECMAScript 6, without having to have a special pre-release version of node.js installed, or using special node command-line flags. This blog entry lays out the steps necessary to try io.js in your Bluemix Node.js application.

Continue reading

October 14, 2014

Keeping secrets – how your cloud application should access credentials and other private data

If you're building a web app, you probably have secrets you have to deal with like database credentials, session keys, etc. So, where do you keep these secrets? Developers using Cloud Foundry based systems has a truly secure option: Cloud Foundry's user-provided services. This blog post will go over the advantages and disadvantages of the traditional and modern approaches.

Continue reading

October 3, 2014

cfenv 1.0.0 with new getServiceCreds() method

The cfenv package is intended to be the Swiss army knife of handling your Cloud Foundry runtime environment variables for node.js applications. Here's a breakdown of the latest updates to the package.

Continue reading

August 29, 2014

How to deploy static websites with Bluemix

In a recent blog post Dr Nic Williams - aka "Dr Nic" - introduced a new buildpack that can be used to create a server which contains no logic, just serves up resources like HTML / JS / CSS / image / etc resources – aka a “static website”. Dr Nic shows how to deploy it to Pivotal Web Services, and while this should work on Bluemix, you never know until you try. So I tried. And of course it worked. To test the buildpack, I happened to have a perfect example that I have been playing with ....

Continue reading

July 17, 2014

Using the node.js cfenv package to make your life easier

I've just put together a little Bluemix application for node.js - bluemix-service-switcher - which shows how to access service information using the cfenv package. This sample, and the cfenv package, should also work fine on any Cloud Foundry-based PaaS. cfenv provides a number of functions to deal with the VCAP_SERVICES and VCAP_APPLICATION environment variables. You will never have to JSON.parse() them again!

Continue reading

July 15, 2014

zip-weather – get weather forecasts via text or phone calls with Twilio

Twilio provides an awesome SMS and telephony service that you can use in web applications. . I’d been wanting to build an application with Twilio for a while now, and finally did it the other day. It’s called zip-weather. The app will respond to text messages and voice calls, prompt you for a location, then provide a weather forecast for that location.

Continue reading

July 10, 2014

dealing with private node.js packages

While is a great place to host node packages, ANYONE can access them. What happens if you have multiple application which all use a package you wrote, but you’d like to not have to publish that package publicly? Private packages like this aren’t really a first-class notion in the node world – yet. But there are various strategies you can use to provide this capability until they are.

Continue reading

June 6, 2014

Debugging node apps running on Cloud Foundry

I've just posted an entry to my personal blog titled "debugging node apps running on Cloud Foundry", describing a technique you can use to debug your node apps while they're running on Cloud Foundry.

Continue reading