Configuring a Presto Notebook¶
Creating a Notebook describes how to create a Presto notebook. After creating a Presto notebook, start the cluster and wait until it is active. For more information, see Using a Presto Notebook (AWS and Azure).
Navigate to the Interpreters tab in the Presto notebook after the cluster is active.
By default, the Presto notebook comes with a default Presto interpreter denoted by presto (%presto). If you want to create a new Presto interpreter, click Create in the Interpreters tab and select presto from the Interpreter Group’s drop-down list. Here is an illustration of choosing the presto Interpreter group.
Configuring Presto Interpreters¶
After the cluster associated with the Presto notebook is active, navigate to the Interpreters tab and add the interpreter properties:
You cannot modify the values of
presto.url from the notebooks UI. The values
displayed against the interpreter properties are the default values. The JDBC interpreter uses the default value
presto.user. The native interpreter uses the current user executing Presto queries as the value of
zeppelin.presto.maxConcurrency. It is the number of paragraphs which can run simultaneously and its default value is 10. The following is an illustrated example of adding this interpreter property.
zeppelin.presto.maxResultinterpreter property. It is the maximum number of rows in the result and its default value is 1000. Here is an illustrated example of adding this interpreter property.
zeppelin.presto.stacktraceas the interpreter property and add
trueas its value. When enabled, the error message also displays stack trace errors that are helpful in debugging issues. Setting this property is recommended to see the stack trace.
After adding interpreter properties, click Save. The illustration below shows the configured interpreter properties.
Setting Session Properties¶
You can set Presto session properties in a Presto notebook paragraph. When you run that session property, it gets
applicable to all paragraphs of that notebook. For example, if you run
set session auto_retry=True; in a paragraph,
the property gets applied to other paragraphs in the notebook’s current session (that is as long as the cluster or
interpreter is not restarted).