[ZEPPELIN-6351] Close modals only on their own user actions

### What is this PR for?
On the home page, an open modal (e.g., `Import Note`, `Create New Note`) closes when a  `NOTES_INFO` message is received.

This is unexpected and makes running parallel E2E tests that create new notes unreliable.

#### Root cause
Both modals treated any `NOTES_INFO` message as the result of *their* own submit action.
Since `NOTES_INFO` message is broadcast for various events, this led to false positives.

#### Fix
Close modals only in response to messages addressed to the submitting client: `IMPORT_NOTE` and `NEW_NOTE`. The server already sends `NEW_NOTE` (used by the old UI), but not `IMPORT_NOTE`. I added a server-sent `IMPORT_NOTE` and replaced `broadcastNote(note)` with sending `IMPORT_NOTE` only to the caller. The previously broadcast `NOTE` is mainly useful to users already on that note page; for a newly imported note, no user is on that page yet, so the broadcast is unnecessary.

### What type of PR is it?
Bug Fix

### What is the Jira issue?
[[ZEPPELIN-6351]](https://issues.apache.org/jira/browse/ZEPPELIN-6351)

### How should this be tested?
- Open two browser windows (A and B).
- In A, open a modal (e.g., Import Note or Create New Note).
- In B, perform a submit that triggers a note update. Verify the modal in A does not close.
- In A, submit the modal. Verify it closes and the note list updates.

### Screenshots (if appropriate)

#### [AS-IS]

https://github.com/user-attachments/assets/a38a8334-81d3-45ae-9264-755143df9041

#### [TO-BE]


https://github.com/user-attachments/assets/b5e9148a-2a2a-441c-a389-aa1f558a025d



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


Closes #5092 from tbonelee/fix-modal-close.

Signed-off-by: ChanHo Lee <chanholee@apache.org>
9 files changed
tree: 44746bb388731dec3735dc1d921d2ebe8b87ce51
  1. .github/
  2. .husky/
  3. .mvn/
  4. alluxio/
  5. angular/
  6. bigquery/
  7. bin/
  8. build-tools/
  9. cassandra/
  10. conf/
  11. dev/
  12. docs/
  13. elasticsearch/
  14. examples/
  15. file/
  16. flink/
  17. flink-cmd/
  18. groovy/
  19. hbase/
  20. helium-dev/
  21. influxdb/
  22. java/
  23. jdbc/
  24. k8s/
  25. licenses/
  26. livy/
  27. markdown/
  28. mongodb/
  29. neo4j/
  30. notebook/
  31. python/
  32. rlang/
  33. scripts/
  34. shell/
  35. spark/
  36. spark-submit/
  37. sparql/
  38. testing/
  39. zeppelin-client/
  40. zeppelin-client-examples/
  41. zeppelin-common/
  42. zeppelin-distribution/
  43. zeppelin-examples/
  44. zeppelin-integration/
  45. zeppelin-interpreter/
  46. zeppelin-interpreter-integration/
  47. zeppelin-interpreter-parent/
  48. zeppelin-interpreter-shaded/
  49. zeppelin-jupyter/
  50. zeppelin-jupyter-interpreter/
  51. zeppelin-jupyter-interpreter-shaded/
  52. zeppelin-plugins/
  53. zeppelin-server/
  54. zeppelin-test/
  55. zeppelin-web/
  56. zeppelin-web-angular/
  57. zeppelin-zengine/
  58. .asf.yaml
  59. .gitattributes
  60. .gitignore
  61. Dockerfile
  62. LICENSE
  63. mvnw
  64. mvnw.cmd
  65. NOTICE
  66. pom.xml
  67. README.md
  68. Roadmap.md
  69. SECURITY-README.md
  70. STYLE.md
README.md

Apache Zeppelin

Documentation: User Guide
Mailing Lists: User and Dev mailing list
Continuous Integration: core frontend rat
Contributing: Contribution Guide
Issue Tracker: Jira
License: Apache 2.0

Zeppelin, a web-based notebook that enables interactive data analytics. You can make beautiful data-driven, interactive and collaborative documents with SQL, Scala and more.

Core features:

  • Web based notebook style editor.
  • Built-in Apache Spark support

To know more about Zeppelin, visit our web site https://zeppelin.apache.org

Getting Started

Install binary package

Please go to install to install Apache Zeppelin from binary package.

Build from source

Please check Build from source to build Zeppelin from source.