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 net8.0 and efcore 8.0 #475

Closed
wants to merge 56 commits into from
Closed

add net8.0 and efcore 8.0 #475

wants to merge 56 commits into from

Conversation

ehsangfl
Copy link
Contributor

@ehsangfl ehsangfl commented Jan 7, 2024

No description provided.

ehsangfl and others added 30 commits May 6, 2023 16:12
* Asp Core
    * New extension method to add OpenRiaServices to services.
    * New extension method to add OpenRiaServices to pipeline.

---------

Co-authored-by: SandstromErik <[email protected]>
Adding links to CoC and .NET Foundation website
" load mono.cecil.pdb from same folder as tools
Fix to prevent #247 from happening again
… csproj (#411)

* update targets file
* Add .NET foundation
Revert entityframework update from 6.* to 7.*
Update entityframwork nugets from 3.1.24 to 3.1.32
* Add Net7 build target to support "Finally Conventions" (IEndpointConventionBuilder.Finally)
* Add OpenRiaServices.Server.DomainOperationEntry to endpoint metadata
    This allows end user to easier implement additional conventions (such as Open Api or similar)
* Copy AuthorizationAttributes to endpoint metadata for queries and invokes to support AspNetCore Authorization
   Attributes can be set on either method or class level
Modify the next size to rent for buffer in ArrayPoolStream in order to handle large buffers
Update Changelog for release
* Asp Core
    * New extension method to add OpenRiaServices to services.
    * New extension method to add OpenRiaServices to pipeline.

---------

Co-authored-by: SandstromErik <[email protected]>
Adding links to CoC and .NET Foundation website
" load mono.cecil.pdb from same folder as tools
Fix to prevent #247 from happening again
… csproj (#411)

* update targets file
* Add .NET foundation
Revert entityframework update from 6.* to 7.*
Update entityframwork nugets from 3.1.24 to 3.1.32
@ehsangfl
Copy link
Contributor Author

ehsangfl commented Jan 7, 2024 via email

@Daniel-Svensson
Copy link
Member

@ehsangfl it looks like you got more commits and changes than expected.

Can you rebase or create a new branch based on current main with just the commits for efcore 8 support?

@SandstromErik do you have the time to look at this after cleanup?

Once the changes are in we need to update the version property in the .csproj.

We can consider dropping .net6/efcore6 support but it is a bit easier said than done since it is referenced from test projects targeting net6 at the moment. (We can either update test projects or compile net6 but exclude it from nuget package)

Copy link
Contributor

@SandstromErik SandstromErik left a comment

Choose a reason for hiding this comment

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

I see no problems and have no other comments to these changes

SandstromErik and others added 10 commits January 10, 2024 16:05
* Update Changelog.md
…n't need to install System.Collections.Immutable (#479)
* Use portable pdbs for framework targets
* fix expected / actual order in Assert.AreEqual
* Remove creation of ProjectPath.txt from some projects that dont need it
* update mstest nuget packages to 3.2
* <Reference should only be included for NET Framework
Makes adding n entities to an EntityCollection or similar roughly O(n) instead of O(n²)

* Don't further process entities which are New, Unchanged, Modified since any changes to them would have already been discovered
* Calculate and cache AssociationMembers once
* Do some code/style cleanup which might also give marginally better perf (calls contains on HashSet instead of Enumerable) and smarter enum checks due to pattern matchning
* Always package nuget's so that PR artifacts can be tested
* minor EntitySet perf improvements
   * Use result of HashSet.Add instead of checking Contains before Add
   * Make ListCollectionViewProxy smarter
     * remove IndexOf from Add for O(1) instead of O(n) performance
     * Contains use hashSet contains instead of IndeOf for O(1) instead of O(n) performance
     * Remove argument range check
* EntitySet Make _set and _identityCache fields readonly
Remove unnecessary calls to *.Contains()
* Combine .!Contains with .Add into a single Add operation
* Replace IndexOf with Contains (faster remove from EntityCollection)

Go though usages of ContainsKey
* Use TryAdd instead if followed by Add
* Use TryGet if followed by fetching value
* Switch to HashSet if value is not used

Replace unneccesary IndexOf calls
* When access EntitySet of EntityCollection using CollectioViewSource add and Contains checks are much faster O(1) instead of O(n)

This translates to roughly ~9% perf improvement for adding 50 000 entities to an EntityCollection.
This fixes the current analyser suggestions/warnings when building AspNetCore hosting about several places in query deserialisation where span's should be used instead of substring.

Performance and allocations might be better, but the main driver is to remove build output when building the AspNetCore hosting project.

Apart from that it also changes naming of private fields to better match the rest of the code base

* Add System.Collections.Immutable nuget dependency to WCF Hosting and update other dependencies
@Daniel-Svensson
Copy link
Member

@ehsangfl thank you for the contribution.

I will probably create a new PR with just the required change to the efcore project and will try to add you as co-author

Some recommendations for you :

  • backup your local changes to another branch git checkout backup main
  • now you can update main or another branch by either doing
    a; reset you main branch to match openria serivces git fetch --all git reset --hard upstream/main
    * git cherry-pick backup -- FILEPATH (to get individual commits) from you backup branch
    * or git checkout backup -- FILEPAHT ? (check out files from another branch and commit the changes to keep ?
    b; checkout main and do interactive rebase against upstream/main
    git fetch --all git rebase -i upstream/main
  • try to work with features in feature branches
    • (which can easily be deleted one done)
    • always start with checking out the latests from upstream (git fetch & reset can be used)

SandstromErik and others added 2 commits April 12, 2024 14:57
…ttributes. Also removed unneccesary attribute sorting and updated most tt generated files (#495)
@ehsangfl ehsangfl closed this by deleting the head repository Apr 13, 2024
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.

5 participants