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

add flag for QA that speeds up processing of Auto Contribution list (previously "retry-interval" flag was used) #29391

Open
LaurenWags opened this issue Mar 29, 2023 · 1 comment

Comments

@LaurenWags
Copy link
Member

Description

Starting in 1.50.x, the retry-interval flag (if specified) is used to determine the interval at which the transaction status is fetched from the custodian as well as determine the interval at which sites from auto contribution list are processed for votes/BAT dispersal. In 1.49.x this flag used to only determine the interval at which sites in the AC list were processed for votes/BAT dispersal.

So while retry-interval flag does the same thing in 1.50.x (interval at which sites in AC list are processed), now that it also is being used to determine the interval to fetch transaction status, it can cause AC to fail prematurely.

The retry-interval flag was primarily used by QA to speed up auto contribution testing (see #10238) so it would be nice to get a flag to do this again.

Steps to Reproduce

  1. In staging, set up auto contribution with Gemini so it occurs at a time like 10:04 (my command line was --args --enable-logging=stderr --vmodule="*/bat-native-ledger/*"=9,"*/brave_rewards/*"=9,"*/bat-native-ads/*"=9,"*/bat-native-confirmations/*"=9,"*/brave_ads/*"=9,"*/brave_user_model/*"=9 --rewards=staging=true,debug=true,reconcile-interval=5,retry-interval=30
  2. Added verified sites to AC list
  3. Waited for AC to occur (confirmed it happened a little after "the 3" since Gemini processes transactions "on the 3's" - 10:03, 10:13, etc)
  4. AC starts to occur per the logs
  5. At 10:04:30 (30s after AC starts per my retry-interval set in command line), browser attempts to fetch txn status from Gemini and txn is still pending
  6. 30s later at 10:05:00, browser attempts to fetch txn status from Gemini and txn is still pending
  7. repeat step 6 several times until browser has tried 5x
  8. It is now 10:06:30 after the 5th attempt and the browser ceases attempting to fetch transaction status.
  9. Auto Contribution has failed prematurely.

It should be noted, that the browser is behaving correctly in AC failing as it only attempts 5x, but since retry-interval is being used for two things (1 (new) - interval for fetching transaction status from custodian and 2 (existing) interval at which the sites in AC list are processed) this is what is causing a problem/clash.

Actual result:

In logs:

Contribution failed after 5 retries

brave://rewards-internals:

Screen Shot 2023-03-29 at 9 43 21 AM

Expected result:

a flag (can be separate from retry-interval) that does what retry-interval did previously, when it was initially implemented

Reproduces how often:

easily

Brave version (brave://version info)

Brave | 1.50.107 Chromium: 112.0.5615.39 (Official Build) beta (x86_64)
-- | --
Revision | a0e7b9718a92bcd1cf33b7c95316caff3fc20714-refs/branch-heads/5615@{#753}
OS | macOS Version 12.6.4 (Build 21G526)

Version/Channel Information:

  • Can you reproduce this issue with the current release? n/a
  • Can you reproduce this issue with the beta channel? 1.50.x yes
  • Can you reproduce this issue with the nightly channel? 1.51.x yes

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields?
  • Does the issue resolve itself when disabling Brave Rewards?
  • Is the issue reproducible on the latest version of Chrome?

Miscellaneous Information:

cc @szilardszaloki @Miyayes

@Miyayes
Copy link
Collaborator

Miyayes commented Apr 5, 2023

There's no more jitter -- therefore, there's no possibility of 20 minute wait anymore. Now it's ~300 sec.

@Miyayes Miyayes added the priority/P4 Planned work. We expect to get to it "soon". label Apr 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants