Coder Social home page Coder Social logo

jhuapl / dtnma-tools Goto Github PK

View Code? Open in Web Editor NEW
1.0 7.0 0.0 795 KB

A reference implementation of the DTN Management Architecture (DTNMA) Agent and related Tools

Home Page: https://jhuapl.github.io/dtnma-tools/

License: Apache License 2.0

CMake 0.68% Shell 0.67% Makefile 0.03% C 97.86% Dockerfile 0.21% Python 0.54%
dtn network-management network-monitoring dtnma

dtnma-tools's Introduction

DTNMA Tools

This software package contains tools related to the Delay-Tolerant Networking Management Architecture (DTNMA), specifically an implementation of the DTNMA Agent and Manager.

The current tools are based on the following specifications:

โš ๏ธ These documents are not published standards and are subject to change over time as the standards are developed and finalized.

Installation

This project uses the CMake and Ninja build systems and relies on a few third-party commercial, off-the-shelf (COTS) libraries to build and run properly.

To perform a basic build and installation, including for dependencies, the following packages must be installed. This list is generated for Ubuntu but similar ones exist for other major OSes.

cmake
ninja-build
ruby
build-essential
autoconf
libtool
civetweb
libcivetweb-dev
libssl-dev
libcjson-dev

To use the systemd wrapper utility around the executables, also install the PIP package

systemd-python

Once dependencies are installed, the following scripts can be run to build and test the project:

./prep.sh
./build.sh check

After the build is successful, the following will install to a local prefix path ($PWD/testroot/usr):

./build.sh install

For further details, see the example in testenv/Dockerfile, which builds a stand-alone test environment container image, along with the other files in testenv.

Usage

The example agent and manager both rely on ION for message transport, so a prerequisite for both is a running ION BPA instance. An example of all of this, including the use of systemd scripts, is under the testenv directory.

To run the integrated test environment, the docker engine and compose must be installed per the Docker installation instructions and typically the user will need to be added to the docker system group for access. The installation can be validated by the ability to run simple introspection commands like docker ps and see a successful result.

Once that is done, the images can be built and containers started with:

./testenv/start.sh

A checkout test can be run to ensure services are running and round-trip AMP control-to-report loop is closed with:

./testenv/check.sh

Finally, after test anything in the containers is finished they can be stopped and cleaned up with:

./testenv/stop.sh

Stand-Alone Agent

As both a demonstration and a useful test fixture for AMP and ADMs, a stand-alone Agent which uses stdio (stdin for commands and stdout for reporting) with hex-encoded AMP messages is included as the stdio_agent. This provides a minimum implementation of an Agent executable without requriring a specific underlying transport for AMP messages. This is not a recommended way to use AMP in a networked environemnt but makes it easier to do things like exercising the Agent in a simple test fixture like what is done with test_stdio_agent.py.

Support

The wiki for this project contains additional details outside of the source and API documentation, and the issue tracker for this project is used for defect reports and enhancement requests. Additional details are in the Contributing document.

Contributing

See the separate Contributing document for details on contributing to this project.

Authors and acknowledgment

Original authors of the DTNMA Agent and Manager within the NASA ION project are Ed Birrane, David Linko, Sarah Heiner.

License

This project uses the Apache-2.0 license.

dtnma-tools's People

Contributors

briansipos avatar d-linko avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

dtnma-tools's Issues

timevalues decoding issue

sending ari:/IANA:amp_agent/CTRL.add_tbr(ari:/TBR.testtime3,0,9,4,[ari:/IANA:amp_agent/CTRL.gen_rpts([ari:/IANA:amp_agent/RPTT.full_report],["ipn:1.7"])],"testTime") to agent translated as ace to 0xC115410A05062415151525120B497465737474696D653300090481C1154105050225238187181941000501126769706E3A312E37687465737454696D65

issue with the period, 9, getting translated to 410065408 by adm_get_parm_tv causing amp_tv_to_ctime to fail returning a time of 0

Issue with report timestamps and uploading to DB

Issue with using relative TV and uploading to DB, need to use rpt->time.ticks +EPOCH_ABSTIME_DTN + EPOCH_DTN_POSIX
TBR run all at once, need to look at how its calculating relative time for the period portion and starttime of TBR

handling default manager eid when sending reports

currently setting manager eid to "dtn:none" in lcc.c when the eid is not given.
ah proposed fix is agent could have a text-only configuration of its "current manager" within nmagent_t that gets set appropriately from nmagent_register()

current work around is including manager eid in rxmgrs parameter for gen_rpts

Missing an API to inject object handlers

The current Agent object registration API requires a lot of per-ADM generated code and use a form of API that doesn't easily allow for dependency injection. Using an API more similar to NetSNMP with subtree registration and object handlers would help to separate the Agent behaivior from the object-specific behavior. Some brainstorming can happen in comments on this ticket.

Current object API does not have serialization interface

The original ION-integrated AMP Agent relied on using the ION SDR for persistent storage of objects. After separating the Agent from ION, and the SDR, objects no longer have persistence.

It would be a design activity to add an object persistence API and to include some initial example using something like SQLite to store serialized objects. The API would need to be optimized to store only when objects state has changed rather than all-at-once. It would also need to distinguish between ADM static objects and ODM objects, so that the ADM objects are registered via an API and ODM objects are registered by scanning the object database.

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.