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 796] Duplicated notebook names should not be allowed #1464
Conversation
addConnectionToNote(note.getId(), (NotebookSocket) conn); | ||
conn.send(serializeMessage(new Message(OP.NEW_NOTE).put("note", note))); | ||
broadcastNoteList(subject); | ||
} catch (DuplicateNameException dne) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't it rethrow the exception? would the caller expect an exception like IOException?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For all websocket requests, we are sending responses from notebookServer class. So, i believe as a standard we should handle the response in the same file. So, rethrowing the exception wouldn't serve that purpose.
### What is this PR for? This PR is for refactoring code for JDBCInterpreter. There is no putting 'Connection' to 'propertyKeyUnusedConnectionListMap' anywhere in the original code. ### What type of PR is it? Improvement ### What is the Jira issue? https://issues.apache.org/jira/browse/ZEPPELIN-1405 ### Questions: * Does the licenses files need update? no * Is there breaking changes for older versions? no * Does this needs documentation? no Author: astroshim <hsshim@nflabs.com> Closes #1396 from astroshim/ZEPPELIN-1405 and squashes the following commits: b07e162 [astroshim] add checking connection is null f6998c2 [astroshim] Merge branch 'master' into ZEPPELIN-1405 1862ae6 [astroshim] Merge branch 'master' into ZEPPELIN-1405 efc2bfc [astroshim] rebase 21217a7 [astroshim] fix indentation. 4d4f85c [astroshim] refactoring code of close() 9f1e368 [astroshim] replace ConnectionPool 4dabbcc [astroshim] wip) changing to use dbcp 12dd7cb [astroshim] remove propertyKeyUnusedConnectionListMap map
@rajarajan-g why do you think it's a problem having same note title/name with existing one. could you give more context? |
@khalidhuseynov : Lets say if i create a note with name 'Note'. If zeppelin allows me to create a new note with name 'Note', then after sometime when i search for one of this note, I am going to get confused here. |
Going to reopen the pull request to trigger CI build |
CI build is green & success. Please review |
I think this PR contains wrong changes like JDBC*. Is it correct? |
@rajarajan-g How do you handle if another user with same notebook name decides to gives you read ability on his notebook? |
@jongyoul : Thanks for noticing that. I didn't make those changes. Those changes seems to come from another commit. Need to check that |
@corneadoug : Nice catch. I didn't check that scenario. Will let you once, i figure out a way. |
Well the problem here is that there is really nothing you can do, you are not going to change your Notebook name, or somebody else notebook name because both name are the same |
@jongyoul : Hey i was quite busy for sometime. I was trying to resolve the commit issues that you have pointed out. but while during rebase i am getting below error
Even though after i resolve the conflicts, again it shows conflict again and not able to remove that unnecessary commit that you pointed out. Please help me out on resolving that issue Please let me know if anyone has faced this issue and also please let me if there is a way to resolve this issue. |
@corneadoug : If a user creates a note with same name, it would do no good to that user itself as it confuses him. For resolving the scenario, we can pick one of the below ways
NoteName (created by user1) |
Hi All, |
What is this PR for?
When a notebook is created/cloned/imported the title/name of the new notebook should not be duplicate of the existing notebook's title/name
What type of PR is it?
Improvement
Todos
What is the Jira issue?
https://issues.apache.org/jira/browse/ZEPPELIN-796
How should this be tested?
allow user to create note.
Screenshots (if appropriate)
Screenshot of error message displayed during create/clone notebook
Screenshot of error message displayed during import notebook
Questions: