jiwq commented on a change in pull request #61: SUBMARINE-189. [SS] Add submarine server architecture doc URL: https://github.com/apache/hadoop-submarine/pull/61#discussion_r339108749
########## File path: docs/design/submarine-server/architecture.md ########## @@ -0,0 +1,126 @@ +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you under the Apache License, Version 2.0 (the + "License"); you may not use this file except in compliance + with the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, + software distributed under the License is distributed on an + "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + KIND, either express or implied. See the License for the + specific language governing permissions and limitations + under the License. + --> +## Motivation +Due to the single responsibility of considering different components, and nowadays the core module depends the hadoop libs which can be setted optional. + +## Proposal + ``` + +---------------------+ + +-----------+ | +--------+ +----+ | + | | | |runtime1+-->+job1| | + | workbench +---+ +---------------------------------+ | +--------+ +----+ | + | | | | +------+ +--------------------+ | +-->+ +--------+ +----+ | + +-----------+ | | | | | +------+ +-------+ | | | | |runtime2+-->+job2| | + | | | | | | YARN | | K8s | | | | | +--------+ +----+ | + +-----------+ | | | | | +------+ +-------+ | | | | YARN Cluster | + | | | | | | | submitter | | | +---------------------+ + | CLI +------->+ | | +--------------------+ +---+ + | | | | | REST | +--------+ +---------+ | | +---------------------+ + +-----------+ | | | | | TRANSL | | monitor | | | | +--------+ +----+ | + | | | | +--------+ +---------+ | | | | +-->+job1| | + +-----------+ | | | | +--------------------+ | | | | | +----+ | + | | | | | | | JobManager | | +-->+ |operator| +----+ | + | SDK +---+ | +------+ +--------------------+ | | | +-->+job2| | + | | +---------------------------------+ | +--------+ +----+ | + +-----------+ | K8s Cluster | + client server +---------------------+ + ``` +We propose to split the core module to two modules, CLI and server as shown in FIG. The client call the REST API to submit and retrieve the job info. + +### Submarine module structure +``` + |--submarine + |--submarine-all + |--submarine-client + |--submarine-commons + |--submarine-dist + |--submarine-sdk + | |--pysubmarine + |--submarine-server + | |--server-core + | |--server-submitter + | | |----submitter-yarn + | | |----submitter-yarnservice + | | |----submitter-k8s + | |--server-yarn-runtime + | |--server-operator + |--submarine-workbench + | |--workbench-server + | |--workbench-web + |--submodules +``` + +### submarine-client +The client as the default implements for submarine server RESTful API, it provides all the features which declared in the RESTful API. + +### submarine-server +``` ++------+ +--------------------+ +| | | +------+ +-------+ | +| | | | YARN | | K8s | | +| | | +------+ +-------+ | +| | | submitter | +| | +--------------------+ +| REST | +--------+ +---------+ +| | | TRANSL | | monitor | +| | +--------+ +---------+ +| | +--------------------+ +| | | JobManager | ++------+ +--------------------+ +``` +The project structure is as follows: +``` + |--submarine-server + |----server-api + |----server-core + |----server-submitter + |----pom.xml + |----README +``` +The server-sdk will be added in the future. It is the official client for Submarine Server API. + +#### REST +It provides the RESTful API for users, consists of submit job and get job info features and so on. Often used by CLI and workbench etc. The submarine client project should implement all APIs. Review comment: As the Birds Eyes View Architecture, I think we should keep it simple and should clever describe the architecture. About the each component's detailed design maybe we can propose inside alone doc in the same location. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services