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

horizon/ingest: http archive requests need a metric and user-agent correction #5161

Closed
sreuland opened this issue Jan 16, 2024 · 4 comments
Closed
Assignees
Labels
bug horizon performance issues aimed at improving performance

Comments

@sreuland
Copy link
Contributor

sreuland commented Jan 16, 2024

What version are you using?

2.27.0

What did you do?

run horizon with forward/live ingestion enabled, ingest=true which is enabled. by default.

What did you expect to see?

  • outbound http archive url requests initiated by horizon ingestion should have the http header User-Agent: "horizon/<horizon_version> golang/<go_mod_version>
  • outbound http archive url requests initiated by horizon captive core runner(created from NewCaptive()) should have the http header User-Agent: "horizon/<horizon_version> golang/<go_mod_version>
  • a prometheus metric is emitted for the history archive request

What did you see instead?

the outbound archive url request has the default golang http header instead User-Agent: "Go-http-client

@sreuland sreuland added the bug label Jan 16, 2024
@sreuland
Copy link
Contributor Author

I believe this bug was present up to release 2.27.0 due to the user agent config being dropped from the config sent to archive pool here:

https://github.com/stellar/go/blob/horizon-v2.27.0/historyarchive/archive_pool.go#L36-L39

however, looking at latest on master, this issue appears to now be obsolete as the entire config including user agent is now sent to the archive pool creation:

https://github.com/stellar/go/blob/master/historyarchive/archive_pool.go#L34-L36

this change was merged recently as part of exp: Add the Zenith (Light Horizon) prototype #4352, and will result in archive url requests from horizon ingestion to now emit http header User-Agent: horizon/<horizon_version> golang/<go_mod_version> and will land on next release upcoming of 2.28.0.

@sreuland
Copy link
Contributor Author

related to #5163, at least for identifying an archive request coming from horizon based on user-agent.

@sreuland sreuland added the performance issues aimed at improving performance label Jan 16, 2024
@sreuland sreuland self-assigned this Jan 16, 2024
@sreuland sreuland changed the title horizon/ingest: http archive requests ignores custom user-agent name config horizon/ingest: http archive requests need a metric and user-agent correction Jan 16, 2024
@sreuland
Copy link
Contributor Author

will patch this on 2.28.0 release branch, since latest master which has a fix from a larger feature dev effort related to ledgerexporter, #4352, will not be included on 2.28.0 release.

@sreuland
Copy link
Contributor Author

#5166 merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug horizon performance issues aimed at improving performance
Projects
Status: Done
Development

No branches or pull requests

1 participant