Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue37 - Have a working flow test for AM #43

Merged
merged 11 commits into from
Jun 5, 2024
Merged

Issue37 - Have a working flow test for AM #43

merged 11 commits into from
Jun 5, 2024

Conversation

andreleblanc11
Copy link
Member

@andreleblanc11 andreleblanc11 commented Jun 4, 2024

I was able to get a working flow test for AM. All 9 tests pass at the moment.

The data flow
watch -> (post locally) -> sarra -> (post locally) -> sender/am_send -> (AM socket) -> flow/amserver -> (post locally) -> download locally

Here are what the results look like when the test passes

sr python version is: , version: 3.00.54rc1
sr c is: /usr/bin/sr3_cpump, PFX= version: 3.24.03rc1
FIXME: yes dir events
checking trees...
checking +/home/sarra/sarra_devdocroot/bulletins_subscribe+
checking +/home/sarra/sarra_devdocroot/bulletins_to_send+
checking +/home/sarra/sarra_devdocroot/bulletins_to_download+
checking +/home/sarra/sarra_devdocroot/bulletins_subscribe+
checking +/home/sarra/sarra_devdocroot/bulletins_to_send+

Download Performance Summaries: LOGDIR=/home/sarra/.cache/sr3/log

        get_from-watch_f02


        amserver-flow_f01


        bulletin_subscribe_f05



NB retries for sarra 0
NB retries for flow 0
NB retries for subscribe 0

ERROR Summary:
  3  subscribe_bulletin_subscribe_f05  (1 file)  [ERROR] sarracenia.config check_undeclared_options subscribe/bulletin_subscribe_f
  2  sender_am_send_f04                (2 file)  [ERROR] sarracenia.flowcb.send.am send Connection interrupted. Attempting to reco

WARNING Summary:
  1867  subscribe_bulletin_subscribe_f05  (2 file)  [WARNING] sarracenia.flow updateFieldsAccepted path_strip_count:1
                TEST RESULTS

stat: cannot statx '/home/sarra/.cache/sr3/log/_*.log': No such file or directory
test 1 success: Log perms confirmed
                 | content of subdirs of /home/sarra/sarra_devdocroot |
test 2 success: compare contents of bulletins_to_send_md5 and bulletins_subscribe_md5 are the same
test 3 success: compare contents of bulletins_to_send_fn and bulletins_subscribe_fn are the same
broker state:
                 | Message posting |
test  4 success: watch           (1354) should post be the same as the messages filtered by the sarra             (1354)
test  5 success: sarra           (513) should publish the same number of items as sender accepts  (513)
test  6 success: sender          (513) should post same number of items as flow posts  (513)
                 | Downloaded files |
test  7 success: sarra   (513) should download same number of files as flow downloads    (513)
test  8 success: flow    (513) should download same number of files as subscribe downloads (513)
./flow_include.sh: line 127: [: : integer expression expected
test  9 success: 0 messages received that we don't know what happened.
Overall am_flow 9 of 9 passed (sample size: 814) !

Notes

  • In the sarra component, I added rejects for SACN[34] and KWAL bulletins as they were causing problems downstream with the AM sender (or AM server, I forget which).
  • As a result of this, the number of files being posted reduces after going through the sarra.
  • The bulletin filenames before going through the AM socket and after are different because the station mapping doesn't include some bulletins in the list that flows through. Some of these bulletins are american and some not, but because of this we can't compare filenames between each.
  • The checksums between the downloaded bulletins before and after going through the AM socket are sometimes also different. I was able to track down some bulletins that had ^M at the end of the file (before going through the socket). However, even when trying to remove these, the checksums were still different so I just decided to not compare the checksums before and after going through the AM socket.

Points of improvement

  • Have the subscriber post to the watch directory and take note of the duplicate suppression in the sarra component.
  • Add more checks for the flow_check? Suggestions are welcome
  • Need to cleanup the commented entries that remain from static_flow - COMPLETED
  • It would also be good to add more bulletins that are generally encountered on the AM sockets.

@andreleblanc11 andreleblanc11 marked this pull request as draft June 4, 2024 17:28
Copy link
Contributor

@petersilva petersilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great start! checksums being different, and having to block certain bulletins are concerning. It sounds like there are improvements to make in AM so that this kind of babying is not needed. I think it's better to merge and improve afterward, and this isn't in critical path yet... but it needs more work for sure.

@petersilva petersilva marked this pull request as ready for review June 4, 2024 20:22
@petersilva
Copy link
Contributor

@andreleblanc11 After I reviewed it... I saw it was in draft mode... oops... Do you want to keep it in draft for a while, or did you intend to ask for it to be merged?

@andreleblanc11
Copy link
Member Author

andreleblanc11 commented Jun 5, 2024

I want to add more bulletins in the mix for the test. So I'm working on another commit to add bulletins that are more frequently encountered on the NCPs.

But yes the idea was to have at least a pretty good test that is working, which is better then nothing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants