Commit 3a5865fa authored by Adrian Pino's avatar Adrian Pino
Browse files

Merge upstream main to resolve conflicts. Update monitoring test

Include the conf test within the monitoring test
parents 171ee3de f180830d
Loading
Loading
Loading
Loading
+46 −22
Original line number Diff line number Diff line
<a href="https://github.com/SunriseOpenOperatorPlatform/open-sdk/actions/workflows/ci.yaml" title="CI Status">
  <img src="https://github.com/SunriseOpenOperatorPlatform/open-sdk/actions/workflows/ci.yaml/badge.svg">
</a>
<a href="https://github.com/SunriseOpenOperatorPlatform/open-sdk/commits/" title="Last Commit">
  <img src="https://img.shields.io/github/last-commit/SunriseOpenOperatorPlatform/open-sdk?style=plastic">
</a>
<a href="https://github.com/SunriseOpenOperatorPlatform/open-sdk/issues" title="Open Issues">
  <img src="https://img.shields.io/github/issues/SunriseOpenOperatorPlatform/open-sdk?style=plastic">
</a>
<a href="https://github.com/SunriseOpenOperatorPlatform/open-sdk/pulls" title="Open Pull Requests">
  <img src="https://img.shields.io/github/issues-pr/SunriseOpenOperatorPlatform/open-sdk?style=plastic">
</a>
<a href="https://github.com/SunriseOpenOperatorPlatform/open-sdk/graphs/contributors" title="Contributors">
  <img src="https://img.shields.io/github/contributors/SunriseOpenOperatorPlatform/open-sdk?style=plastic">
</a>
<a href="https://github.com/SunriseOpenOperatorPlatform/open-sdk/blob/main/LICENSE" title="License">
  <img src="https://img.shields.io/badge/License-Apache%202.0-green.svg?style=plastic">
</a>
<a href="https://github.com/SunriseOpenOperatorPlatform/open-sdk/releases/latest" title="Latest Release">
  <img src="https://img.shields.io/github/release/SunriseOpenOperatorPlatform/open-sdk?style=plastic">
</a>


# OpenSDK

Open source SDK to abstract CAMARA/GSMA Transformation Functions (TFs) for Edge Cloud platforms, 5G network cores and O-RAN solutions.

## Features

- Unified SDK for interacting with Edge Cloud platforms, 5G Core solutions, and O-RAN solutions.
- Abstract CAMARA Transformation Functions (TFs)
- Unified Python SDK for interacting with Edge Cloud platforms, 5G Core solutions, and O-RAN solutions.
- Modular and extensible adapter structure
- Conforms to CAMARA/GSMA API standards.


---

@@ -15,27 +39,27 @@ Open source SDK to abstract CAMARA/GSMA Transformation Functions (TFs) for Edge
### CAMARA APIs

