View ksql_extra_twitter_filter.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE STREAM twitter_reinvent_kafka_ksql AS | |
SELECT | |
TIMESTAMPTOSTRING(CreatedAt, 'yyyy-MM-dd HH:mm:ss.SSS') AS CreatedAt, | |
EXTRACTJSONFIELD(user,'$.Name') AS user_Name, | |
EXTRACTJSONFIELD(user,'$.ScreenName') AS user_ScreenName, | |
EXTRACTJSONFIELD(user,'$.Location') AS user_Location, | |
EXTRACTJSONFIELD(user,'$.Description') AS user_Description, | |
Text, | |
hashtagentities, | |
lang |
View ksql_pull_tweet_medatadata_apart.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE STREAM twitter_summit AS | |
SELECT | |
TIMESTAMPTOSTRING(CreatedAt, 'yyyy-MM-dd HH:mm:ss.SSS') AS CreatedAt, | |
EXTRACTJSONFIELD(user,'$.Name') AS user_Name, | |
EXTRACTJSONFIELD(user,'$.ScreenName') AS user_ScreenName, | |
EXTRACTJSONFIELD(user,'$.Location') AS user_Location, | |
EXTRACTJSONFIELD(user,'$.Description') AS user_Description, | |
Text, | |
hashtagentities, | |
lang |
View ksql_reinvent_create_stream.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE STREAM twitter_raw | |
(CreatedAt bigint, | |
Id bigint, | |
Text VARCHAR, | |
SOURCE VARCHAR, | |
Truncated VARCHAR, | |
InReplyToStatusId VARCHAR, | |
InReplyToUserId VARCHAR, | |
InReplyToScreenName VARCHAR, | |
GeoLocation VARCHAR, |
View connect_twitter.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "twitter_source_json_01", | |
"config": { | |
"connector.class": "com.github.jcustenborder.kafka.connect.twitter.TwitterSourceConnector", | |
"twitter.oauth.accessToken": "", | |
"twitter.oauth.consumerSecret": "", | |
"twitter.oauth.consumerKey": "", | |
"twitter.oauth.accessTokenSecret": "", | |
"kafka.delete.topic": "twitter_deletes_json_01", | |
"value.converter": "org.apache.kafka.connect.json.JsonConverter", |
View Cassandra.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.datastax.driver.core.*; | |
import java.util.UUID; | |
import java.util.Date; | |
public class Cassandra { | |
Cluster cluster; | |
Session session; | |
PreparedStatement smt; | |
public void setup() { |
View autohue.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
# | |
# See https://github.com/soffes/hue for deets on the API. This script requires | |
# the Gem be installed, which is documented at the same URL. | |
# | |
require 'hue' | |
View cc-by-3.0.md
License
The prose, course text, slide layouts, class outlines, diagrams, HTML, CSS, and Markdown code in the set of educational materials located in this repository are licensed as CC BY 3.0. The Octocat, GitHub logo and other already-copyrighted and already-reserved trademarks and images are not covered by this license.
Attribution 3.0 Unported (CC BY 3.0)
This is a human-readable summary of the Legal Code (the full license).
You are free:
View generaterandomchanges
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#Ensure we have the quantity specified on the CLI | |
if [ -z "$3" ]; then ARG_ERR=ERR; fi | |
if [ -z "$2" ]; then ARG_ERR=ERR; fi | |
if [ -z "$1" ]; then ARG_ERR=ERR; fi | |
if [ -n "$ARG_ERR" ]; | |
then | |
echo "Usage: <filecount> <filenamebase> <filenameextension>" | |
exit |
View syntax-example.md
This should be rended as Clojure code:
(defn hello-world [] (println "hello, world"))
Great success!
NewerOlder