Posts Tagged ‘Groovy’

Observing & Querying Tweets (Part 3)

Wednesday, January 13th, 2010 by admin

In my previous posts I’ve discussed how to fetch data from Twitter and massage it into the form that is needed when observing data in Sierra. I also talked about how to “POST” that data to Sierra so that it’s available to query. In this post I’m going to discuss the process of actually querying that data once it’s in Sierra.

Before you read on you may want to browse over the Sierra documentation. These docs list all of the REST calls that are available on Sierra. In my example below I’ll be using the “connections” call.

I should also note that I’ve made some additions to the source code that I’ve used across all of these posts. That code is available along with the rest of the Sierra sample code. In particular I’ve made the code aware of command-line options that specify whether you are “observing” (-o) or “querying” (-q). You can also define all of the needed usernames and passwords via the command-line as well.

(more…)

Tags: , , , , ,
Posted in SaffronSierra | 1 Comment »

Observing & Querying Tweets (Part 2)

Monday, December 28th, 2009 by admin

In my last post I walked through grabbing tweets from Twitter using their API. We then took those tweets and built the necessary XML “resource” for pushing that data into Saffron Sierra. In this post I’m going to cover the process of actually getting the data into (observing) Sierra.

To start, I should probably cover a minor modification I made to the code from the last post as I worked through this post. Last time, I created one XML resource for Sierra that contained all of the tweets from my timeline. After some testing, and thinking, I decided to put each tweet into it’s own separate XML resource. I think this is cleaner, and it’s the “supported” path for Sierra anyway.

(more…)

Tags: , , , ,
Posted in SaffronSierra | 2 Comments »

Observing & Querying Tweets (Part 1)

Monday, November 9th, 2009 by admin

As we look to build compelling examples using Saffron Sierra we’ve often talked about using Twitter as a datasource.  If we could get Twitter data/tweets into Sierra then we could builds lots on interesting analytical capability using Sierra’s APIs.  To enable our exploration, and others, I’ve decided to start a little series (probably 3 parts) of blog post about observing and querying Twitter data in Sierra.

In this first part I’m going to cover the process of grabbing a Twitter feed and building the necessary resource XML for Sierra observations.  For now, you can think of a “resource” in Sierra speak as our method of “inserting” data into the system.  For my example I’m going to be using Groovy .  This code should be easily replicated in your language of choice.  I choose Groovy because I’m familiar with it and it provides a few tools that make this kind of stuff really easy.

(more…)

Tags: , , , ,
Posted in SaffronSierra | 5 Comments »

Using Grails for SaaS Deployment

Friday, September 4th, 2009 by admin

First, a little history…

About 6 months ago we began using Grails for our new and ever growing set of REST apis.  Overall our experience has been great.  Grails has really allowed us to accelerate development and focus on the things that are important to us.  Naturally, when we started talking about Sierra and knew that we’d need to build a user dashboard, admin console, etc… we turned to Grails.

Grails is implemented using Groovy, which is a scripting language that runs in the Java JVM.  Seeing as the rest of the Saffron stack uses Java this was another strong selling point for us, but it also means that in order to stand up Sierra we’d have to jump through all of the same hoops that come along with running a Java stack.
(more…)

Tags: , , , , , , ,
Posted in SaffronSierra | 1 Comment »