[ZEPPELIN-3540] Show Spark inline UI in Non-Secure mode
What is this PR for?
After running a paragraph via Spark interpreter, we will be showing a "Spark UI" link. On clicking it, we show the Spark UI with the respective running job running.
What type of PR is it?
[Improvement]
What is the Jira issue?
How should this be tested?
Using Spark interpreter, run a paragraph. On successful execution, we will see a Spark UI link(as shown in screenshot below) Click on the link and the pop up modal opens up showing the Spark job in the Zeppelin context.
Screenshots (if appropriate)


@prabhjyotsingh @r-kamath - Just a reminder to review this.
@shahsank3t I didn't try this PR, but I didn't see backend pass spark.ui.allowFramingFrom to frontend, so how does frontend know whether it should show spark ui inline or in another windows of the old method ?
ping @shahsank3t Any updates ?
@zjffdu Apologies missed out the earlier notification.
I didn't try this PR, but I didn't see backend pass spark.ui.allowFramingFrom to frontend, so how does frontend know whether it should show spark ui inline or in another windows of the old method ?
Yes, you are right. Frontend is not checking the property spark.ui.allowFramingFrom and always explicitly showing spark ui inline(within a modal).
If we want to provide the support to fallback, we can check the specified property for any value and show ui inline and if no value is set, show in another windows. Sounds good?
One drawback of inline UI is that user can not switch from spark ui and notebook, this may make user annoyed .
can we open a pop up with options, like clicking on a url link in google doc? possible options: open, open in new tab
can we open a pop up with options, like clicking on a url link in google doc? possible options: open, open in new tab
@zjffdu Above suggestion makes sense right? User can click which ever desired option. @felixcheung Thanks for the suggestion, I'll look into it.
Make sense for me to provide options to allow user to chose.
@zjffdu @felixcheung Integrated your suggestions.
Below screenshot when single job is running:

Below screenshot with multiple job is running:

Please have a look.
I just have concern that is it possible to implement it via less code change. Because it seems to be a very simple function to pop an iframe window. Not sure why it would involve so many code change. But I am not frontend expert, I may be wrong on this. Wait for other frontend expert for more comments. \cc @prabhjyotsingh
I agree with @zjffdu. AFAIK, we already have a modal for some other reasons. Can we reuse them for this issue?
@jongyoul @zjffdu @prabhjyotsingh Updated the code by reusing modal and other available methods. Please review it.
@shahsank3t can you enable CI, looks like Travis builds are not enabled https://zeppelin.apache.org/contribution/contributions.html#continuous-integration
@prabhjyotsingh Done enabling CI
@zjffdu @prabhjyotsingh Updated the PR with all the changes and documentation. Please review and let me know if I should rebase and squash the commits.
@zjffdu Thanks for the review. I wasn't aware of Zeppelin context as another thing. Have addressed your comments and fixed the wording.
@r-kamath - addressed your review comments. Please have a look again. Thanks in advance.