Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
naffis committed Nov 6, 2012
1 parent c4b4ce7 commit 41938f7
Show file tree
Hide file tree
Showing 380 changed files with 32,344 additions and 1 deletion.
7 changes: 7 additions & 0 deletions .gitignore
@@ -0,0 +1,7 @@
.classpath
.project
*.jar
target
.lein-deps-sum
classes/
lib/
22 changes: 21 additions & 1 deletion README.md
@@ -1,2 +1,22 @@
storm-election-example
======================
======================

This is a simple demo app based on the storm-starter project (https://github.com/nathanmarz/storm-starter.) that monitors twitter for certain keywords related to the GOP primary, displays the latest tweets, generats a tag cloud and graphs the number of mentions each candidate has received.

A video of the app running can be found here: http://www.youtube.com/watch?v=pfwyP0vUqew

How to run this example:

Using Leiningen (https://github.com/technomancy/leiningen)

lein deps
lein compile
java -cp `lein classpath` storm.starter.TwitterTopology

redis-server

node app.js




193 changes: 193 additions & 0 deletions maven_repository/goose/goose/2.1.10/goose-2.1.10.pom
@@ -0,0 +1,193 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>com.gravity</groupId>
<artifactId>goose</artifactId>
<version>2.1.10</version>
<packaging>jar</packaging>
<name>goose</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<repositories>
<repository>
<id>akka.repository</id>
<name>Akka Maven Repository</name>
<url>http://akka.io/repository</url>
</repository>
</repositories>

<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.6.1</version>
<type>jar</type>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.6.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.jsoup</groupId>
<artifactId>jsoup</artifactId>
<version>1.5.2</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.0.1</version>
</dependency>

<dependency>
<groupId>org.scala-lang</groupId>
<artifactId>scala-compiler</artifactId>
<version>2.9.0-1</version>
<scope>compile</scope>
</dependency>

<dependency>
<groupId>org.scala-lang</groupId>
<artifactId>scala-library</artifactId>
<version>2.9.0-1</version>
</dependency>

<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.1.2</version>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<version>2.6</version>
</dependency>
<dependency>
<groupId>se.scalablesolutions.akka</groupId>
<artifactId>akka-actor</artifactId>
<version>1.1.3</version>
<exclusions>
<exclusion>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-core</artifactId>
</exclusion>
<exclusion>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
</exclusion>

</exclusions>
</dependency>
<dependency>
<groupId>se.scalablesolutions.akka</groupId>
<artifactId>akka-typed-actor</artifactId>
<version>1.1.3</version>
<exclusions>
<exclusion>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-core</artifactId>
</exclusion>
<exclusion>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
</exclusion>

</exclusions>
</dependency>
</dependencies>

<!--
Hey... since we're open source, let's compile the source and javadocs into jars as well
-->
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.6</version>
<configuration>
<useFile>false</useFile>
<disableXmlReport>true</disableXmlReport>
<includes>
<include>**/*Test.*</include>
</includes>
<excludes>
<exclude>**/*IT.*</exclude>
</excludes>
</configuration>
</plugin>
<plugin>
<groupId>org.scala-tools</groupId>
<artifactId>maven-scala-plugin</artifactId>
<version>2.14.3</version>
<configuration>
<charset>UTF-8</charset>
<jvmArgs>
<jvmArg>-Xmx1024m</jvmArg>
</jvmArgs>
</configuration>
<executions>
<execution>
<id>compile</id>
<goals>
<goal>compile</goal>
</goals>
<phase>compile</phase>
</execution>
<execution>
<id>test-compile</id>
<goals>
<goal>testCompile</goal>
</goals>
<phase>test-compile</phase>
</execution>
<execution>
<phase>process-resources</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>

</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.1.2</version>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.8</version>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>

</project>
12 changes: 12 additions & 0 deletions maven_repository/goose/goose/maven-metadata-local.xml
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<metadata>
<groupId>goose</groupId>
<artifactId>goose</artifactId>
<versioning>
<release>2.1.10</release>
<versions>
<version>2.1.10</version>
</versions>
<lastUpdated>20120113155822</lastUpdated>
</versioning>
</metadata>
Binary file added node/.DS_Store
Binary file not shown.
27 changes: 27 additions & 0 deletions node/app.js
@@ -0,0 +1,27 @@
var app = require('express').createServer()
, io = require('socket.io').listen(app)
, redis = require('redis');
var sub = redis.createClient();

sub.subscribe("tags-romney");
sub.subscribe("tags-santorum");
sub.subscribe("tags-gingrich");
sub.subscribe("tags-paul");

sub.subscribe("tweets-romney");
sub.subscribe("tweets-santorum");
sub.subscribe("tweets-gingrich");
sub.subscribe("tweets-paul");

app.listen(8080);

app.get('/', function (req, res) {
res.sendfile(__dirname + '/index.html');
});

io.sockets.on('connection', function (socket) {
sub.on("message", function(pattern, key){
socket.emit(pattern, key);
});

});

0 comments on commit 41938f7

Please sign in to comment.