| API Name                  | Version |
|----------------------|--------------|
| Edge Application Management            | v0.9.3-wip   |
| Quality-on-Demand    | v1.0.0       |
| Location Retrieval   | v1.0.0       |
| Traffic Influence    | v0.8.1       |
|---------------------------|---------|
| Edge Application Management | [v0.9.3-wip](https://raw.githubusercontent.com/camaraproject/EdgeCloud/main/code/API_definitions/Edge-Application-Management.yaml) |
| Quality-on-Demand         | [v1.0.0](https://raw.githubusercontent.com/camaraproject/QualityOnDemand/refs/tags/r2.2/code/API_definitions/quality-on-demand.yaml) |
| Location Retrieval        | [v0.4.0](https://raw.githubusercontent.com/camaraproject/DeviceLocation/refs/tags/r2.2/code/API_definitions/location-retrieval.yaml) |
| Traffic Influence         | [v0.8.1](https://raw.githubusercontent.com/camaraproject/EdgeCloud/v0.8.1/code/API_definitions/Traffic_Influence.yaml) |

### EdgeCloud Platforms

| Platform   | Status     |
|------------|------------|
| Kubernetes | To be supported soon |
| i2Edge     | Supported  |
| aerOS      | Supported  |
| Kubernetes |  |
| i2Edge     |   |
| aerOS      |   |

### Network Adapters

| Platform     | NEF Version | QoD | Location Retrieval | Traffic Influence |
|--------------|-------------|-----|---------------------|--------------------|
| Open5GS      | v1.2.3      | ✅  | ✅                  | ❌                 |
| Open5GCore   | v1.2.3      | ✅  | ❌                  | ❌                 |
| OAI          | v1.2.3      | ✅  | ❌                  | ✅                 |
| Open5GS      | [v1.2.3](https://www.3gpp.org/ftp/Specs/archive/29_series/29.122/29122-hc0.zip) TS 29.122 (v17.12.0) | ✅  | ✅                  | ❌                 |
| Open5GCore   | [v1.2.3](https://www.3gpp.org/ftp/Specs/archive/29_series/29.122/29122-hc0.zip) TS 29.122 (v17.12.0) | ✅  | ❌                  | ❌                 |
| OAI          | [v1.2.3](https://www.3gpp.org/ftp/Specs/archive/29_series/29.122/29122-hc0.zip) TS 29.122 (v17.12.0) | ✅  | ❌                  | ✅                 |

---

@@ -59,7 +83,7 @@ cd open-sdk
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
pip intall -e .
pip install -e .
```

### Basic Usage
@@ -105,8 +129,8 @@ participant K8s as Kubernetes

note over SDK: [Config] Edge Cloud platform: Kubernetes, IP, Port
API ->> SDK: from sunrise6g_opensdk import Sdk as sdkclient
API ->> SDK: sdkclient.create_clients_from(configuration)
API ->> SDK: edgecloud_client = clients.get("edgecloud")
API ->> SDK: sdkclient.create_adapters_from(configuration)
API ->> SDK: edgecloud_client = adapters.get("edgecloud")
SDK ->> SDK: SDK initialized and ready to be used
note over AP,API: Platform ready to receive CAMARA calls
AP ->> API: POST /app (APP_ONBOARD_MANIFEST)
@@ -133,8 +157,8 @@ participant 5GS as Open5GS

note over SDK: [Config] Network core: Open5Gs, IP, Port
API ->> SDK: from sunrise6g_opensdk import Sdk as sdkclient
API ->> SDK: sdkclient.create_clients_from(configuration)
API ->> SDK: network_client = clients.get("network")
API ->> SDK: sdkclient.create_adapters_from(configuration)
API ->> SDK: network_client = adapters.get("network")
SDK ->> SDK: SDK initialized and ready to be used
note over AP,API: Platform ready to receive CAMARA calls
AP ->> API: POST /sessions (QOS_SESSION_REQUEST)
@@ -144,10 +168,10 @@ NEF ->> 5GS: QoS session creation
```
---

## Roadmap
## Roadmap for Open SDK 2nd release

- [ ] Add support to GSMA OPG.02 TFs (WIP)
- [ ] Include JUNIPER O-RAN adapter (WIP)
- [ ] Add support to GSMA OPG.02 TFs
- [ ] Include JUNIPER O-RAN adapter

---

+3 −3
Original line number Diff line number Diff line
@@ -10,9 +10,9 @@ To contribute:

1. Fork the repository and create a feature branch from `main`.
2. Develop your changes in the appropriate adapter directory:
   - `src/sunrise6g_opensdk/edgecloud/clients/`
   - `src/sunrise6g_opensdk/network/clients/`
   - `src/sunrise6g_opensdk/oran/clients/`
   - `src/sunrise6g_opensdk/edgecloud/adapters/`
   - `src/sunrise6g_opensdk/network/adapters/`
   - `src/sunrise6g_opensdk/oran/adapters/`
3. Follow the coding guidelines below.
4. Write or update unit tests for your changes.
5. Ensure all tests pass.
+1 −1
Original line number Diff line number Diff line
@@ -14,7 +14,7 @@ To run tests for the Edge Cloud adapters:
pytest tests/edgecloud/
```

To run tests for the Network adapters (WIP):
To run tests for the Network adapters:
```bash
pytest tests/network/
```
+0 −26
Original line number Diff line number Diff line
```mermaid
sequenceDiagram
title Retrieve Edge Cloud Zones
actor AP as App Vertical Provider
participant CE as Capabilities Exposure
box Service Resource Manager
    participant API
    participant SDK as EdgeCloudSDK
end
participant i2Edge
participant PiEdge
participant aerOS

note over AP,CE: CAMARA EdgeCloud API
AP ->> CE: GET /edge-cloud-zones
CE ->> API: GET /av. zones
API ->> SDK: sbi = EdgeCloudFactory.create_edgecloud_client(i2Edge)
API ->> SDK: sbi.get_edge_cloud_zones()
SDK ->> i2Edge: GET /zones/list
API ->> SDK: sbi = EdgeCloudFactory.create_edgecloud_client(PiEdge)
API ->> SDK: sbi.get_edge_cloud_zones()
SDK ->> PiEdge: GET /nodes
API ->> SDK: sbi = EdgeCloudFactory.create_edgecloud_client(aerOS)
API ->> SDK: sbi.get_edge_cloud_zones()
SDK ->> aerOS: GET /entities?type=Domain
```
+5 −5
Original line number Diff line number Diff line
@@ -4,9 +4,9 @@ from sunrise6g_opensdk.common.sdk import Sdk as sdkclient # For developers

def main():
    # The module that imports the SDK package, must specify which adapters will be used:
    client_specs = {
    adapter_specs = {
        "edgecloud": {
            "client_name": "i2edge",
            "client_name": "kubernetes",
            "base_url": "http://IP:PORT",
        },
        "network": {
@@ -16,9 +16,9 @@ def main():
        },
    }

    clients = sdkclient.create_clients_from(client_specs)
    edgecloud_client = clients.get("edgecloud")
    network_client = clients.get("network")
    adapters = sdkclient.create_adapters_from(adapter_specs)
    edgecloud_client = adapters.get("edgecloud")
    network_client = adapters.get("network")

    print("EdgeCloud client ready to be used:", edgecloud_client)
    print("Network client ready to be used:", network_client)
Loading