You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ratis.apache.org by "Josh Elser (JIRA)" <ji...@apache.org> on 2018/11/02 22:56:00 UTC

[jira] [Commented] (RATIS-387) Create interactive demo client

    [ https://issues.apache.org/jira/browse/RATIS-387?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16673792#comment-16673792 ] 

Josh Elser commented on RATIS-387:
----------------------------------

Attached a WIP patch:
{code:java}
% mvn exec:java -Dexec.mainClass=org.apache.ratis.logservice.shell.LogServiceShell -Dexec.args="-q localhost:9990,localhost:9991,localhost:9992"
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Detecting the operating system and CPU architecture
[INFO] ------------------------------------------------------------------------
[INFO] os.detected.name: osx
[INFO] os.detected.arch: x86_64
[INFO] os.detected.version: 10.12
[INFO] os.detected.version.major: 10
[INFO] os.detected.version.minor: 12
[INFO] os.detected.classifier: osx-x86_64
[INFO]
[INFO] -----------------< org.apache.ratis:ratis-logservice >------------------
[INFO] Building Apache Ratis LogService 0.3.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[WARNING] The POM for org.apache.ratis:ratis-thirdparty-hadoop:jar:0.1.0-SNAPSHOT is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
[INFO]
[INFO] --- exec-maven-plugin:1.3.1:java (default-cli) @ ratis-logservice ---
[WARNING] Warning: killAfter is now deprecated. Do you need it ? Please comment on MEXEC-6.
logservice> create log1
TODO implement create
logservice> put log1 a
TODO implement put
logservice> read log1
TODO implement read
logservice> delete log1
TODO implement delete
logservice> quit
Bye!
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 31.349 s
[INFO] Finished at: 2018-11-02T18:53:22-04:00
[INFO] ------------------------------------------------------------------------{code}
I need to actually wire up the calls to the state machine – close though. I think this will be pretty darn useful.

> Create interactive demo client
> ------------------------------
>
>                 Key: RATIS-387
>                 URL: https://issues.apache.org/jira/browse/RATIS-387
>             Project: Ratis
>          Issue Type: Sub-task
>          Components: LogService
>            Reporter: Josh Elser
>            Assignee: Josh Elser
>            Priority: Major
>         Attachments: RATIS-387.wip.patch
>
>
> I've been thinking about how to give a "compelling" demo for the LogService. I keep coming back to a simple shell that could be used to do simple things like create, read, and write to a log.
> I am thinking something like:
> {code}
> > create 'log1'
> > put 'log1' 'a'
> > put 'log1' 'b'
> > put 'log1' 'c'
> > read 'log1'
> ['a', 'b', 'c']
> > delete 'log'
> {code}
> Users would provide the location of the MetaData service to this shell. Everything else should be auto-magic (in the final version, anyways).
> I think this compliments the docker infra work that [~rajeshbabu] is working on.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)