2. @doanduyhai
Who Am I ?
Duy Hai DOAN
Cassandra technical advocate
• talks, meetups, confs
• open-source devs (Achilles, …)
• OSS Cassandra point of contact
☞ duy_hai.doan@datastax.com
☞ @doanduyhai
2
3. @doanduyhai
Datastax
• Founded in April 2010
• We contribute a lot to Apache Cassandra™
• 400+ customers (25 of the Fortune 100), 400+ employees
• Headquarter in San Francisco Bay area
• EU headquarter in London, offices in France and Germany
• Datastax Enterprise = OSS Cassandra + extra features
3
8. @doanduyhai
What does Zeppelin provide ?
Front-end & display system for free
Generic back-end with REST APIs & WebSocket
Pluggable interpreters system
Task scheduler (à la CRON)
8
14. @doanduyhai
Interpreter processing lifecycle
① Receive input commands/data
• as raw text
• from form data
② Process the input commands/data by the external back-end
③ Format the response using Zeppelin display system
④ Send response back to the Zeppelin engine
14
18. Writing An Interpreter
How To
Simple interpreter example (AsciiDoc)
Complex interpreter example (Cassandra)
19. @doanduyhai
Steps to write your own interpreter
• Create a class that extends Interpreter base class
• Register it in a static block
• Optionnally define default config params
19
static {
Interpreter.register("MyInterpreterName", MyClassName.class.getName());
}
static {
Interpreter.register("MyInterpreterName", MyClassName.class.getName(),
new InterpreterPropertyBuilder()
.add("property1", "default value", "Description of property1").build());
}
20. @doanduyhai
To register your interpreter as default
• Edit the enum ZeppelinConfiguration.ConfVars
• Add your interpreter FQCN in the property ZEPPELIN_INTERPRETERS
20
21. @doanduyhai
To register your interpreter in config files
• Create conf/zeppelin-site.xml from conf/zeppelin-site.xml.template
• Add your interpreter FQCN in the property zeppelin.interpreters
21
<property>
<name>zeppelin.interpreters</name>
<value>org.apache.zeppelin.spark.SparkInterpreter,org.apache.zeppelin.spark.PySparkInterpreter,
org.apache.zeppelin.spark.SparkSqlInterpreter,org.apache.zeppelin.spark.DepInterpreter,
org.apache.zeppelin.markdown.Markdown,org.apache.zeppelin.shell.ShellInterpreter,
org.apache.zeppelin.hive.HiveInterpreter,com.me.MyNewInterpreter
</value>
</property>