Skip to content

Commit 10d7c59

Browse files
committed
Merge branch 'master' into merge-master-into-openapi
2 parents 1b89742 + 004168f commit 10d7c59

40 files changed

+559
-137
lines changed

.config/dotnet-tools.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
]
1616
},
1717
"dotnet-reportgenerator-globaltool": {
18-
"version": "5.2.1",
18+
"version": "5.2.2",
1919
"commands": [
2020
"reportgenerator"
2121
]

.github/CONTRIBUTING.md

Lines changed: 32 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ When you are creating an enhancement suggestion, please include as many details
3939

4040
- **Use a clear and descriptive title** for the issue to identify the suggestion.
4141
- **Provide a step-by-step description of the suggested enhancement** in as many details as possible.
42-
- **Provide specific examples to demonstrate the usage.** Include copy/pasteable snippets which you use in those examples, as [Markdown code blocks](https://docs.github.com/en/github/writing-on-github/creating-and-highlighting-code-blocks).
42+
- **Provide specific examples to demonstrate the usage.** Include copy/pasteable snippets which you use in those examples as [Markdown code blocks](https://docs.github.com/en/github/writing-on-github/creating-and-highlighting-code-blocks).
4343
- **Describe the current behavior and explain which behavior you expected to see instead** and why.
4444
- **Explain why this enhancement would be useful** to most users and isn't something that can or should be implemented in your API project directly.
4545
- **Verify that your enhancement does not conflict** with the [JSON:API specification](https://jsonapi.org/).
@@ -56,7 +56,7 @@ Please follow these steps to have your contribution considered by the maintainer
5656
- Follow all instructions in the template. Don't forget to add tests and update documentation.
5757
- After you submit your pull request, verify that all status checks are passing. In release builds, all compiler warnings are treated as errors, so you should address them before push.
5858

59-
We use [CSharpGuidelines](https://csharpcodingguidelines.com/) as our coding standard (with a few minor exceptions). Coding style is validated during PR build, where we inject an extra settings layer that promotes various suggestions to warning level. This ensures a high-quality codebase without interfering too much when editing code.
59+
We use [CSharpGuidelines](https://csharpcodingguidelines.com/) as our coding standard. Coding style is validated during PR build, where we inject an extra settings layer that promotes various IDE suggestions to warning level. This ensures a high-quality codebase without interfering too much while editing code.
6060
You can run the following [PowerShell scripts](https://github.com/PowerShell/PowerShell/releases) locally:
6161
- `pwsh ./inspectcode.ps1`: Scans the code for style violations and opens the result in your web browser.
6262
- `pwsh ./cleanupcode.ps1 [branch-name-or-commit-hash]`: Reformats the codebase to match with our configured style, optionally only changed files since the specified branch (usually master).
@@ -86,13 +86,39 @@ public sealed class AppDbContext : DbContext
8686
}
8787
```
8888

89+
### Pull request workflow
90+
91+
Please follow the steps and guidelines below for a smooth experience.
92+
93+
Authors:
94+
- When opening a new pull request, create it in **Draft** mode.
95+
- After you've completed the work *and* all checks are green, click the **Ready for review** button.
96+
- If you have permissions to do so, ask a team member for review.
97+
- Once the review has started, don't force-push anymore.
98+
- When you've addressed feedback from a conversation, mark it with a thumbs-up or add a some text.
99+
- Don't close a conversation you didn't start. The creator closes it after verifying the concern has been addressed.
100+
- Apply suggestions in a batch, instead of individual commits (to minimize email notifications).
101+
- Re-request review when you're ready for another round.
102+
- If you want to clean up your commits before merge, let the reviewer know in time. This is optional.
103+
104+
Reviewers:
105+
- If you're unable to review within a few days, let the author know what to expect.
106+
- Use **Start a review** instead of **Add single comment** (to minimize email notifications).
107+
- Consider to use suggestions (the ± button).
108+
- Don't close a conversation you didn't start. Close the ones you opened after verifying the concern has been addressed.
109+
- Once approved, use a merge commit only if all commits are clean. Otherwise, squash them into a single commit.
110+
A commit is considered clean when:
111+
- It is properly documented and covers all aspects of an isolated change (code, style, tests, docs).
112+
- Checking out the commit results in a green build.
113+
- Having this commit show up in the history is helpful (and can potentially be reverted).
114+
89115
## Creating a release (for maintainers)
90116

91117
- Verify documentation is up-to-date
92-
- Bump the package version in Directory.Build.props
118+
- Bump the package version in `Directory.Build.props`
93119
- Create a GitHub release
94-
- Update https://github.com/json-api-dotnet/JsonApiDotNetCore.MongoDb to consume the new version and release
95-
- Create a new branch in https://github.com/json-api-dotnet/MigrationGuide and update README.md in master
120+
- Update [JsonApiDotNetCore.MongoDb](https://github.com/json-api-dotnet/JsonApiDotNetCore.MongoDb) to consume the new version and release
121+
- Create a new branch in [MigrationGuide](https://github.com/json-api-dotnet/MigrationGuide) and update README.md in master, if major version change
96122

97123
## Backporting and hotfixes (for maintainers)
98124

@@ -101,7 +127,7 @@ public sealed class AppDbContext : DbContext
101127
git checkout tags/v2.5.1 -b release/2.5.2
102128
```
103129
- Cherrypick the merge commit: `git cherry-pick {git commit SHA}`
104-
- Bump the package version in Directory.Build.props
130+
- Bump the package version in `Directory.Build.props`
105131
- Make any other compatibility, documentation, or tooling related changes
106132
- Push the branch to origin and verify the build
107133
- Once the build is verified, create a GitHub release, tagging the release branch

docs/home/index.html

Lines changed: 30 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<link href="favicon.ico" rel="icon">
1010
<link href="favicon.ico" rel="apple-touch-icon">
1111
<link href="https://fonts.googleapis.com/css?family=Open+Sans:300,300i,400,400i,600,600i,700,700i|Raleway:300,300i,400,400i,600,600i,700,700i" rel="stylesheet">
12-
<link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.5.0/css/bootstrap.css" rel="stylesheet">
12+
<link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.5.0/css/bootstrap.min.css" rel="stylesheet">
1313
<link href="https://unpkg.com/boxicons@2.0.7/css/boxicons.min.css" rel="stylesheet">
1414
<link href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.4.0/styles/default.min.css" rel="stylesheet">
1515
<link href="https://cdnjs.cloudflare.com/ajax/libs/aos/2.3.4/aos.css" rel="stylesheet">
@@ -22,7 +22,10 @@
2222
<div class="row">
2323
<div class="col-lg-7 pt-5 pt-lg-0 order-2 order-lg-1">
2424
<h1>JsonApiDotNetCore</h1>
25-
<h2>A framework for building <a href="https://jsonapi.org/" target="_blank">JSON:API</a> compliant REST APIs using .NET Core and Entity Framework Core. Includes support for <a href="https://jsonapi.org/ext/atomic/" target="_blank">Atomic Operations</a>.</h2>
25+
<h2>
26+
A framework for building <a href="https://jsonapi.org/" target="_blank">JSON:API</a> compliant REST APIs using .NET Core and Entity Framework Core.
27+
Includes support for <a href="https://jsonapi.org/ext/atomic/" target="_blank">Atomic Operations</a>.
28+
</h2>
2629
<a href="#about" class="btn-get-started scrollto">Read more</a>
2730
<a href="../../getting-started/install.html" class="btn-get-started">Getting started</a>
2831
<a href="https://github.com/json-api-dotnet/JsonApiDotNetCore/" target="_blank" class="btn-get-started">Contribute on GitHub</a>
@@ -43,12 +46,13 @@ <h2>A framework for building <a href="https://jsonapi.org/" target="_blank">JSON
4346
<div class="col-lg-6 pt-5 pt-lg-0">
4447
<h3 data-aos="fade-up">Objectives</h3>
4548
<p data-aos="fade-up" data-aos-delay="100">
46-
The goal of this library is to simplify the development of APIs that leverage the full range of features provided by the <a href="https://jsonapi.org/" target="_blank">JSON:API</a> specification.
49+
The goal of this library is to simplify the development of APIs that leverage the full range of features
50+
provided by the <a href="https://jsonapi.org/" target="_blank">JSON:API</a> specification.
4751
You just need to focus on defining the resources and implementing your custom business logic.
4852
</p>
4953
<div class="row">
5054
<div class="col-md-6" data-aos="fade-up" data-aos-delay="100">
51-
<i class='bx bxs-package'></i>
55+
<i class="bx bxs-package"></i>
5256
<h4>Eliminate boilerplate</h4>
5357
<p>We strive to eliminate as much boilerplate as possible by offering out-of-the-box features such as sorting, filtering and pagination.</p>
5458
</div>
@@ -69,28 +73,28 @@ <h2>Features</h2>
6973
<p>The following features are supported, from HTTP all the way down to the database</p>
7074
</div>
7175
<div class="row">
72-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="100" id='filter'>
76+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="100" id="filter">
7377
<div class="icon-box">
7478
<div class="icon"><i class="bx bxs-filter-alt"></i></div>
7579
<h4 class="title">Filtering</h4>
7680
<p class="description">Perform compound filtering using the <code>filter</code> query string parameter</p>
7781
</div>
7882
</div>
79-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="200" id='sort'>
83+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="200" id="sort">
8084
<div class="icon-box">
81-
<div class="icon"><i class="bx bx-sort-z-a"></i></div>
85+
<div class="icon"><i class="bx bx-sort-a-z"></i></div>
8286
<h4 class="title">Sorting</h4>
8387
<p class="description">Order resources on one or multiple attributes using the <code>sort</code> query string parameter</p>
8488
</div>
8589
</div>
86-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="300" id='pagination'>
90+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="300" id="pagination">
8791
<div class="icon-box">
8892
<div class="icon"><i class="bx bx-note"></i></div>
8993
<h4 class="title">Pagination</h4>
9094
<p class="description">Leverage the benefits of paginated resources with the <code>page</code> query string parameter</p>
9195
</div>
9296
</div>
93-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="400" id='selection'>
97+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="400" id="selection">
9498
<div class="icon-box">
9599
<div class="icon"><i class="bx bxs-select-multiple"></i></div>
96100
<h4 class="title">Sparse fieldset selection</h4>
@@ -99,30 +103,30 @@ <h4 class="title">Sparse fieldset selection</h4>
99103
</div>
100104
</div>
101105
<div class="row">
102-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="100" id='include'>
106+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="500" id="include">
103107
<div class="icon-box">
104108
<div class="icon"><i class="bx bxs-vector"></i></div>
105109
<h4 class="title">Relationship inclusion</h4>
106110
<p class="description">Side-load related resources of nested relationships using the <code>include</code> query string parameter</p>
107111
</div>
108112
</div>
109-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="100" id='security'>
113+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="600" id="security">
110114
<div class="icon-box">
111-
<div class="icon"><i class='bx bxs-lock'></i></div>
115+
<div class="icon"><i class="bx bxs-lock"></i></div>
112116
<h4 class="title">Security</h4>
113-
<p class="description">Configure permissions, such as view/create/change/sort/filter of attributes and relationships</p>
117+
<p class="description">Configure permissions, such as viewing, creating, modifying, sorting and filtering of attributes and relationships</p>
114118
</div>
115119
</div>
116-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="100" id='validation'>
120+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="700" id="validation">
117121
<div class="icon-box">
118-
<div class="icon"><i class='bx bx-check-double'></i></div>
122+
<div class="icon"><i class="bx bx-check-double"></i></div>
119123
<h4 class="title">Validation</h4>
120-
<p class="description">Validate incoming requests using built-in ASP.NET Core <code>ModelState</code> validation, which works seamlessly with partial updates</p>
124+
<p class="description">Validate incoming requests using built-in ASP.NET Model Validation, which works seamlessly with partial updates</p>
121125
</div>
122126
</div>
123-
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="200" id='customizable'>
127+
<div feature class="col-md-6 col-lg-3 d-flex align-items-stretch" data-aos="zoom-in" data-aos-delay="800" id="customizable">
124128
<div class="icon-box">
125-
<div class="icon"><i class='bx bxs-category-alt'></i></div>
129+
<div class="icon"><i class="bx bxs-category-alt"></i></div>
126130
<h4 class="title">Customizable</h4>
127131
<p class="description">Use various extensibility points to intercept and run custom code, besides just model annotations</p>
128132
</div>
@@ -139,7 +143,7 @@ <h2>Example usage</h2>
139143
<div class="row">
140144
<div code-example class="col-md-12 col-lg-12 d-flex d-flex justify-content-center" data-aos="zoom-in" data-aos-delay="100">
141145
<div class="icon-box code-example">
142-
<div class="icon"><i class='bx bx-detail'></i></div>
146+
<div class="icon"><i class="bx bx-detail"></i></div>
143147
<h4 class="title">Resource</h4>
144148
<pre>
145149
<code>#nullable enable
@@ -179,16 +183,16 @@ <h4 class="title">Resource</h4>
179183
<div class="row">
180184
<div code-example class="col-md-12 col-lg-12 d-flex d-flex justify-content-center" data-aos="zoom-in" data-aos-delay="100">
181185
<div class="icon-box code-example">
182-
<div class="icon"><i class='bx bx-message-rounded-detail'></i></div>
186+
<div class="icon"><i class="bx bx-message-rounded-detail"></i></div>
183187
<h4 class="title">Request</h4>
184188
<pre><code>GET /articles?filter=contains(summary,'web')&sort=-lastModifiedAt&fields[articles]=title,summary&include=author HTTP/1.1</code></pre>
185189
</div>
186190
</div>
187191
</div>
188192
<div class="row">
189-
<div code-example class="col-md-12 col-lg-12 d-flex d-flex justify-content-center" data-aos="zoom-in" data-aos-delay="100">
193+
<div code-example class="col-md-12 col-lg-12 d-flex d-flex justify-content-center" data-aos="zoom-in" data-aos-delay="200">
190194
<div class="icon-box code-example">
191-
<div class="icon"><i class='bx bx-message-rounded-detail bx-flip-horizontal'></i></div>
195+
<div class="icon"><i class="bx bx-message-rounded-detail bx-flip-horizontal"></i></div>
192196
<h4 class="title">Response</h4>
193197
<pre>
194198
<code>{
@@ -259,15 +263,15 @@ <h4 class="title">Response</h4>
259263
<h2>Sponsors</h2>
260264
</div>
261265
<div class="row justify-content-center">
262-
<div sponsor class="col-md-4 col-lg-3 d-flex align-items-stretch justify-content-center aos-init aos-animate" data-aos="zoom-in" data-aos-delay="100" id="jetbrains">
263-
<div class="icon-box d-flex align-items-center">
266+
<div sponsor class="col-md-4 col-lg-3 d-flex align-items-stretch justify-content-center aos-init aos-animate" id="jetbrains">
267+
<div class="icon-box d-flex align-items-center" data-aos="zoom-in" data-aos-delay="100">
264268
<div class="icon">
265269
<img src="https://resources.jetbrains.com/storage/products/company/brand/logos/jb_beam.svg" alt="JetBrains Logo" style="width:150px">
266270
</div>
267271
</div>
268272
</div>
269-
<div sponsor class="col-md-4 col-lg-3 d-flex align-items-stretch justify-content-center aos-init aos-animate" data-aos="zoom-in" data-aos-delay="100" id="araxis">
270-
<div class="icon-box d-flex align-items-center" style="background-color: rgb(116, 125, 139)">
273+
<div sponsor class="col-md-4 col-lg-3 d-flex align-items-stretch justify-content-center aos-init aos-animate" id="araxis">
274+
<div class="icon-box d-flex align-items-center" style="background-color: rgb(116, 125, 139)" data-aos="zoom-in" data-aos-delay="200">
271275
<div class="icon">
272276
<img src="https://www.araxis.com/theme/37/img/araxis-logo-lg.svg" alt="Araxis Logo" style="width:150px">
273277
</div>

docs/usage/writing/creating.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ POST /articles HTTP/1.1
1616
}
1717
```
1818

19-
When using client-generated IDs and only attributes from the request have changed, the server returns `204 No Content`.
20-
Otherwise, the server returns `200 OK`, along with the updated resource and its newly assigned ID.
19+
When using client-generated IDs and all attributes of the created resource are the same as in the request, the server
20+
returns `204 No Content`. Otherwise, the server returns `201 Created`, along with the stored attributes and its newly assigned ID.
2121

2222
In both cases, a `Location` header is returned that contains the URL to the new resource.
2323

package-versions.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<BenchmarkDotNetVersion>0.13.*</BenchmarkDotNetVersion>
1313
<BlushingPenguinVersion>1.0.*</BlushingPenguinVersion>
1414
<BogusVersion>35.2.*</BogusVersion>
15-
<CodeAnalysisVersion>4.8.*</CodeAnalysisVersion>
15+
<CodeAnalysisVersion>4.9.*</CodeAnalysisVersion>
1616
<CoverletVersion>6.0.*</CoverletVersion>
1717
<DapperVersion>2.1.*</DapperVersion>
1818
<FluentAssertionsVersion>6.12.*</FluentAssertionsVersion>

0 commit comments

Comments
 (0)