This repository has been archived by the owner on Jun 6, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 549
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* VC update API doc (#1816) * refine api doc * refine doc * refine * refine * [VC update] rest-server (#1831) * change scheduler storage to zookeeper * add queue update * fix * add vc update api * add yarn health check, refine error * add api doc * refine api doc * refine api doc * update yarn response * add unit test * unit test * replace parseint with math.round, fix unit test * replace mathjs with build-in Math * vc update (#1974) * Update yarnContainerScript.mustache add entrypoint="" * add design for vc update * refine design of vc update * add description of /api/v1/:username/virtualClusters * remove design of vc_update to dir of webportal * refine design of vc * VC function development * vc style modification * vc list style modification * Modify the prompt * repair bug * remove design of vc_update and refine annotation * refine var name * Change eslint error * Optimize the code according to pr * Modified read-only
- Loading branch information
Showing
16 changed files
with
2,008 additions
and
316 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
// Copyright (c) Microsoft Corporation | ||
// All rights reserved. | ||
// | ||
// MIT License | ||
// | ||
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated | ||
// documentation files (the "Software"), to deal in the Software without restriction, including without limitation | ||
// the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and | ||
// to permit persons to whom the Software is furnished to do so, subject to the following conditions: | ||
// The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. | ||
// | ||
// THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING | ||
// BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, | ||
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
|
||
// module dependencies | ||
const Joi = require('joi'); | ||
|
||
// define the input schema for the 'update vc' api | ||
const vcPutInputSchema = Joi.object().keys({ | ||
vcCapacity: Joi.number() | ||
.integer() | ||
.min(0) | ||
.max(100) | ||
.required(), | ||
}).required(); | ||
|
||
// define the input schema for the 'put vc status' api | ||
const vcStatusPutInputSchema = Joi.object().keys({ | ||
vcStatus: Joi.string() | ||
.valid(['stopped', 'running']) | ||
.required(), | ||
}).required(); | ||
|
||
// module exports | ||
module.exports = { | ||
vcPutInputSchema: vcPutInputSchema, | ||
vcStatusPutInputSchema: vcStatusPutInputSchema, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.