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

Implement round robin for selecting transaction queue #3091

Merged

Conversation

Mihajlo-Pavlovic
Copy link
Collaborator

@Mihajlo-Pavlovic Mihajlo-Pavlovic commented Mar 5, 2024

Description

Implemented round robin as a tiebreaker when there are multiple queues with same minimal length

Fixes # (issue)

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Tested locally on nodes with 2 and 1 wallet, by doing multiple publishes.

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

Copy link
Contributor

@zeroxbt zeroxbt left a comment

Choose a reason for hiding this comment

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

Isn't the current implementation more efficient ? If one of the tx queues is slower or stuck, why shouldn't we just add new txs to the queues with lower number of txs ?

@Mihajlo-Pavlovic Mihajlo-Pavlovic self-assigned this Mar 5, 2024
@Mihajlo-Pavlovic Mihajlo-Pavlovic added the improvement Improvements or enhancements to existing features label Mar 5, 2024
@Mihajlo-Pavlovic
Copy link
Collaborator Author

@zeroxbt I added additional changes, now round robin is only used as tiebreaker

@djordjekovac djordjekovac merged commit 0b353c6 into v6/develop Mar 7, 2024
2 of 3 checks passed
@djordjekovac djordjekovac deleted the v6/feature/improve-transaction-queue-selection branch March 7, 2024 10:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Improvements or enhancements to existing features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants