Skip to content

Commit

Permalink
Merge pull request #1009 from eclipse-tractusx/chore/update-irs-opera…
Browse files Browse the repository at this point in the history
…tion-view

chore: update data chain kit operation view to latest irs version
  • Loading branch information
ds-jhartmann authored Aug 2, 2024
2 parents a8b6c74 + 5cd286e commit 2e8065f
Showing 1 changed file with 27 additions and 40 deletions.
67 changes: 27 additions & 40 deletions docs-kits/kits/Data Chain Kit/page_software-operation-view.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,41 +11,20 @@ sidebar_position: 2

## Local deployment of IRS with minimum dependencies setup

> **Please note that this demo is currently based on IRS version 4.5.0**
> **Please note that this demo is currently based on IRS version 5.4.0**
### Step 1: Prerequisites

1. [Docker](https://docs.docker.com/get-docker/) is installed and the Docker deamon is running with at least 8GB of memory
1. [Docker](https://docs.docker.com/get-docker/) is installed and the Docker deamon is running with at least 8GB of
memory
2. [helm](https://helm.sh/docs/intro/install/) is installed
3. Any Kubernetes cluster is installed and running, eg. [Minikube](https://minikube.sigs.k8s.io/docs/start/)
4. [kubectl](https://kubernetes.io/docs/tasks/tools/) is installed

### Step 2: Update and build the irs-helm chart
### Step 2: Add the IRS helm repository

```bash
>$ helm dependency build
```

You should see console output with messages like below:

```bash
Hang tight while we grab the latest from your chart repositories...
...Successfully got an update from the "irs" chart repository
...Successfully got an update from the "tractusx-dev" chart repository
...Successfully got an update from the "prometheus-community" chart repository
Update Complete. ⎈Happy Helming!
Saving 1 charts
Downloading irs-helm from repo https://eclipse-tractusx.github.io/item-relationship-service
Deleting outdated charts
```
Please note that irs repository has to be added to helm repo list
```bash
>$ helm repo add irs https://eclipse-tractusx.github.io/item-relationship-service
>$ helm repo list
NAME URL
irs https://eclipse-tractusx.github.io/item-relationship-service
helm repo add irs https://eclipse-tractusx.github.io/item-relationship-service
```

### Step 3: Installing the IRS
Expand All @@ -55,35 +34,41 @@ irs https://eclipse-tractusx.github.io/item-relationship-ser
To deploy IRS on kubernetes with helm run

```bash
>$ helm install irs-local .
helm install irs-local irs/item-relationship-service -f your-values.yaml
```

##### 1.1 Get the Status of the deployment

Helm can give you feedback on the release status:

```bash
>$ helm list
NAME NAMESPACE REVISION UPDATED STATUS CHART APP VERSION
irs-local default 1 2024-02-26 11:36:46.399546 +0100 CET deployed irs-helm-local-6.14.0 4.5.0
helm list
```

```bash
NAME NAMESPACE REVISION UPDATED STATUS CHART APP VERSION
irs-local default 1 2024-08-01 10:24:46.8811785 +0200 CEST deployed item-relationship-service-7.4.0 5.4.0
```

Kubectl can give you feedback on how the status of the deployment currently is, there should be two pods deployed - IRS and Minio:
Kubectl can give you feedback on how the status of the deployment currently is, there should be two pods deployed - IRS
and Minio:

```bash
>$ kubectl get pods
NAME READY STATUS RESTARTS AGE
irs-local-minio-7cc78d8985-qggrx 1/1 Running 0 10m
irs-local-irs-helm-c84f98ffb-zg59z 1/1 Running 0 10m
kubectl get pods
```

```bash
NAME READY STATUS RESTARTS AGE
irs-local-item-relationship-service-5bdcd5854d-gq976 1/1 Running 0 47s
irs-local-minio-6f6c58cfbd-j8jkg 1/1 Running 0 47s
```

#### 2. Forward Ports

When the deployment has been finished please use the command to forward the port:

```bash
>$ kubectl port-forward svc/irs-local-irs-helm 8080:8080
kubectl port-forward svc/irs-local-item-relationship-service 8080:8080
```

After that you can access the Swagger UI page:
Expand All @@ -92,11 +77,14 @@ After that you can access the Swagger UI page:

## Testing the Item Relationship Service

You can use any approach to access exposed by IRS API endpoints, for example mentioned above Swagger UI page. There is also prepared Insomnia collection with example calls to IRS, see [IRS_Request_Collection.json](../../testing/IRS_Request_Collection.json)
You can use any approach to access exposed by IRS API endpoints, for example mentioned above Swagger UI page. There is
also prepared Insomnia collection with example calls to IRS,
see [IRS_Request_Collection.json](https://github.com/eclipse-tractusx/item-relationship-service/blob/5.4.0/local/testing/request-collection/IRS_Request_Collection.json)

### Valid Global Asset Ids for testing

IRS is loading with mocked data from Testdata file, see [CX_Testdata.json](../../../irs-models/src/main/resources/test_data/CX_Testdata.json)
IRS is loading with mocked data from Testdata file,
see [CX_Testdata.json](https://github.com/eclipse-tractusx/item-relationship-service/blob/5.4.0/irs-models/src/main/resources/test_data/CX_Testdata.json)

### Valid test requests for testing

Expand All @@ -105,7 +93,6 @@ You can use these snippets for testing purposes.
```json
{
"bomLifecycle": "asBuilt",
"lookupBPNs": true,
"direction": "downward",
"depth": 10,
"auditContractNegotiation": false,
Expand All @@ -119,7 +106,7 @@ You can use these snippets for testing purposes.
```json
{
"aspects": [
"SerialPart"
"urn:samm:io.catenax.serial_part:3.0.0#SerialPart"
],
"depth": 1,
"key": {
Expand Down

0 comments on commit 2e8065f

Please sign in to comment.