-
Notifications
You must be signed in to change notification settings - Fork 749
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
improve performance of ValueRetrievers #1928
Conversation
Thanks for the PR. It's quite big so we will need some time to review it. It would be interesting how much the performance was improved with these changes. Could you provide some numbers for us? |
While I'm not very impressed with the performance improvement, I really like that a lot of code has been deleted (I'm serious). Less code = less maintenance and less bugs. Also I think it's really nice that there are many tests cases added. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, it took so long for reviewing this PR. Thanks for doing this work. Not only improves the performance, but I think it makes it also easier to maintain the ValueRetrievers in the future because there is now only a single implementation per type.
Sadly some other changes in the past so there are some merge conflicts.
Could you fix them? Then I will merge this PR. Everything else is fine.
Sure no problem. I'll try to get it done sometime this week. |
changelog.txt
Outdated
@@ -2,6 +2,7 @@ Changes since 3.1.89 | |||
|
|||
Fixes: | |||
+ Update the default C# skeleton template to use context injection instead of the deprecated ScenarioContext.Current | |||
+ Improved performance of ValueRetrievers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would also add that the nullable retrievers aren't needed anymore :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
I think I got all the testcases you've introduced in #1941 But would you mind doublechecking?
|
||
namespace TechTalk.SpecFlow.Assist.ValueRetrievers | ||
{ | ||
public abstract class NonNullableValueRetriever<T> : IValueRetriever |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't like bringing bad news, but this is a breaking change.
@SabotageAndi is this allowed?
Another options are:
- make them as obsolete (and maybe new folder), and remove them in a new major version (V4), or
- create a new package with the old classes, e.g. TechTalk.SpecFlow.Assist.ValueRetrievers.Legacy or TechTalk.SpecFlow.Assist.ValueRetrievers.Nullable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As these changes go into the next minor version (3.3), I have no big problems with some breaking changes. But it would be good to list this in the API Changes of the changelog.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've updated the changelog with an entry for the breaking changes of the classes.
Hooray!
On Fri, 8 May 2020 at 15:16 bollhals ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In changelog.txt
<#1928 (comment)>:
> @@ -2,6 +2,7 @@ Changes since 3.1.89
Fixes:
+ Update the default C# skeleton template to use context injection instead of the deprecated ScenarioContext.Current
++ Improved performance of ValueRetrievers
Done.
I think I got all the testcases you've introduced in #1941
<#1941> But would you mind
doublechecking?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1928 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AB3OIIZFWVKM374NJUF3TC3RQPZ3FANCNFSM4LVYHGLQ>
.
--
Best Regards,
Gennady Verdel
|
I will try to find some time on Monday/Tuesday to review the PR. |
Thanks for fixing the merge conflicts and for your contribution to SpecFlow. If you would like us to send you some SpecFlow stickers as a thank you, please fill out the form here. |
Hey
In my project I am using the TableHelperExtensionMethods quite extensively and my analysis showed that they're not the fastest, so I wanted to have a look whether I can improve things a bit.
I started by improving the performance of the ValueRetrievers to get a feeling and to see if this is something you want to include.
Regarding the changes in this PR.
Let me know what you think.
Cheers
Types of changes
Checklist: