summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsourabh_sourabh <sourabh.sourabh@est.tech>2024-10-04 14:35:32 +0100
committersourabh_sourabh <sourabh.sourabh@est.tech>2024-10-04 14:51:05 +0100
commitef70022bddcb18a17c4afe2332cafa78621ab8b5 (patch)
tree1405c88ab9fccfb5e9971079ecddaf6cf9e649b9
parentf540809d5b1f70a6055b7b9bf39c4ed81413b6e3 (diff)
[CPS] OSLO release changes
- Updated open api for cps, ncmp and policy apis. - Updated release notes with bus and features. Issue-ID: CPS-2434 Change-Id: Ib4d80f3939b6e267f228177c817e43832a9384db Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
-rw-r--r--docs/api/swagger/cps/openapi.yaml6
-rw-r--r--docs/api/swagger/ncmp/openapi.yaml88
-rw-r--r--docs/api/swagger/policy-executor/openapi.yaml315
-rw-r--r--docs/release-notes.rst8
4 files changed, 254 insertions, 163 deletions
diff --git a/docs/api/swagger/cps/openapi.yaml b/docs/api/swagger/cps/openapi.yaml
index d6cca6e687..d22b2887a6 100644
--- a/docs/api/swagger/cps/openapi.yaml
+++ b/docs/api/swagger/cps/openapi.yaml
@@ -2406,17 +2406,17 @@ components:
<code>2</code> <name>kids</name> </categories> </bookstore> </stores>
deltaReportSample:
value:
- - action: ADD
+ - action: create
xpath: "/bookstore/categories/[@code=3]"
target-data:
code: "3,"
name: kidz
- - action: REMOVE
+ - action: remove
xpath: "/bookstore/categories/[@code=1]"
source-data:
code: "1,"
name: Fiction
- - action: UPDATE
+ - action: replace
xpath: "/bookstore/categories/[@code=2]"
source-data:
name: Funny
diff --git a/docs/api/swagger/ncmp/openapi.yaml b/docs/api/swagger/ncmp/openapi.yaml
index a227addda5..871090fc7c 100644
--- a/docs/api/swagger/ncmp/openapi.yaml
+++ b/docs/api/swagger/ncmp/openapi.yaml
@@ -20,13 +20,14 @@ paths:
schema:
example: ncmp-datastore:running
type: string
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
- description: The format of resource identifier depend on the associated DMI
Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
@@ -130,13 +131,14 @@ paths:
schema:
example: ncmp-datastore:running
type: string
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
- description: The format of resource identifier depend on the associated DMI
Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
@@ -264,13 +266,14 @@ paths:
schema:
example: ncmp-datastore:running
type: string
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
- description: The format of resource identifier depend on the associated DMI
Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
@@ -377,13 +380,14 @@ paths:
schema:
example: ncmp-datastore:running
type: string
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
- description: The format of resource identifier depend on the associated DMI
Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
@@ -495,13 +499,14 @@ paths:
schema:
example: ncmp-datastore:running
type: string
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
- description: The format of resource identifier depend on the associated DMI
Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
@@ -824,13 +829,14 @@ paths:
handle
operationId: getModuleReferencesByCmHandle
parameters:
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
responses:
"200":
@@ -880,13 +886,14 @@ paths:
\ with options to filter on module name and revision"
operationId: getModuleDefinitions
parameters:
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
- description: Filter for a module name.This is an optional parameter
in: query
@@ -1017,13 +1024,14 @@ paths:
description: Retrieve CM handle details and properties by cm handle id
operationId: retrieveCmHandleDetailsById
parameters:
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
responses:
"200":
@@ -1070,13 +1078,14 @@ paths:
description: Get CM handle properties by cm handle id
operationId: getCmHandlePublicPropertiesByCmHandleId
parameters:
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
responses:
"200":
@@ -1210,13 +1219,14 @@ paths:
description: Get CM handle state by cm handle id
operationId: getCmHandleStateByCmHandleId
parameters:
- - description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ - description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network\
+ \ CM Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
responses:
"200":
@@ -1464,14 +1474,15 @@ components:
schema:
example: ncmp-datastore:running
type: string
- cmHandleInPath:
- description: "The identifier for a network function, network element, subnetwork\
- \ or any other cm object by managed Network CM Proxy"
+ cmHandleReferenceInPath:
+ description: "The identifier (cmHandle or alternate) for a network function,\
+ \ network element, subnetwork or any other cm object by managed Network CM\
+ \ Proxy"
in: path
name: cm-handle
required: true
schema:
- example: my-cm-handle
+ example: my-cm-handle-reference
type: string
resourceIdentifierInQuery:
description: The format of resource identifier depend on the associated DMI
@@ -1558,6 +1569,15 @@ components:
required: true
schema:
type: string
+ cmHandleInPath:
+ description: "The identifier for a network function, network element, subnetwork\
+ \ or any other cm object by managed Network CM Proxy"
+ in: path
+ name: cm-handle
+ required: true
+ schema:
+ example: my-cm-handle
+ type: string
cpsPathInQuery:
description: "For more details on cps path, please refer https://docs.onap.org/projects/onap-cps/en/latest/cps-path.html"
examples:
diff --git a/docs/api/swagger/policy-executor/openapi.yaml b/docs/api/swagger/policy-executor/openapi.yaml
index 6b73d98ed6..1248c0d08b 100644
--- a/docs/api/swagger/policy-executor/openapi.yaml
+++ b/docs/api/swagger/policy-executor/openapi.yaml
@@ -18,55 +18,170 @@
openapi: 3.0.3
info:
+ description: Allows NCMP to execute a policy defined by a third party implementation
+ before proceeding with a CM operation
title: Policy Executor
- description: "Allows NCMP to execute a policy defined by a third party implementation before proceeding with a CM operation"
version: 1.0.0
+servers:
+- url: /
+security:
+- bearerAuth: []
tags:
- - name: policy-executor
- description: "Execute all your policies"
+- description: Execute all your policies
+ name: policy-executor
paths:
/policy-executor/api/v1/{action}:
post:
- description: "Fire a Policy action"
+ description: Fire a Policy action
operationId: executePolicyAction
parameters:
- - $ref: '#/components/parameters/authorizationInHeader'
- - $ref: '#/components/parameters/actionInPath'
- requestBody:
+ - description: Bearer token may be used to identify client as part of a policy
+ explode: false
+ in: header
+ name: Authorization
+ required: false
+ schema:
+ type: string
+ style: simple
+ - description: "The policy action. Currently supported options: 'execute'"
+ explode: false
+ in: path
+ name: action
required: true
- description: "The action request body"
+ schema:
+ example: execute
+ type: string
+ style: simple
+ requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/PolicyExecutionRequest'
- tags:
- - policy-executor
+ description: The action request body
+ required: true
responses:
- '200':
- description: "Successful policy execution"
+ "200":
content:
application/json:
schema:
$ref: '#/components/schemas/PolicyExecutionResponse'
- '400':
- $ref: '#/components/responses/BadRequest'
- '401':
- $ref: '#/components/responses/Unauthorized'
- '403':
- $ref: '#/components/responses/Forbidden'
- '500':
- $ref: '#/components/responses/InternalServerError'
-
+ description: Successful policy execution
+ "400":
+ content:
+ application/json:
+ example:
+ status: 400
+ message: Bad Request
+ details: The provided request is not valid
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Bad request
+ "401":
+ content:
+ application/json:
+ example:
+ status: 401
+ message: Unauthorized request
+ details: This request is unauthorized
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Unauthorized request
+ "403":
+ content:
+ application/json:
+ example:
+ status: 403
+ message: Request Forbidden
+ details: This request is forbidden
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Request forbidden
+ "500":
+ content:
+ application/json:
+ example:
+ status: 500
+ message: Internal Server Error
+ details: Internal server error occurred
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Internal server error
+ tags:
+ - policy-executor
components:
- securitySchemes:
- bearerAuth:
- type: http
- description: "Bearer token (from client that called CPS-NCMP),used by policies to identify the client"
- scheme: bearer
+ parameters:
+ actionInPath:
+ description: "The policy action. Currently supported options: 'execute'"
+ explode: false
+ in: path
+ name: action
+ required: true
+ schema:
+ example: execute
+ type: string
+ style: simple
+ authorizationInHeader:
+ description: Bearer token may be used to identify client as part of a policy
+ explode: false
+ in: header
+ name: Authorization
+ required: false
+ schema:
+ type: string
+ style: simple
+ responses:
+ BadRequest:
+ content:
+ application/json:
+ example:
+ status: 400
+ message: Bad Request
+ details: The provided request is not valid
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Bad request
+ Unauthorized:
+ content:
+ application/json:
+ example:
+ status: 401
+ message: Unauthorized request
+ details: This request is unauthorized
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Unauthorized request
+ Forbidden:
+ content:
+ application/json:
+ example:
+ status: 403
+ message: Request Forbidden
+ details: This request is forbidden
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Request forbidden
+ InternalServerError:
+ content:
+ application/json:
+ example:
+ status: 500
+ message: Internal Server Error
+ details: Internal server error occurred
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Internal server error
+ NotImplemented:
+ content:
+ application/json:
+ example:
+ status: 501
+ message: Not Implemented
+ details: Method not implemented
+ schema:
+ $ref: '#/components/schemas/ErrorMessage'
+ description: Method not (yet) implemented
schemas:
ErrorMessage:
- type: object
- title: Error
properties:
status:
type: string
@@ -74,125 +189,73 @@ components:
type: string
details:
type: string
-
- Request:
+ title: Error
type: object
+ Request:
+ example:
+ schema: org.onap.cps.ncmp.policy-executor:ncmp-create-schema:1.0.0
+ data: "{}"
properties:
schema:
+ description: The schema for the data in this request. The schema name should
+ include the type of operation
+ example: org.onap.cps.ncmp.policy-executor:ncmp-create-schema:1.0.0
type: string
- description: "The schema for the data in this request. The schema name should include the type of operation"
- example: "org.onap.cps.ncmp.policy-executor:ncmp-create-schema:1.0.0"
data:
+ description: The data related to the request. The format of the object is
+ determined by the schema
type: object
- description: "The data related to the request. The format of the object is determined by the schema"
required:
- - schema
- - data
-
- PolicyExecutionRequest:
+ - data
+ - schema
type: object
+ PolicyExecutionRequest:
+ example:
+ decisionType: allow
+ requests:
+ - schema: org.onap.cps.ncmp.policy-executor:ncmp-create-schema:1.0.0
+ data: "{}"
+ - schema: org.onap.cps.ncmp.policy-executor:ncmp-create-schema:1.0.0
+ data: "{}"
properties:
decisionType:
- type: string
description: "The type of decision. Currently supported options: 'allow'"
- example: "allow"
+ example: allow
+ type: string
requests:
- type: array
items:
$ref: '#/components/schemas/Request'
+ type: array
required:
- - decisionType
- - requests
-
- PolicyExecutionResponse:
+ - decisionType
+ - requests
type: object
+ PolicyExecutionResponse:
+ example:
+ decision: deny
+ decisionId: 550e8400-e29b-41d4-a716-446655440000
+ message: Object locked due to recent change
properties:
decisionId:
+ description: Unique ID for the decision (for auditing purposes)
+ example: 550e8400-e29b-41d4-a716-446655440000
type: string
- description: "Unique ID for the decision (for auditing purposes)"
- example: "550e8400-e29b-41d4-a716-446655440000"
decision:
- type: string
description: "The decision outcome. Currently supported values: 'allow','deny'"
- example: "deny"
+ example: deny
+ type: string
message:
+ description: Additional information regarding the decision outcome
+ example: Object locked due to recent change
type: string
- description: "Additional information regarding the decision outcome"
- example: "Object locked due to recent change"
required:
- - decisionId
- - decision
- - message
-
- responses:
- BadRequest:
- description: "Bad request"
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ErrorMessage'
- example:
- status: 400
- message: "Bad Request"
- details: "The provided request is not valid"
- Unauthorized:
- description: "Unauthorized request"
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ErrorMessage'
- example:
- status: 401
- message: "Unauthorized request"
- details: "This request is unauthorized"
- Forbidden:
- description: "Request forbidden"
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ErrorMessage'
- example:
- status: 403
- message: "Request Forbidden"
- details: "This request is forbidden"
-
- InternalServerError:
- description: "Internal server error"
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ErrorMessage'
- example:
- status: 500
- message: "Internal Server Error"
- details: "Internal server error occurred"
-
- NotImplemented:
- description: "Method not (yet) implemented"
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ErrorMessage'
- example:
- status: 501
- message: "Not Implemented"
- details: "Method not implemented"
-
- parameters:
- actionInPath:
- name: action
- in: path
- description: "The policy action. Currently supported options: 'execute'"
- required: true
- schema:
- type: string
- example: "execute"
- authorizationInHeader:
- name: Authorization
- in: header
- description: "Bearer token may be used to identify client as part of a policy"
- schema:
- type: string
-
-security:
- - bearerAuth: []
+ - decision
+ - decisionId
+ - message
+ type: object
+ securitySchemes:
+ bearerAuth:
+ description: "Bearer token (from client that called CPS-NCMP),used by policies\
+ \ to identify the client"
+ scheme: bearer
+ type: http
diff --git a/docs/release-notes.rst b/docs/release-notes.rst
index 7340e7a788..74a6ce5e2b 100644
--- a/docs/release-notes.rst
+++ b/docs/release-notes.rst
@@ -39,10 +39,18 @@ Release Data
Bug Fixes
---------
3.5.3
+ - `CPS-2353 <https://lf-onap.atlassian.net/browse/CPS-2353>`_ Slow cmHandle registration when we use moduleSetTag, alternateId and dataProducerIdentifier
+ - `CPS-2395 <https://lf-onap.atlassian.net/browse/CPS-2395>`_ Retry mechanism (with back off algorithm) is removed with more frequent watchdog poll
+ - `CPS-2409 <https://lf-onap.atlassian.net/browse/CPS-2409>`_ Return NONE for get effective trust level api if the trust level caches empty (restart case)
+ - `CPS-2430 <https://lf-onap.atlassian.net/browse/CPS-2430>`_ Fix memory leak related to using arrays in Hibernate
+
Features
--------
3.5.3
+ - `CPS-2247 <https://lf-onap.atlassian.net/browse/CPS-2247>`_ Policy Executor: Invoke Policy Executor and handle 'deny' response
+ - `CPS-2412 <https://lf-onap.atlassian.net/browse/CPS-2412>`_ Policy Executor: handle errors
+ - `CPS-2417 <https://lf-onap.atlassian.net/browse/CPS-2417>`_ Remove Hazelcast cache for prefix resolver
Version: 3.5.2