This repository was archived by the owner on Nov 24, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 355
Deprecate & Rewrite DELETE to_extension #4333
Merged
ocket8888
merged 11 commits into
apache:master
from
mhoppa:feature/rewrite_delete_to_extension
Jan 29, 2020
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
86a63fe
Initial implementation of to_extension POST rewrite
mhoppa 8198a93
Merge branch 'master' into feature/rewrite_to_extensions
mhoppa 13cd027
Rewrite to_extension POST
mhoppa 45f574f
remove commented out code
mhoppa 076610f
Merge branch 'master' into feature/rewrite_to_extensions
mhoppa 1198c40
Merge branch 'master' into feature/rewrite_to_extensions
mhoppa 7d3ec73
Remove non CHECK_EXTENSION create support as its broken in perl
mhoppa 22193e9
Deprecate/Rewrite to_extension DELETE
mhoppa 5865371
Merge branch 'master' into feature/rewrite_delete_to_extension
mhoppa b7f7457
Minor cleanup
mhoppa df6b4f9
Docs fixes
mhoppa File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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,76 @@ | ||
| .. | ||
| .. | ||
| .. Licensed 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. | ||
| .. | ||
|
|
||
| .. _to-api-to_extensions-id: | ||
|
|
||
| ************************ | ||
| ``to_extensions/{{ID}}`` | ||
| ************************ | ||
| .. versionadded:: 1.5 | ||
|
|
||
| ``DELETE`` | ||
| ========== | ||
| Deletes a Traffic Ops extension definition. This does **not** delete the actual extension file. | ||
|
|
||
| :Auth. Required: Yes | ||
| :Roles Required: None\ [1]_ | ||
| :Response Type: ``undefined`` | ||
|
|
||
| Request Structure | ||
| ----------------- | ||
| .. table:: Request Path Parameters | ||
|
|
||
| +------+---------------------------------------------------------------------------+ | ||
| | Name | Description | | ||
| +======+===========================================================================+ | ||
| | ID | The integral, unique identifier of the extension definition to be deleted | | ||
| +------+---------------------------------------------------------------------------+ | ||
|
|
||
| .. code-block:: http | ||
| :caption: Request Example | ||
|
|
||
| DELETE /api/1.5/to_extensions/16 HTTP/1.1 | ||
| Host: trafficops.infra.ciab.test | ||
| User-Agent: curl/7.47.0 | ||
| Accept: */* | ||
| Cookie: mojolicious=... | ||
|
|
||
| Response Structure | ||
| ------------------ | ||
| .. code-block:: http | ||
| :caption: Response Example | ||
|
|
||
| HTTP/1.1 200 OK | ||
| Access-Control-Allow-Credentials: true | ||
| Access-Control-Allow-Headers: Origin, X-Requested-With, Content-Type, Accept | ||
| Access-Control-Allow-Methods: POST,GET,OPTIONS,PUT,DELETE | ||
| Access-Control-Allow-Origin: * | ||
| Cache-Control: no-cache, no-store, max-age=0, must-revalidate | ||
| Content-Type: application/json | ||
| Date: Wed, 12 Dec 2018 16:33:52 GMT | ||
| Server: Mojolicious (Perl) | ||
| Set-Cookie: mojolicious=...; Path=/; Expires=Mon, 18 Nov 2019 17:40:54 GMT; Max-Age=3600; HttpOnly | ||
| Vary: Accept-Encoding | ||
| Whole-Content-Sha512: EB0Nu85azbGzaehDTAODP3NPqWbByIza1XQhgwtsW2WTXyK/dxQtncp0YiJXyO0tH9H+n+6BBfojBOb5h0dFPA== | ||
| Content-Length: 60 | ||
|
|
||
| { "alerts": [ | ||
| { | ||
| "level": "success", | ||
| "text": "Extension deleted." | ||
| } | ||
| ]} | ||
|
|
||
| .. [1] No roles are required to use this endpoint, however access is controlled by username. Only the reserved user ``extension`` is permitted the use of this endpoint. | ||
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.