Thanks to visit codestin.com
Credit goes to Github.com

Skip to content

TheWorldAvatar/ExposureFeatureInfoAgent

Repository files navigation

Exposure feature info agent

The purpose of this agent is to display results generated by the exposure calculation agent. The advantage of this over the standard Feature-Info-Agent is that this agent groups the exposure results in a format that is more suited for the calculation results, e.g.

{
    "Count": {"400 m": 10, "800 m": 50},
    "Area": {"400 m": 100, "800 m": 5000}
}

which is not possible with the standard feature info agent.

This agent is designed to be deployed on https://github.com/TheWorldAvatar/hd4-stack.

Routes

  1. /feature-info-agent/get

    Mandatory parameter: iri

    Example request (handled by visualisation framework):

    curl http://localhost:3838/exposure-feature-info-agent/feature-info-agent/get?iri=http://subject

    This is for non-trajectory calculations where results are instantiated as triples.

  2. /trajectory/feature-info-agent/get

    Parameters:

    • iri (mandatory): IRI of the trajectory (the instance that contains point time series)
    • trip (optional, mandatory IF trajectory contains trip information): trip index

    Example request (handled by visualisation framework):

    curl http://localhost:3838/exposure-feature-info-agent/trajectory/feature-info-agent/get?iri=http://subject&trip=1

    This is for trajectory based calculations where results are instantiated as time series.

Build

Populate docker\credentials with repo_password.txt and repo_username.txt.

Then run the following to build the Docker image:

docker compose build

To push the image to the repository, run the following

docker compose push

Debugging

A debugging config is provided - https://github.com/TheWorldAvatar/hd4-stack/blob/main/stack-manager/inputs/config/services/exposure-feature-info-agent-debug.json, with an extra JAVA_OPTS environment variable and the debugging port is set to 5005.

To attach using VS code, the following config can be applied in launch.json:

{
    "type": "java",
    "name": "Reattach and Debug",
    "request": "attach",
    "hostName": "localhost",
    "port": "5005"
}

Note that some debugging features may not work if this repo folder is not named ExposureFeatureInfoAgent (e.g. being able to watch parameters).

About

This agent is used to display exposure results of a subject

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages