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

feat: LogHttpDependency() should allow status codes within 100-599 range #515

Merged
merged 5 commits into from
Jan 20, 2023

Conversation

mic-hnk
Copy link
Contributor

@mic-hnk mic-hnk commented Jan 16, 2023

LogHttpDependency() - allow status codes within the range of 100 to 599 - #516

@netlify
Copy link

netlify bot commented Jan 16, 2023

Deploy Preview for arcus-observability canceled.

Name Link
🔨 Latest commit 31feeb8
🔍 Latest deploy log https://app.netlify.com/sites/arcus-observability/deploys/63ca5b10dc72e60009687310

@request-info
Copy link

request-info bot commented Jan 16, 2023

The maintainers of this repository would appreciate it if you could provide more information.

Copy link
Member

@stijnmoreels stijnmoreels left a comment

Choose a reason for hiding this comment

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

🎉 Thx for your contribution, @mic-hnk ! Greatly appreciated.
Some things we have to change:

  • Provide new LogHttpDependency overloads with int as status code.
  • Add new tests that uses this new int variant.

We can help you of course along the way!

💡 A tip for GitHub contributions: it is better to work on separate feature branches instead of on your main, otherwise conflicts and other sync problems will occur.

@stijnmoreels stijnmoreels changed the title LogHttpDependency() should allow status codes within 100-599 range feat: LogHttpDependency() should allow status codes within 100-599 range Jan 17, 2023
@fgheysels
Copy link
Member

fgheysels commented Jan 17, 2023

Thx for your contribution, @mic-hnk ! Some things we have to change:

  • Revert current changes so that the current HttpStatusCode overloads still validate within the enumeration.
  • Provide new LogHttpDependency overloads with int as status code.
  • Add new tests that uses this new int variant.
  • Updates the feature documentation to show this overload.

We can help you of course along the way!

💡 A tip for GitHub contributions: it is better to work on separate feature branches instead of on your main, otherwise conflicts and other sync problems will occur.

I don't necessarily agree with the first point @stijnmoreels , see also my comment in the issue :)

@stijnmoreels
Copy link
Member

stijnmoreels commented Jan 18, 2023

I don't necessarily agree with the first point @stijnmoreels , see also my comment in the issue :)

Ok, that's fine by me. Removed it. 👍
We could also see this as a fix, and do the changes in another 'feature' PR. But if @mic-hnk want to take it up, by all means! 😁

@mic-hnk
Copy link
Contributor Author

mic-hnk commented Jan 18, 2023

I'm on it

@mic-hnk
Copy link
Contributor Author

mic-hnk commented Jan 18, 2023

🎉 Thx for your contribution, @mic-hnk ! Greatly appreciated. Some things we have to change:

  • Provide new LogHttpDependency overloads with int as status code.
  • Add new tests that uses this new int variant.
  • Updates the feature documentation to show this overload.

We can help you of course along the way!

💡 A tip for GitHub contributions: it is better to work on separate feature branches instead of on your main, otherwise conflicts and other sync problems will occur.

I pushed some changes.
Also, I guess this is the documentation you mean - https://observability.arcus-azure.net/features/writing-different-telemetry-types/#measuring-http-dependencies
Do you have any suggestion how I should indicate difference between previously existing methods and the int overload?

@fgheysels
Copy link
Member

fgheysels commented Jan 18, 2023

🎉 Thx for your contribution, @mic-hnk ! Greatly appreciated. Some things we have to change:

  • Provide new LogHttpDependency overloads with int as status code.
  • Add new tests that uses this new int variant.
  • Updates the feature documentation to show this overload.

We can help you of course along the way!
💡 A tip for GitHub contributions: it is better to work on separate feature branches instead of on your main, otherwise conflicts and other sync problems will occur.

I pushed some changes. Also, I guess this is the documentation you mean - https://observability.arcus-azure.net/features/writing-different-telemetry-types/#measuring-http-dependencies Do you have any suggestion how I should indicate difference between previously existing methods and the int overload?

To be honest, I think the docs are sufficient as is. In my opinion, a developer will be able to detect this overload by using intellisense.

@stijnmoreels
Copy link
Member

To be honest, I think the docs are sufficient as is. In my opinion, a developer will be able to detect this overload by using intellisense.

Just looked, you might be right 🤔 . We can leave it like this. 👍

@mic-hnk mic-hnk requested a review from stijnmoreels January 19, 2023 07:10
Copy link
Member

@stijnmoreels stijnmoreels left a comment

Choose a reason for hiding this comment

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

Thank you so much for taking this up! 🥇
Some small comments but were getting there.

Hejniak Michał added 2 commits January 19, 2023 14:47
@mic-hnk mic-hnk requested a review from stijnmoreels January 19, 2023 14:01
Copy link
Member

@stijnmoreels stijnmoreels left a comment

Choose a reason for hiding this comment

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

Think that this new variant you added also needs some unit tests. But otherwise this is good to go! 💯
Great job re-using the common code practices and helping us bringing higher value! Greatly appreciated. 💗

@mic-hnk
Copy link
Contributor Author

mic-hnk commented Jan 20, 2023

Think that this new variant you added also needs some unit tests. But otherwise this is good to go! 💯 Great job re-using the common code practices and helping us bringing higher value! Greatly appreciated. 💗

I added some more tests :)

@fgheysels
Copy link
Member

Thanks for this contribution.
This is a small but convenient change which will improve Arcus' usability!

@mic-hnk
Copy link
Contributor Author

mic-hnk commented Jan 20, 2023

Thank you :)
This project provides a lot of value and I'm glad it's there. Keep up the good work!

@stijnmoreels stijnmoreels merged commit 9f8937a into arcus-azure:main Jan 20, 2023
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.

3 participants