nasa / bplib

Apache License 2.0
27 stars 13 forks source link

Implement ordered active table as option #22

Closed jpswinski closed 4 years ago

jpswinski commented 5 years ago

Currently, the option to reuse CIDs is problematic because when the active table wraps, it will get stuck at the oldest unacknowledged bundle and even if a forced retransmit occurs, the oldest unacknowledged bundle will still be the same one since the CID is the same.

If there was an attribute passed in on channel open whereby another buffer_index[ACTIVE_TABLE_SIZE] array was allocated to keep track of the time ordering of the bundles that have been sent, then CID resuse could really be used, and the utilization (absence of gaps) of the active table would go up. The cost is the memory allocation, but the attribute at channel open would give the user the option.

jpswinski commented 4 years ago

retransmit_order attribute added, with BP_RETX_OLDEST_BUNDLE and BP_RETX_SMALLEST_CID options provided.