Skip to content

[ZEPPELIN-3994] Notebook serving#3356

Closed
Leemoonsoo wants to merge 21 commits intoapache:masterfrom
Leemoonsoo:note_serving
Closed

[ZEPPELIN-3994] Notebook serving#3356
Leemoonsoo wants to merge 21 commits intoapache:masterfrom
Leemoonsoo:note_serving

Conversation

@Leemoonsoo
Copy link
Copy Markdown
Member

@Leemoonsoo Leemoonsoo commented Apr 25, 2019

What is this PR for?

This PR implements notebook serving explained here.

While this PR is already quite large, front-end implementation will have separate PR.
This PR is work in progress.

How to run

  1. Prepare kubernetes cluster
  2. Prepare persistentVolumeClaim with name 'task-context-volume-claim' in your kubernetes cluster
  3. Build Zeppelin docker image (follow instructions here
  4. Deploy api router by running kubectl apply -f k8s/serving-api-router/serving-api-router.yaml
  5. Start Zeppelin on Kubernetes by running kubectl apply -f k8s/zeppelin-server.yaml
  6. Port forward to the api router (e.g. kubectl port-forward <zeppelin-serving-api-router pod name> 8080:80) and browse localhost:8080

*Note: This branch does not include front-end implementation. To try with front-end, checkout this branch.

Summary of changes

To be updated

What type of PR is it?

Feature

Todos

What is the Jira issue?

https://issues.apache.org/jira/browse/ZEPPELIN-3994

How should this be tested?

Questions:

  • Does the licenses files need update? yes
  • Is there breaking changes for older versions? no
  • Does this needs documentation? yes

asfgit pushed a commit that referenced this pull request Feb 28, 2020
### What is this PR for?
This PR adds a command-line option to run a single note.
The code is pickled from #3356.

Usage is

```
bin/zeppelin.sh --run <noteId>
```

The command will launch a Zeppelin server and run a given note, and terminate on after all paragraph's successful run (with exit 0) or terminate on any paragraph error (with exit 1).

### What type of PR is it?
Feature

### What is the Jira issue?
https://issues.apache.org/jira/browse/ZEPPELIN-4619

### Questions:
* Does the licenses files need update? no
* Is there breaking changes for older versions? no
* Does this needs documentation? no

Author: Lee moon soo <[email protected]>

This patch had conflicts when merged, resolved by
Committer: Lee moon soo <[email protected]>

Closes #3654 from Leemoonsoo/ZEPPELIN-4619 and squashes the following commits:

6a83163 [Lee moon soo] remove useless test
a7531a4 [Lee moon soo] address comment
7743b43 [Lee moon soo] add log
99974f8 [Lee moon soo] overload loading runAllParagraphs()
101d155 [Lee moon soo] add --run option
@amit-shahi
Copy link
Copy Markdown

Which version of Zeppelin do I run on Kubernetes to work with Flink 1.11.3? Is there a working Zeppelin Kubernetes YAML that works with Flink?

@zjffdu
Copy link
Copy Markdown
Contributor

zjffdu commented Jan 12, 2021

@amit-shahi You can download latest zeppelin 0.9 which support flink 1.11, but we haven't verified it on k8s

@amit-shahi
Copy link
Copy Markdown

@zjffdu Can I use the Docker Image apache/zeppelin:0.9.0 (https://hub.docker.com/r/apache/zeppelin/tags?page=1&ordering=last_updated)? Also, I have flink running on another POD on the same K8 cluster. Where do I configure Zeppelin to connect to my existing Flink Job Manager POD so Zeppelin can submit JOBS through it's UI?

@zjffdu
Copy link
Copy Markdown
Contributor

zjffdu commented Jan 12, 2021

I am afraid the docker image of 0.9 is still using 0.9.0-preview2, we are working on it to upgrade to 0.9.0
But it still support flink 1.11 IIRC.

@amit-shahi
Copy link
Copy Markdown

@zjffdu Okay. Which Zeppelin version I should from Docker? I have flink running on another POD on the K8s cluster. Where do I configure Zeppelin to connect to my existing Flink Job Manager POD so Zeppelin can submit JOBS through it's UI?

@zjffdu
Copy link
Copy Markdown
Contributor

zjffdu commented Jan 12, 2021

@amit-shahi
Copy link
Copy Markdown

amit-shahi commented Jan 12, 2021

@zjffdu Thanks. I'm accessing Kubernetes on the Windows system. As per the above documentation, Do I need to set FLINK_HOME to my local Flink directory (not on Kubernetes)? Can I bypass this so it can use Kubernetes Flink's FLINK_HOME reference instead? Where do I configure zeppelin so it can use K8's Flink settings for FLINK_HOME? What's the right way to do that?

@zjffdu
Copy link
Copy Markdown
Contributor

zjffdu commented Jan 12, 2021

flink should be put in the same host of zeppelin. FLINK_HOME point to that location.

@amit-shahi
Copy link
Copy Markdown

@zjffdu I'm not sure if I got that. Let's say on Kubernetes, Flink's Job Manager is installed on POD1 and Task Manager is installed on POD2. When we install Zeppelin through YAML, it gets installed on POD 3, How do I use POD1's (Job Manager) FLINK_HOME location/reference in POD 3 so Zeppelin server can connect to existing Flink installation?

@zjffdu
Copy link
Copy Markdown
Contributor

zjffdu commented Jan 12, 2021

You need to put flink in pod3 and specify FLINK_HOME to this path. Then specify flink.execution.remote.host and flink.execution.remote.port as the JobManager rest api address

@amit-shahi
Copy link
Copy Markdown

amit-shahi commented Jan 12, 2021

@zjffdu I made the changes as suggested.

image

When I run default Flink Job in Zeppelin, this is what I see-

image
or
image

This also causes the Flink Pod Restart which gets created by zeppelin-server.

I'm using zeppelin 0.9.0 from Docker Hub, and Flink 1.11.3. I'm not sure what else I need to change/fix, so I can submit Flink SQL job from zeppelin to main POD1 Flink cluster.

@zjffdu
Copy link
Copy Markdown
Contributor

zjffdu commented Jan 13, 2021

You need to set zeppelin.run.mode as local in zeppelin-site.xml, otherwise zeppelin would launch flink interpreter in another pod which may cause this issue.

@amit-shahi
Copy link
Copy Markdown

@zjffdu Thanks. I'm using this k8 YAML https://github.com/apache/zeppelin/blob/master/k8s/zeppelin-server.yaml

Is there a different image for interpreter apache/zeppelin-interpreter:0.9.0-SNAPSHOT (as mentioned in above YAML)
or can I use apache/zeppelin:0.9.0 from https://hub.docker.com/r/apache/zeppelin/tags as an image for ZEPPELIN_K8S_CONTAINER_IMAGE in zeppelin yaml?

@zjffdu
Copy link
Copy Markdown
Contributor

zjffdu commented Jan 13, 2021

@amit-shahi Let's discuss that in user mail list.

@amit-shahi
Copy link
Copy Markdown

@zjffdu Ok, I will create a thread on the mailing list.

@amit-shahi
Copy link
Copy Markdown

@zjffdu When I try to execute this YAML https://github.com/apache/zeppelin/blob/master/k8s/zeppelin-server.yaml thru
kubectl apply -f zeppelin-server.yaml, I see this error-

image

image

Is the yaml file correct?

@amit-shahi
Copy link
Copy Markdown

@zjffdu How do I set zeppelin.run.mode as local in zeppelin-site.xml?

@github-actions
Copy link
Copy Markdown

This pull request has been inactive for over a year. If no further activity occurs within the next 30 days, it will be automatically closed. If you believe this PR is still relevant, please feel free to leave a comment or make an update. Thank you!

@github-actions github-actions bot added the Stale label Jul 19, 2025
@github-actions
Copy link
Copy Markdown

This pull request has been automatically closed due to prolonged inactivity (over one year without updates). If you feel this was done in error or would like to continue the discussion, feel free to reopen it. Thank you for your contributions!

@github-actions github-actions bot closed this Aug 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants