Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolves #808 Updated docs to warn of possible race condition #1224

Merged
merged 2 commits into from
May 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions api-docs/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -1489,7 +1489,7 @@
}
},
"requestBody": {
"description": "<h3>Notes:</h3> <ul> <li>**providerMetadata** is set by the server. If provided, it will be overwritten.</li> <li>**datePublished** and **assignerShortname** are optional fields in the schema, but are set by the server. </li> </ul>",
"description": "<h3>Notes:</h3> <ul> <li>When updating a rejected record to published, it is recommended to confirm that both the Cve-Id and CVE record are in the REJECTED state after calling this endpoint. Though very unlikely, a race condition can occur causing the two states to be out of sync. </li> <li>**providerMetadata** is set by the server. If provided, it will be overwritten.</li> <li>**datePublished** and **assignerShortname** are optional fields in the schema, but are set by the server. </li> </ul>",
"required": true,
"content": {
"application/json": {
Expand Down Expand Up @@ -1693,7 +1693,7 @@
}
},
"requestBody": {
"description": "<h3>Notes:</h3> <ul> <li>**providerMetadata** is set by the server. If provided, it will be overwritten.</li> <li>**datePublished** and **assignerShortname** are optional fields in the schema, but are set by the server. </li> </ul>",
"description": "<h3>Notes:</h3> <ul> <li>It is recommended to confirm that both the Cve-Id and CVE record are in the REJECTED state after calling this endpoint. Though very unlikely, a race condition can occur causing the two states to be out of sync. </li> <li>**providerMetadata** is set by the server. If provided, it will be overwritten.</li> <li>**datePublished** and **assignerShortname** are optional fields in the schema, but are set by the server. </li> </ul>",
"required": true,
"content": {
"application/json": {
Expand Down
6 changes: 4 additions & 2 deletions src/controller/cve.controller/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -643,6 +643,7 @@ router.put('/cve/:id/cna',
#swagger.requestBody = {
description: '<h3>Notes:</h3>
<ul>
<li>When updating a rejected record to published, it is recommended to confirm that both the Cve-Id and CVE record are in the correct state after calling this endpoint. Though very unlikely, a race condition can occur causing the two states to be out of sync. </li>
<li>**providerMetadata** is set by the server. If provided, it will be overwritten.</li>
<li>**datePublished** and **assignerShortname** are optional fields in the schema, but are set by the server. </li>
</ul>',
Expand Down Expand Up @@ -824,11 +825,12 @@ router.put('/cve/:id/reject',
'#/components/parameters/apiSecretHeader'
]
#swagger.requestBody = {
description: '<h3>Notes:</h3>
description: "<h3>Notes:</h3>
<ul>
<li>It is recommended to confirm that both the Cve-Id and CVE record are in the REJECTED state after calling this endpoint. Though very unlikely, a race condition can occur causing the two states to be out of sync. </li>
<li>**providerMetadata** is set by the server. If provided, it will be overwritten.</li>
<li>**datePublished** and **assignerShortname** are optional fields in the schema, but are set by the server. </li>
</ul>',
</ul>",
required: true,
content: {
"application/json": {
Expand Down
Loading