Giter Site home page Giter Site logo

datadashboard's Introduction

EDC Data Dashboard

Please note: This repository does not contain production-grade code and is only intended for demonstration purposes.

EDC Data Dashboard is a dev frontend application for EDC Management API.

Documentation

Developer documentation can be found under docs/developer, where the main concepts and decisions are captured as decision records.

Running the frontend locally

Should you want to run the frontend on your development machine, you'll have to configure some backend values. Those are stored in app.config.json, and by default contain the following:

{
  "managementApiUrl": "{{managementApiUrl}}",
  "catalogUrl": "{{catalogUrl}}",
  "storageAccount": "{{account}}",
  "storageExplorerLinkTemplate": "storageexplorer://v=1&accountid=/subscriptions/{{subscriptionId}}/resourceGroups/{{resourceGroup}}/providers/Microsoft.Storage/storageAccounts/{{account}}&subscriptionid={{subscriptionId}}&resourcetype=Azure.BlobContainer&resourcename={{container}}",
}

Substitute the values as necessary:

  • apiKey: enter here what your EDC instance expects in th x-api-key header
  • catalogUrl: prepend your connector URL, e.g. http://localhost, assuming your catalog endpoint is exposed at port 8181, which is the default
  • managementApiUrl: prepend your connector URL, e.g. http://localhost, assuming your IDS endpoint is exposed at port 9191
  • storageAccount: insert the name of an Azure Blob Storage account to which the connector has access, otherwise data transfers won't work.

Be extra careful NOT to commit those changes, as they might leak potentially sensitive information!!!

As some extra safety consider running git udpate-index --assume-unchanged src/assets/config/app.config.json before changing this file.

Running a frondend and two connectors locally (for demo purpose)

To test the correct functionality locally you can spin up a local docker compose that will load two data-dashboards service and two connectors, one for consumer and one for provider.

Just start the docker compose.

docker compose up

Consumer data-dashboard will be available at http://localhost:18080 Provider data-dashboard will be available at http://localhost:28080

Running DataDashboard from the host machine (for debugging purpose)

To have a quicker development cycle, you can also run the DataDashboard from the host machine using npm start, sending request against the connector loaded by docker compose. First you need to change the app.config.json this way:

{
  ...
  "managementApiUrl": "http://localhost:4200/management",
  "catalogUrl": "http://localhost:4200/management",
  ...
}

Then start the local DataDashboard:

npm start

The DataDashboard will be available at http://localhost:4200

Deploy to Azure

Create a resource group and container registry:

export RESOURCE_GROUP=edc-data-dashboard
export ACR_NAME=edcdatadashboard
az group create --resource-group $RESOURCE_GROUP --location westeurope -o none
az acr create --resource-group $RESOURCE_GROUP --name $ACR_NAME --sku Standard --location westeurope --admin-enabled -o none

Dockerize the application and push it to the registry by running:

az acr build --registry $ACR_NAME --image edc-showcase/edc-data-dashboard:latest .

The docker image is now ready to be deployed to Azure Container Instances (ACI). The app.config.json file contains configuration which is fetched by the application at startup. This file can be overridden at deployment time by mounting a secret on assets/config. For each deployment you need to provide the corresponding connector backend URL, the storage account name and the API key using this secret. Deploy to ACI using the following command:

export CONNECTOR_DATA_URL=<CONNECTOR_DATA_URL>
export CONNECTOR_CATALOG_URL=<CONNECTOR_CATALOG_URL>
export STORAGE_ACCOUNT=<STORAGE_ACCOUNT>
export API_KEY=<API_KEY>

# deploy to ACI (when prompted for credentials use the username/password as available in Azure Portal: ACR->Access Keys)
az container create --image ${ACR_NAME}.azurecr.io/edc-showcase/edc-data-dashboard:latest \
--resource-group $RESOURCE_GROUP \
--name edc-data-dashboard \
--secrets "app.config.json"="{\"managementApiUrl\": \"$CONNECTOR_DATA_URL\", \"catalogUrl\": \"$CONNECTOR_CATALOG_URL\", \"storageAccount\": \"$STORAGE_ACCOUNT\", \"apiKey\": \"$API_KEY\"}" \
--secrets-mount-path /usr/share/nginx/html/assets/config \
--dns-name-label edc-data-dashboard

Contributing

See how to contribute for details.

datadashboard's People

Contributors

algattik avatar brunopacheco1 avatar chrislomonico avatar dependabot[bot] avatar edwo-dev avatar farhin23 avatar idoiamurua avatar izzzu avatar janpmeyer avatar jimmarino avatar juliapampus avatar konfr avatar michaelsteinert avatar ndr-brt avatar olfabensoussia avatar paullatzelsperger avatar ronjaquensel avatar tygross025 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

datadashboard's Issues

connector client: switch `ContractAgreementService`

Feature Request

Use the EDC-connector-client in the ContractAgreementService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

Add flexibility to modify the base-href of DataDashboard app

Feature Request

Add flexibility to modify the base-href of the application according to need. Define the base href of choice at the time of image creation.

