forked from databricks/spark-training
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTutorial.java
More file actions
28 lines (22 loc) · 776 Bytes
/
Copy pathTutorial.java
File metadata and controls
28 lines (22 loc) · 776 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
import org.apache.spark.*;
import org.apache.spark.api.java.*;
import org.apache.spark.api.java.function.*;
import org.apache.spark.streaming.*;
import org.apache.spark.streaming.twitter.*;
import org.apache.spark.streaming.api.java.*;
import twitter4j.*;
import java.util.Arrays;
import scala.Tuple2;
public class Tutorial {
public static void main(String[] args) throws Exception {
// Checkpoint directory
String checkpointDir = TutorialHelper.getCheckpointDirectory();
// Configuring Twitter credentials
String apiKey = "";
String apiSecret = "";
String accessToken = "";
String accessTokenSecret = "";
TutorialHelper.configureTwitterCredentials(apiKey, apiSecret, accessToken, accessTokenSecret);
// Your code goes here
}
}