nasa-jpl / ION-DTN

NASA Open Source ION Software implementation of Delay Tolerant Networking. ION development is managed by the Jet Propulsion Lab; regression testing and code management are provided by Ohio University.
https://nasa-jpl.github.io/ION-DTN/
Other
23 stars 6 forks source link

SF: PC: cfdptest not handling events in non-interactive mode #21

Open iondev33 opened 9 months ago

iondev33 commented 9 months ago

cfdptest does not seem to handle any event in scripted mode (non interactive). It exits right away. This is problematic when you queue up a multitude of request transfers. It will overrun ION. Solution seems to have cfdptest handle events until a transfer complete is received (at least when that mode is requested).

------comment Attached updated version for consideration with some very minor changes to exit only when transaction finished event is received.

cfdptest.txt

-------comment Attached an updated version of cfdp_listen.c. Original code is from Samuel Jero 2011. Code has been updated to timestamp the events at a millisecond resolution. It has been updated to generate optional kafka messages on 'transaction finished' with support of metadata information. That code is available on demand. This code runs on the receiving node of cfdp file transfers. It detects all cfdp events, prints messages (and optionally can generate a software bus message when a file has been successfully transmitted). The source node can use cfdp_test to transmit files. cfdp_test will wait now that a file is transmitted to exit. A bash file can be used to transmit a batch of files as necessary.

-------comment re-attached cfdp_listen.c cfdp_listen.txt

-------comment SB: cfdptest is a test program, designed for testing the functionality of CFDP, and for that purpose it seems to be fine as written. It is not designed for operations. A program that uses CFDP to send a batch of files and waits for confirmation of the reception of each file would be new software, not ION, and it would want to be carefully designed. Unfortunately we're not staffed to support the debugging of user-written software.

Where is cfdp_listen.c located in the ION source tree? No idea what it looks like or how it works, or is supposed to work.

We would be glad to add your new code to the "contrib" folder when you're happy with its performance.

-------comment cfdplisten.c was found in tests/issue-330-cfdpclock-FDU-removal folder. It was written by Samuel Jero in Dec 2011 cfdptest does not seem to require much changes besides handling events until the transaction is finished. cfdplisten is more problematic depending on the configuration and parameters being used. With 3.7.2, if I use mode 2 with acsadmin running, I get a lot of errors and core dumps. It works better without acsadmin running. But this might not be a long term solution. So far, I can’t really say that CFDP is running reliably on my system when trying to transfer more than one file.

I have not tried with 4.x but could. Eventually we want to get to reliable cfdp file transfers end-to-end. One thing I don’t understand is that CFDP seems to be part of ION, isn’t it? or is CFDP prototype software as well and not designed for operations? It is not clear from the documentation. Thanks, Pat.

---------comment SB: The CFDP protocol implementation in ION is designed for operations, and it is currently in daily operational use on ISS.

The cfdptest test application is not part of the CFDP protocol implementation. It is a test program, designed and supported only for the purpose of testing the CFDP protocol implementation.

The cfdplisten test application is supported only for the purpose of executing the issue-330-cfdpclock-FDU-removal test. It’s unclear whether or not (or how long) that test will be retained in the ION regression test suite, so relying on it for any purpose at all is probably unwise.

Mode 2 of cfdptest was designed for use with standard (that is, RFC 5050) custody transfer, not with ACS, with which it was never tested. It ought to work with ACS all the same, but ACS in bpv6 is known to have some issues that might be contributing to the errors you are seeing. Since bpv6 is planned to be deprecated, neither running with nor without bpv6 ACS is a long term solution.

CFDP runs reliably end-to-end if you use the software as provided, for the purposes for which it was designed. The user application program behavior you are looking for will have to be implemented in new user application software. JPL may be able to help you develop software to your specifications, but it’s not in our currently funded program of work.