Which Areas Would Be Affected?

the Dockerfile and app-config.service.ts file

Why Is the Feature Desired?

When we try to deploy the edc-datadashboard to a Kubernetes cluster and implement an ingress route to access the service, it encounters the following issue:
The index file loads correctly but, it cannot load the asset files (css, js, images) properly. As a result, the angular app cannot be loaded properly, and the browser shows a blank page.

For example, in the following ingress file we have defined the ingress route /company-dashboard/ for our dashboard application.

image

Now, if we try to access the application from our browser (for instance, at "http://localhost/company-dashboard/"), then it encounters the above-mentioned problem.

This happens because we are accessing our application from a non-root path ('/company-dashboard/'), but the angular application is trying to load the assets from the root path ('/').
This can easily be solved by modifying the base-href in index.html file. If we change the <base href="/"> to <base href="/company-dashboard/">, the application will use this path to load the script files.

However, directly modifying the index.html file is not a good option as it compromises our flexibility for defining the paths.

Solution Proposal

One solution for this is to include the following command in the Dockerfile.

RUN npm run build -- --base-href=$BASE_PATH

We can take the $BASE_PATH as input during image creation. It will change the <base href=…> of the application according to our choice.

Also, when trying to fetch any asset from within the code, the URL to the asset should be adapted accordingly.
For example, in app-config.service.ts file we are using the url 'assets/config/app.config.json' to get the config files.

