Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ZEPPELIN-6145] Remove useless message type in Terminal Interpreter #4894

Merged
merged 2 commits into from
Nov 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,6 @@ public class TerminalService {

private LinkedBlockingQueue<String> commandQueue = new LinkedBlockingQueue<>();

public void onTerminalInit() {
LOGGER.info("onTerminalInit");
}

public void onTerminalReady() {
TerminalService.startThread(() -> {
try {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,6 @@ public void onWebSocketText(String message) {
if (messageMap.containsKey("type")) {
String type = messageMap.get("type");
switch (type) {
case "TERMINAL_INIT":
terminalService.onTerminalInit();
this.noteId = messageMap.get("noteId");
this.paragraphId = messageMap.get("paragraphId");
terminalManager.onWebSocketConnect(noteId, paragraphId);
break;
case "TERMINAL_READY":
terminalService.onTerminalReady();
this.noteId = messageMap.get("noteId");
Expand Down
8 changes: 0 additions & 8 deletions shell/src/main/resources/html/js/index.js
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you remove commented method call for app.onTerminalInit() in the file for clarity?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,6 @@ function action(type, data) {
}

let app = {
onTerminalInit() {
// alert("TERMINAL_INIT");
ws.send(action("TERMINAL_INIT", {
noteId, paragraphId
}));
},
onCommand(command) {
ws.send(action("TERMINAL_COMMAND", {
command
Expand All @@ -78,8 +72,6 @@ function setupHterm() {
t = new hterm.Terminal();

t.onTerminalReady = function() {
// app.onTerminalInit();

// Create a new terminal IO object and give it the foreground.
// (The default IO object just prints warning messages about unhandled
// things to the the JS console.)
Expand Down
Loading