Github user bzz commented on the issue:

    https://github.com/apache/zeppelin/pull/1304
  
    @corneadoug thank you for explaining!
    
    So we are talking about WS API to fetch full notebook state from the 
history by it's revision? Wich on client-side looks like 
[websocketMsgSrv.getNoteRevision($routeParams.noteId, 
$routeParams.revisionId);](https://github.com/apache/zeppelin/blob/3bd94ddc77ef9f9853ae978bf024d206378f16ba/zeppelin-web/src/components/websocketEvents/websocketMsg.service.js#L175)
    
    And on the back-end is a 
[NOTE_REVISION](https://github.com/apache/zeppelin/blob/36a7e38ffd6af614ad770a6e23ec1fd98a90c809/zeppelin-server/src/main/java/org/apache/zeppelin/socket/NotebookServer.java#L239)
 event in `NotebookServer`.
    
    @khalidhuseynov I think first of all, there is a bit of confusion here: 
this event is handled by
    `getNoteRevision` which looks more like `getNoteByRevision` because 
`Revision`, as discussed before, just represents the reference to the point in 
time, knowing which a full Note can be obtained, as it was back then. So 
`getNoteRevision` may be interpreted as a getter for Revision, rather than the 
Note.
    
    Then, it makes perfect sense to change the 
[Notebook.getNoteRevision()](https://github.com/apache/zeppelin/blob/5cdc02d3651fc8f5b7f9aa81f1d617007932b666/zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/Notebook.java#L366)
 API, both, function name AND a signature, as that is the place where actual 
work of retrieving the Note is done, to something like:
    
    ```java
    getNoteByRevisionId(String noteId, String revisionId, AuthenticationInfo 
subject)
    ```
    
    And this necessity, that comes from API client, at least for me, is an 
overriding argument in our discussion: you were right and we should adjust 
[NotebookRepo.get](https://github.com/apache/zeppelin/pull/1254/files#diff-eea417ea15b9480afaf52ebe1f51449dR92)
 interface and follow your design from #1254 (and close #1277).
    
    What do you think?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to