return this.http
      .get<AppConfig>('/assets/config/app.config.json')
      .toPromise()
      .then(data => {
      ....

In case, we are using a base-href different than root (‘/’) then this will fail to get the files. We can modify this and prepare the url by adding the base-href with it. We can utilize Angular LocationStrategy, prepareExternalUrl in this scenario.

return this.http
      .get<AppConfig>(this.locationStrategy.prepareExternalUrl('assets/config/app.config.json'))
      .toPromise()
      .then(data => {
      ....

connector client: switch `PolicyService`

Feature Request

Use the EDC-connector-client in the PolicyService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

EDC-management: "Bad Request" when creating a "policy"

Bug Report

Describe the Bug

Policy can not be created.
'Bad Request' error is thrown.

Expected Behavior

Policy is created.

Observed Behavior

  1. Throws error message
  2. Does not create policy

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Policies'
  2. Click on 'Create policy'
  3. Insert id
  4. Click 'Save'
  5. See error

Context Information

  • Used version
    • [DataDashboard https://github.com/eclipse-edc/DataDashboard/commit/550f6d0b557bf76b5ab7cf665d6c1a98cb156186]
    • [EDC v0.2.0]
  • OS: [Windows/CentOS7]

Error Information

zone.js:2680 POST http://localhost:9192/api/management/v2/policydefinitions 400 (Bad Request)

Detailed Description

Request payload:

{
    "policy": {
        "@type": "SET"
    },
    "id": "test"
}

Response:

{
  "servlet":"EDC-management",
  "message":"Bad Request",
  "url":"/api/management/v2/policydefinitions",
  "status":"400"
}

Negotiation process does not start

Bug Report

Describe the Bug

The negotiation process does not start because the initiateContractNegotiation function of the ContractNegotiationService is not recognised.

Expected Behavior

Start the negotiation process.

Observed Behavior

I get the error this.negotiationService.initiateContractNegotiation is not a function.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Catalog browser'
  2. Click on 'Negotiate'
  3. See error

Context Information

  • Used version [EDC v0.7.0, EDC Client v0.4.0]
  • OS: [Windows]

Detailed Description

This is the error I get when I click the ‘Negotiate’ button.

UIError

CatalogBrowser: check on init whether agreement exists

The CatalogBrowserComponent should check during initialization whether a contract exists for each offer and act as follows:

  • if exists:
    • re-label the button to "Re-Negotiate"
    • add a link to navigate to the agreements page
  • if not exists keep as is

Dead links

Bug Report

Describe the Bug

There are dead links on the page /introduction:

  • Onboarding Guide
  • Data Management API

Context Information

Version: main c3ec34f

EDC-management: "Bad Request" when creating a "contract definition"

Bug Report

Describe the Bug

'Contract Definition' can not be created.
'Bad Request' error is thrown.

Expected Behavior

Contract definition is created.

Observed Behavior

Throws error message.
Does not create contract definition.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Contract Definitions'
  2. Click on 'Create contract definition'
  3. Insert id
  4. Select Access policy
  5. Select Contract policy
  6. Select Assets
  7. Click 'Create'
  8. See error

Context Information

  • Used version
    • [DataDashboard https://github.com/eclipse-edc/DataDashboard/commit/550f6d0b557bf76b5ab7cf665d6c1a98cb156186]
    • [EDC v0.2.0]
  • OS: [Windows/CentOS7]

Error Information

zone.js:2680 POST http://localhost:9191/api/management/v2/contractdefinitions 400 (Bad Request)

create_contract_definition_error

Detailed Description

Request:

{
    "id": "def-test-pdf_company1",
    "criteria": [
        {
            "edc:operandLeft": "asset:prop:id",
            "edc:operator": "in",
            "edc:operandRight": [
                "test-pdf_company1"
            ]
        }
    ],
    "accessPolicyId": "no-restriction-policy",
    "contractPolicyId": "no-restriction-policy"
}

Response:

{
    "servlet": "EDC-management",
    "message": "Bad Request",
    "url": "/api/management/v2/contractdefinitions",
    "status": "400"
}

Run Locally without the Cloud

Feature Request

The DataDashboard should be useable with different storage types, especially locally with the file system and without any cloud connectivity like Azure or AWS.

Which Areas Would Be Affected?

The connection to the data plane and the storage types.

Why Is the Feature Desired?

The current version of the README shows a part "Running the frontend locally." When reading further, the storageAccount must be set:

insert the name of an Azure Blob Storage account to which the connector has access, otherwise data transfers won't work.

In the source code, only AzureStorage and AmazonS3 are hard-coded storage types without possibility to run with the filesystem storage:

useFactory: () => [{id: "AzureStorage", name: "AzureStorage"}, {id: "AmazonS3", name: "AmazonS3"}],

Solution Proposal

Being able to use the DataDashboard locally with the filesystem as storage type.

connector client: switch `ApplicationObservabilityService`

Feature Request

Use the EDC-connector-client in the ApplicationObservabilityService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

EDC-management: "Unauthorized" when fetching "Contract Definitions"

Bug Report

Describe the Bug

Contract definitions can not be fetched.
HTTP Error 401 is thrown (Unauthorized).

Expected Behavior

Contract Definitions are fetched and list of items is shown.

Observed Behavior

  1. Throws error message
  2. Does not fetch and show items

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Contract Definitions'
  2. See error

Context Information

  • Used version
    • [DataDashboard https://github.com/eclipse-edc/DataDashboard/commit/dc4f57d3492706d39a6f7f663e706a52ca073efb]
    • [EDC v0.2.0]
  • OS: [Windows/CentOS7]

Error Information

ContractDefinitionsError

Detailed Description

Response:

[
    {
        "message": "Request could not be authenticated",
        "type": "AuthenticationFailed",
        "path": null,
        "invalidValue": null
    }
]

API Key in app.config.json ignored

Bug Report

Describe the Bug

The API Key configured in app.config.json seems to be ignored and is instead taken exclusively from the environment config (e.g. environment.prod.ts).

Expected Behavior

API Key configured in app.config.json is used by the frontend.

Observed Behavior

API Key from the environment config (e.g. environment.prod.ts) is used, even if there is a different value configured in app.config.json.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Configure an API key in app.config.json that is different from the one in the environment config
  2. Run the application
  3. Observe the headers sent with any request
  4. See that the value of the "X-Api-Key" header contains the API key configured in the environment config.

Context Information

There is an existing "TODO" in the code at line 83 of app.module.ts, but I haven't found a corresponding issue.

Possible Implementation

The value in the environment file could be taken as a default, overwritten by the app config if it is configured there.

Fix spacing between elements

Bug Report

This is not exactly a bug or feature, but rather a small enhancement to the UIs.

A clear and concise description of the bug.

Expected Behavior

To have proper and symmetrical symmetry between displayed elements

Observed Behavior

The gap between UI elements isn't always the same and some upper margin is missing.

Steps to Reproduce

I noticed this in the policies, assets, catalog, and transfer process views.

Context Information

Add any other context about the problem here.

  • Used version [e.g. EDC v1.0.0]
  • OS: [e.g. iOS, Windows]
  • ...

Detailed Description

If applicable, add screenshots and logs to help explain your problem.

Possible Implementation

You already know the root cause of the erroneous state and how to fix it? Feel free to share your thoughts.

EDC-management: "Unauthorized" when fetching assets

Bug Report

Describe the Bug

Assests can not be fetched.
HTTP Error 401 is thrown (Unauthorized).

Expected Behavior

Assets are fetched and list of assets is shown.

Observed Behavior

  1. Throws error message
  2. Does not fetch and show assets

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Assets'
  2. See error

Context Information

  • Used version
    • [DataDashboard https://github.com/eclipse-edc/DataDashboard/commit/550f6d0b557bf76b5ab7cf665d6c1a98cb156186]
    • [EDC v0.2.0]
  • OS: [Windows/CentOS7]

Error Information

Assets_Error

Detailed Description

Response:

[
    {
        "message": "Request could not be authenticated",
        "type": "AuthenticationFailed",
        "path": null,
        "invalidValue": null
    }
]

Name property being used in asset deletion dialog

Bug Report

The name property in asset is being used in the deletion dialog and is optional, which could result in unexpected behaviors.
A clear and concise description of the bug.

Expected Behavior

An informative and clear alert when the user is about to delete an asset.

Observed Behavior

We get "undefined in the dialog" as shown in the attached screenshot.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to '/my-assets'
  2. Create an asset without a name
  3. Try to delete the asset

Context Information

Add any other context about the problem here.

  • Used version [e.g. EDC v1.0.0]
  • OS: [e.g. iOS, Windows]
  • ...

Detailed Description

368570650_311606641331146_5743845719701442051_n

Possible Implementation

Using the asset ID instead of name, because we always have an ID. As far as my knowledge goes, the connector will generate one in case it's not specified.

Incompatible with v2 management endpoints

Bug Report

Describe the Bug

As of v0.1.0 of the EDC Connector the v1 management api endpoints were removed. The DataDashboard relies on the removed endpoins and is thus not compatible with the newest versions of the connector.

Expected Behavior

DataDashboard should function the same with newer versions of EDC as before.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Start DataDashboard with a EDC connector version >=v0.1.0
  2. Observe that DataDashboard cannot retrieve information from management api

Context Information

  • Used EDC Connector v0.1.2 from the eclipse-edc/MinimumViableDataspace repository

Possible Implementation

Many of the possible depreciated endpoints used are marked as depreciated in openapi/management-api.yaml

Data Transfer Failed on Local Development

Bug Report

Data Transfer error after contract negotiation

Post request to data transfer doesn't work in the local development setup. Produces error net::ERR_INTERNET_DISCONNECTED

Expected Behavior

Once clicked, the transfer button should create an azure blob container containing the transferred data.

Observed Behavior

  1. Submits infinite post request to (HTTP://localhost:9192/api/v1/data/transferprocess/{transferId})
  2. Throws net:: Err_INTERNET_DISCONNECTED Error
  3. Does create an Azure Blob Container but post request doesn't work

Steps to Reproduce

Steps to reproduce the behavior:

  1. Negotiate Contract
  2. Click on Transfer
  3. See the error

Error Information

`
zone.js:2680 GET http://localhost:9192/api/v1/data/transferprocess/{id} net::ERR_INTERNET_DISCONNECTED

  q @ zone.js:2680
  scheduleTask @ zone.js:393
  onScheduleTask @ zone.js:283
  scheduleTask @ zone.js:386
  scheduleTask @ zone.js:221
  scheduleMacroTask @ zone.js:244
  Me @ zone.js:683
  (anonymous) @ zone.js:2713
  o. @ zone.js:973
  (anonymous) @ http.mjs:1915
  _trySubscribe @ Observable.js:37
  (anonymous) @ Observable.js:31
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  _ @ mergeInternals.js:19
  p @ mergeInternals.js:14
  _next @ OperatorSubscriber.js:13
  next @ Subscriber.js:31
  (anonymous) @ innerFrom.js:51
  _trySubscribe @ Observable.js:37
  (anonymous) @ Observable.js:31
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  wR @ mergeInternals.js:50
  (anonymous) @ mergeMap.js:13
  (anonymous) @ lift.js:10
  (anonymous) @ Observable.js:26
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  (anonymous) @ filter.js:6
  (anonymous) @ lift.js:10
  (anonymous) @ Observable.js:26
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  (anonymous) @ map.js:6
  (anonymous) @ lift.js:10
  (anonymous) @ Observable.js:26
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  e.subscribe.o @ switchMap.js:14
  _next @ OperatorSubscriber.js:13
  next @ Subscriber.js:31
  (anonymous) @ innerFrom.js:51
  _trySubscribe @ Observable.js:37
  (anonymous) @ Observable.js:31
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  (anonymous) @ switchMap.js:10
  (anonymous) @ lift.js:10
  (anonymous) @ Observable.js:26
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  (anonymous) @ filter.js:6
  (anonymous) @ lift.js:10
  (anonymous) @ Observable.js:26
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  (anonymous) @ tap.js:15
  (anonymous) @ lift.js:10
  (anonymous) @ Observable.js:26
  sc @ errorContext.js:19
  subscribe @ Observable.js:22
  (anonymous) @ contract-viewer.component.ts:162
  L. @ zone.js:2378
  invokeTask @ zone.js:406
  onInvokeTask @ core.mjs:25579
  invokeTask @ zone.js:405
  runTask @ zone.js:178
  invokeTask @ zone.js:487
  invoke @ zone.js:476
  m.args. @ zone.js:2358

`

  • Used version [e.g. DataDashboard v1.0.0]
  • OS: [Mac]

Detailed Description

Screen Shot 2022-10-09 at 2 50 49 PM
Screen Shot 2022-10-09 at 2 51 25 PM

Policy IDs are not displayed

Bug Report

Describe the Bug

The IDs of policy definitions are not displayed in the UI. Under Policies, the header of the cards for existing policies is empty, whereas for Assets and Contract Definitions the ID appears there. The policy IDs are also missing when creating a new contract definition. The dropdown menu for choosing a policy appears, but all entries are empty.

Expected Behavior

Policy IDs are displayed correctly.

Observed Behavior

Policy IDs are not displayed at all.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Run the MVD
  2. Open dashboard of any of the three connectors
  3. Go to Policies and see empty card header as shown in the first screenshot below
  4. Alternatively, go to Contract Definitions
  5. Click Create contract definition
  6. Click on the field for Access Policy or Contract Policy and see empty dropdown as shown in the second screenshot below.

Context Information

  • Used versions: current main branch of MVD and Dashboard (2022-10-21)

Detailed Description

Policies overview:
grafik

Creating new contract definition:
grafik

Possible Implementation

The issue might be caused by a mismatch of the ID properties in the policy classes. The PolicyDefinition in the dashboard has a field called uid, while the PolicyDefinition and PolicyDefinitionResponseDto in the connector have a field called id.

Wrong error message in assets and policies views

Bug Report

When an entity creation fails, a wrong error message is shown.

Expected Behavior

A self-descriptive error for each operation on assets

Observed Behavior

When trying to create an asset or a policy with the wrong DTO or if there is an issue with the called API, we get an error message stating "This asset cannot be deleted" ("This policy cannot be deleted" for the case of policy)

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to '/my-assets'
  2. Click on 'create asset' button
  3. Fill the dialog with (wrong) informations
  4. See error message

Possible Implementation

You already know the root cause of the erroneous state and how to fix it? Feel free to share your thoughts.

Configure the name of the participant EDC Demo in UI

Feature Request

Configure the name of the participant EDC Demo

image

Which Areas Would Be Affected?

  • User Interface have to print out the Title
  • configuration for each of the participents in MVD

Why Is the Feature Desired?

During the debugging its helpful to see the participant's name. In the local development environment, the developer see differ the ports

Solution Proposal

Add a new property name to app.config.json in repo DataDashboard

Configure the 3 participents in repo MinimumViableDataspace in participants.json

{
  "include": [
    {
      "participant": "company1",
      "region": "eu",
      "country": "FR",
      "data_dashboard_theme": "theme-1",
      "name":"Company 1"
    },
    {
      "participant": "company2",
      "region": "eu",
      "country": "DE",
      "data_dashboard_theme": "theme-2",
      "name":"Company 2"
    },
    {
      "participant": "company3",
      "region": "us",
      "country": "US",
      "data_dashboard_theme": "theme-3",
      "name":"Company 3"
    }
  ]
}

Type of Issue

new feature

Checklist

  • assigned appropriate label?
  • Do NOT select a milestone or an assignee!

EDC-management: "Bad Request" when creating an asset

Bug Report

Describe the Bug

Asset can not be created. 'Bad Request' error is thrown.
Inserted information is valid and blob file exists.

Expected Behavior

  1. Creates asset

Observed Behavior

  1. Throws error message
  2. Does not create asset

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Assets'
  2. Click on 'Create asset'
  3. Insert asset information
  4. Click 'create'
  5. See error

Context Information

  • Used version [DataDashboard 2023-18-08]
  • OS: [Windows/CentOS7]

Error Information

zone.js:2680 POST http://localhost:9191/api/management/v3/assets 400 (Bad Request)

{ "headers": { "normalizedNames": {}, "lazyUpdate": null }, "status": 400, "statusText": "Bad Request", "url": "http://localhost:9191/api/management/v3/assets", "ok": false, "name": "HttpErrorResponse", "message": "Http failure response for http://localhost:9191/api/management/v3/assets: 400 Bad Request", "error": { "servlet": "EDC-management", "message": "Bad Request", "url": "/api/management/v3/assets", "status": "400" } }

Detailed Description

error-1 error-2

connector client: switch `CatalogService`

Feature Request

Use connector client in CatalogService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

Bump connector-client to `0.2.0-beta-3`

Feature Request

If you are missing a feature or have an idea how to improve this project that should first be discussed, please feel
free to open up a discussion.

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

Dashboard can not fetch data offers from federated catalog

Bug Report

Describe the Bug

No data offers can be fetched from the federated catalog.

Expected Behavior

All data offers from the federated catalogue should be fetched.

Observed Behavior

The tab "Catalog Browser" remains without data offers.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Run MVD with current EDC
  2. Click on tab "Catalog Browser"

Context Information

  • Used version: EDC v0.2.1
  • OS: Linux

Detailed Description

datadashboard

Possible Implementation

the called end point does not exist. The undefineid must be removed from the URL

Assets can not be shown

Bug Report

Describe the Bug

List of assets can not be shown.

Expected Behavior

Asset items are listed as expected.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Assests'
  2. See error

Context Information

  • Used version
    • [DataDashboard https://github.com/eclipse-edc/DataDashboard/commit/6ded7040896244628c3b52301bf7204d89631051]
    • [EDC v0.2.0]
  • OS: [Windows/CentOS7]

Error Information

assets_error

Detailed Description

core.mjs:6485 ERROR TypeError: Cannot read properties of undefined (reading 'edc:id')

Response:

[
    {
        "@id": "test-document-2_company1",
        "@type": "edc:Asset",
        "edc:properties": {
            "edc:version": "1.0",
            "edc:type": "AzureStorage",
            "edc:name": "test-document-2_company1",
            "edc:id": "test-document-2_company1",
            "edc:contenttype": "text/plain"
        },
        "edc:dataAddress": {
            "@type": "edc:DataAddress",
            "edc:container": "src-container",
            "edc:type": "AzureStorage",
            "edc:blobname": "text-document-2.txt",
            "edc:account": "company1assets",
            "edc:keyName": "company1assets-key1"
        },
        "@context": {
            "dct": "https://purl.org/dc/terms/",
            "edc": "https://w3id.org/edc/v0.0.1/ns/",
            "dcat": "https://www.w3.org/ns/dcat/",
            "odrl": "http://www.w3.org/ns/odrl/2/",
            "dspace": "https://w3id.org/dspace/v0.8/"
        }
    },
    {
        "@id": "test-document_company1",
        "@type": "edc:Asset",
        "edc:properties": {
            "edc:version": "1.0",
            "edc:type": "AzureStorage",
            "edc:name": "test-document_company1",
            "edc:id": "test-document_company1",
            "edc:contenttype": "text/plain"
        },
        "edc:dataAddress": {
            "@type": "edc:DataAddress",
            "edc:container": "src-container",
            "edc:type": "AzureStorage",
            "edc:blobname": "text-document.txt",
            "edc:account": "company1assets",
            "edc:keyName": "company1assets-key1"
        },
        "@context": {
            "dct": "https://purl.org/dc/terms/",
            "edc": "https://w3id.org/edc/v0.0.1/ns/",
            "dcat": "https://www.w3.org/ns/dcat/",
            "odrl": "http://www.w3.org/ns/odrl/2/",
            "dspace": "https://w3id.org/dspace/v0.8/"
        }
    }
]

Cypress tests do not visit intended URL because of wrong URL syntax

Bug Report

Describe the Bug

In spec.cy.js file the cypress tests aims to visit two URLs - consumerUrl and providerUrl. These two URLs are configured in cypress.config.ts file as,

...
e2e: {
    baseUrl: 'http://localhost:18080',
    ...
  },
  env: {
    consumerUrl: 'http//localhost:18080',
    providerUrl: 'http//localhost:28080',
  },
...

The consumerUrl and providerUrl do not conform to the syntax of a generic URI. According to the generic syntax the scheme name is followed by a colon (:). This is missing in both of these two URLs, as there is no following colon (:) after http.

This configuration file cypress.config.ts, also defines a baseUrl. This baseUrl is used as prefix for every cy.visit() command's URL. If we want to visit a different host than the baseUrl, then we have to provide a fully qualified URL of the path we want to visit.

As the two URLs - consumerUrl and providerUrl, divert from the generic syntax, cypress can not recognize them as fully qualified URLs. Therefore, at the time of execution it appends these two URLs with the baseUrl, and ends up visiting the paths: http://localhost:18080/http//localhost:18080 and http://localhost:18080/http//localhost:28080

Expected Behavior

The cy.visit(consumerUrl) and cy.visit(providerUrl) commands should visit the URLs 'http://localhost:18080' and 'http://localhost:28080' correspondingly.

Observed Behavior

cy.visit(consumerUrl) and cy.visit(providerUrl) commands try to visit the paths: http://localhost:18080/http//localhost:18080 and http://localhost:18080/http//localhost:28080 correspondingly. Although these paths do not exist, cypress redirects them to the host path(the baseUrl), and thus the cy.visit() tests pass.

Although both of these tests pass, it is not testing what we wanted to. For example, in the second test, we intend to visit the providerUrl:http//localhost:28080, but the test redirects it to the baseUrl:http//localhost:18080 which is basically the consumerUrl. And ends up executing the rest of the tests on consumer data-dashboard.

  it('should create an asset and view it on provider side', function() {
    cy.visit(providerUrl);
    ....
  });

After the redirect occurs, the dashboard can not load the introduction page. However, it can load the menu bar and therefore the second test also pass.

Steps to Reproduce

Steps to reproduce the behavior:

  1. clone the DataDashboard project from https://github.com/eclipse-edc/DataDashboard/tree/main

  2. from the root folder, run npm install

  3. run docker compose up. This will make consumer data-dashboard available at http://localhost:18080 and provider data-dashboard available at http://localhost:28080

  4. run npx cypress open to open the cypress test runner. (We assume that cypress is already installed)

  5. On test runner, click on 'E2E Testing' -> 'Start E2E Testing in Electron' -> 'spec.cy.js'

  6. See that at the beginning of the test execution the navigation bar conatins the URL http://localhost:18080/http//localhost:18080 when running cy.visit(consumerUrl) and then http://localhost:18080/http//localhost:28080 when running cy.visit(providerUrl).
    cypress_bug_ss_1

Both of them are then redirected to http://localhost:18080

  1. Right click on the dashboard and select Inspect Element. In the Network tab see the Requested URL.
    cypress_bug_ss_2

  2. In the Console tab, see the Error: NG04002:... noMatchError. This is thrown when it can not match any routes.
    cypress_bug_ss_3

Context Information

  • Cypress version: 13.8.1
  • Node version: v18.20.2

Possible Implementation

Update the consumer and provider URLs in cypress.config.ts file with right syntax, and adjust any changes in the spec.cy.js file.

connector client: switch `TransferProcessService`

Feature Request

Use the EDC-connector-client in the TransferProcessService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

lastUpdated Column removed in previous commit by mistake

We found a bug in https://github.com/eclipse-edc/DataDashboard/blob/main/src/modules/edc-demo/components/transfer-history/transfer-history-viewer.component.html file. We think that the "lastUpdated" column was removed by mistake from the Transfer History page in a previous commit.
The missing column should be added as follows:

 <ng-container matColumnDef="lastUpdated">
            <th mat-header-cell matHeaderCellDef scope="col">Last updated</th>
            <td mat-cellmatCellDef="let item">{{asDate(item.stateTimestamp)}}</td>
 </ng-container> 

Otherwise, the Transfer History page of the DashBoard gives an error in the console.

Substitut app.config.json file with env-variables

Feature Request

Use env-variables instead of the app.conf.json, because Angular uses this variables on build time not runtime. So for a builded docker image their is no way to change the values. Like in Kubernetes.

Which Areas Would Be Affected?

Use of defined variables

Why Is the Feature Desired?

Use DataDashboard in k8.

Solution Proposal

Substitute config file with env-variables approach

Newly created 'Contract Definition' is not reflected in 'Catalog Browser'

Bug Report

Describe the Bug

When a new contract definiton is created on "Contract Definitions" page, it does not appear in the "Catalog Browser"

Expected Behavior

When a new contract definition is created it has to appear in the Catalog Browser.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'Contract Definitions'
  2. Click on 'Create contract definition'
  3. Insert required properties
  4. Click on 'Create'
  5. See new item in list
  6. Go to 'Catalog Browser'
  7. See missing contract

Context Information

Add any other context about the problem here.

  • Used version
    • [DataDashboard #8c178ad]
    • [EDC v0.2.0]
  • OS: [Windows/CentOS7]

Detailed Description

Contract-Definitions
Catalog-Browser (1)

feat: enable dependabot

Feature Request

Which Areas Would Be Affected?

Enable dependabot

Why Is the Feature Desired?

keep dependencies up-to-date

connector client: switch `ContractDefinitionService`

Feature Request

Use the EDC-connector-client in the ContractDefinitionService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

connector client: switch `AssetService`

Feature Request

Use the EDC-connector-client in the AssetService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

connector client: switch `DataplaneSelectorService`

Feature Request

Use the EDC-connector-client in the DataplaneSelectorService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

Missing Runtime Information

Bug Report

Describe the Bug

Currently, the documentation and the README lack essential information for deploying the Data Dashboard, including wrong commands, broken links, and spelling issues.

Expected Behavior

Some aspects currently missing the in the documentation:

  • Requirements section. What is required to run the Data Dashboard (like docker, docker compose, Azure, etc.)?
  • Compatible EDC version. Only by viewing the Commit history, it can be assumed with which version the dashboard is compatible.
  • Information for variables. Currently, it isn't described how to run the data dashboard with a catalog and management API URL on different ports. Therefore, everything seems to run on 8181 and 9191.

Observed Behavior

Besides the missing information, there are different issues like wrong commands, broken links, or spelling bugs, making it harder to deploy the product. Some examples:

  • Commands like git udpate-index --assume-unchanged src/assets/config/app.config.json don't work since it is git update-index instead of git udpate-index
  • Searching for specific words doesn't work. For example, the tool is sometimes called "frontend", sometimes "frondend"
  • Links like the how to contribute are causing a 404 error

Steps to Reproduce

Trying to deploy the Data Dashboard as described in the README.

Context Information

  • Used version: Current documentation and README of the main branch

connector client: switch `ContractNegotiationService`

Feature Request

Use the EDC-connector-client in the ContractNegotiationService

Which Areas Would Be Affected?

e.g., DPF, CI, build, transfer, etc.

Why Is the Feature Desired?

Are there any requirements?

Solution Proposal

If possible, provide a (brief!) solution proposal.

Transfer History does not react when list contains items

Bug Report

Describe the Bug

When the transfer history contains items, the gui does not react on user interaction e. g. the menu can not be opened.

Expected Behavior

GUI reacts as expected.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Transfer an asset successfully
  2. Go to 'Transfer History'
  3. Click on 'Menu'
  4. See error

Context Information

Add any other context about the problem here.

  • Used version
    • [DataDashboard https://github.com/eclipse-edc/DataDashboard/commit/550f6d0b557bf76b5ab7cf665d6c1a98cb156186]
    • [EDC v0.2.0]
  • OS: [Windows/CentOS7]

Error Information

transferhistory_error

Detailed Description

Response:

[
    {
        "@id": "d074d450-a2f3-4499-921e-0a83265e5b65",
        "@type": "edc:TransferProcess",
        "edc:correlationId": "d074d450-a2f3-4499-921e-0a83265e5b65",
        "edc:state": "COMPLETED",
        "edc:stateTimestamp": 1693495142794,
        "edc:type": "CONSUMER",
        "edc:assetId": "test-document_company1",
        "edc:contractId": "ZGVmLXRlc3QtZG9jdW1lbnRfY29tcGFueTE=:dGVzdC1kb2N1bWVudF9jb21wYW55MQ==:MzM4MGNjZjctMTg4YS00MDU5LTk0M2EtZTkxN2NmMzFhM2Nk",
        "edc:callbackAddresses": [],
        "edc:dataDestination": {
            "@type": "edc:DataAddress",
            "edc:container": "4630a7ac-2a4b-4b09-8cb6-dd5ee01707cb",
            "edc:type": "AzureStorage",
            "edc:account": "company2assets",
            "edc:keyName": "46709f3e-2d50-4d47-ac24-639830575955-container"
        },
        "edc:connectorId": "consumer",
        "@context": {
            "dct": "https://purl.org/dc/terms/",
            "edc": "https://w3id.org/edc/v0.0.1/ns/",
            "dcat": "https://www.w3.org/ns/dcat/",
            "odrl": "http://www.w3.org/ns/odrl/2/",
            "dspace": "https://w3id.org/dspace/v0.8/"
        }
    }
]

Possible Implementation

Look up .\src\modules\edc-demo\components\transfer-history\transfer-history-viewer.component.html

Row 40

 <td mat-cell *matCellDef="let item">{{item['edc:dataRequest']['edc:connectorId']}}</td>

Property edc:dataRequest does not exist.

After fixing:
transferhistory_success

Infinit progress bar loop in contract negotiation due to interrupted process

Bug Report

Describe the Bug

Infinit progress bar loop in contract negotiation. That is happening because the contract verification is abruptly terminated, due to policy inequality.

Expected Behavior

Once clicking in Negotiate, few seconds later the contract is agreed and it apears in Contracts.

Observed Behavior

When clicking in Negotiate, the loading bar never stops and every few seconds a request is triggered, but the process never finishes, so no contract is created.

Steps to Reproduce

Steps to reproduce the behavior:

  1. clone and setup eclipse-edc/MinimumViableDataspace and eclipse-edc/DataDashboard.
  2. Execute docker compose -f system-tests/docker-compose.yml up -d --build.
  3. Open Company 1 in the browser: http://localhost:7080/
  4. Go to http://localhost:7080/catalog-browser
  5. Click Negotiate for test-document-2_company3.
  6. See browser Network in developer console.
  7. See docker compose logs.

Context Information

  • eclipse-edc/MinimumViableDataspace at main branch
  • eclipse-edc/DataDashboard at main branch
  • Apple M2 14.3.1
  • Java 17 temurin

Detailed Description

Video screenshot:
https://github.com/eclipse-edc/DataDashboard/assets/4491850/d40f4979-7bc2-4c96-aaaa-4e2d8e833609

Logs:

company3  | DEBUG 2024-03-07T15:30:50.781713329 [PROVIDER] ContractNegotiation 4a5409d7-1959-4df5-be5b-8116ea4ef3c9 is now in state REQUESTED.
company3  | DEBUG 2024-03-07T15:30:51.523723204 [ProviderContractNegotiationManagerImpl] ContractNegotiation 4a5409d7-1959-4df5-be5b-8116ea4ef3c9 is now in state AGREEING
company3  | DEBUG 2024-03-07T15:30:51.524190412 ContractNegotiation: ID 4a5409d7-1959-4df5-be5b-8116ea4ef3c9. [Provider] send agreement
company3  | DEBUG 2024-03-07T15:30:51.554371287 ContractNegotiation: ID 4a5409d7-1959-4df5-be5b-8116ea4ef3c9. [Provider] send agreement
company3  | SEVERE 2024-03-07T15:30:51.557119079 ContractNegotiation: ID 4a5409d7-1959-4df5-be5b-8116ea4ef3c9. Fatal error while [Provider] send agreement. Error details: {"@type":"dspace:ContractNegotiationError","dspace:code":"400","dspace:reason":"Contract agreement received. Validation failed: Policy in the contract agreement is not equal to the one in the contract offer","dspace:processId":"6d5c90a2-df02-4b25-b0c8-71dc8de9e377","@context":{"dct":"https://purl.org/dc/terms/","edc":"https://w3id.org/edc/v0.0.1/ns/","dcat":"https://www.w3.org/ns/dcat/","odrl":"http://www.w3.org/ns/odrl/2/","dspace":"https://w3id.org/dspace/v0.8/"}}
company3  | DEBUG 2024-03-07T15:30:51.557247121 [ProviderContractNegotiationManagerImpl] ContractNegotiation 4a5409d7-1959-4df5-be5b-8116ea4ef3c9 is now in state TERMINATED

Possible Implementation

This is happening because the contract offer'spolicy is different from the asset policy, at line org.eclipse.edc.connector.contract.validation.ContractValidationServiceImpl.117 and org.eclipse.edc.connector.contract.policy.PolicyEquality.35, see the logs above.

The offer that comes from /federatedcatalog contains the correct policy, but some of the ODRL properties are mistyped, thus the parsing from dcat:Dataset into ContractOffer is broken and the process fails, see src/modules/edc-demo/services/catalog-browser.service.ts.60.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.