Subject: [dtn] AMP: Post-DTNWG AMP comments

From: "Birrane, Edward J." <[email-masked]>
Date: Sun, 17 Apr 2016 20:46:42 +0000

After the DTNWG last IETF there was a small group who got together to review the AMP specifications in more detail.  A few comments came from that meeting:

I am fine with each of these changes but, before making changes to the AMP spec wanted to propose these to the list for comment.

1.  Data names
=======================
It was requests that the names for Atomic Data and Computed Data be changed. Some "Atomic data" is, itself, computed, just not by the AMP agent. The nomenclature "Externally Defined Data (EDD)" and "Variable (VAR)" were proposed to replace Atomic/Primitive Data (AD) and Computed Data (CP), respectively.

2. Computed Data scope
=======================
A question was asked about the "scope" of a computed data item. The AMP implies that CD items are initialized upon first definition (or system reboot) and persist until they are explicitly removed (if it is a user-defined CD item) or until reboot.  The AMP spec should be updated to clarify this.

3. Computed Data Evaluation
=======================
Currently in AMP, a CD is defined as an expression (EXPR) which is evaluated when necessary.  This makes it difficult to treat CDs as a variable to persistently store data values. A request was made to make CDs strongly typed and to have EXPR be one such type.  The proposed behavior of a CD would be as follows.

A CD item would be defined as a MID, TYPE, and initializing EXPR. If the type of the CD is anything other than EXPR, the initializing expression would be evaluated and the result used to provide an initial value for the CD. If the type of the CD is EXPR, then the initializing expression itself (without evaluation) will be used as the value of the CD.

This also requires adding an "EVAL" unary operator to the Agent ADM which accepts an EXPR and provides the evaluated value of the expression.

This supports (using a C-like syntax) the following kinds of definitions:
INT CD_1 = 0  // CD_1 now has the INT value of 0.
UINT CD_2 = A + B // CD_2 now has the UINT value of A + B
EXPR CD_3 = A + B // CD_3 is the expression "A + B"
UINT CD_4 = EVAL(CD_3) // CD_4 now has the UITN value of A + B

4. Assignment operator in the Agent ADM
=======================

An assignment operator should be added to the Agent ADM to allow assignment to a CD item.

-Ed

---
Edward J. Birrane, III, Ph.D.
Embedded Applications Group Supervisor
Space Exploration Sector
Johns Hopkins Applied Physics Laboratory
(W) 443-778-7423 / (F) 443-228-3839