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

Close iterator properly #2333

Merged
merged 5 commits into from
Mar 31, 2023
Merged

Close iterator properly #2333

merged 5 commits into from
Mar 31, 2023

Conversation

AlekSi
Copy link
Member

@AlekSi AlekSi commented Mar 30, 2023

Description

Closes #2330.

This PR doesn't have code/bug Some user-visible feature works incorrectly label because #2330 wasn't released yet.

Readiness checklist

  • I added/updated unit tests.
  • I added/updated integration/compatibility tests.
  • I added/updated comments and checked rendering.
  • I made spot refactorings.
  • I updated user documentation.
  • I ran task all, and it passed.
  • I ensured that PR title is good enough for the changelog.
  • (for maintainers only) I set Reviewers (@FerretDB/core), Assignee, Labels, Project and project's Sprint fields.
  • I marked all done items in this checklist.

@AlekSi AlekSi added code/chore Code maintenance improvements no ci labels Mar 30, 2023
@AlekSi AlekSi added this to the v1.0.0 GA milestone Mar 30, 2023
@AlekSi AlekSi self-assigned this Mar 30, 2023
@AlekSi AlekSi marked this pull request as ready for review March 30, 2023 15:42
@AlekSi AlekSi requested a review from a team as a code owner March 30, 2023 15:42
@AlekSi AlekSi enabled auto-merge (squash) March 30, 2023 15:42
@AlekSi AlekSi removed the no ci label Mar 30, 2023
@AlekSi AlekSi requested review from a team and noisersup March 30, 2023 15:43
Copy link
Contributor

@w84thesun w84thesun left a comment

Choose a reason for hiding this comment

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

Tests fail, looks like we don't handle errors correctly from projections.

integration/query_projection_test.go Outdated Show resolved Hide resolved
@AlekSi
Copy link
Member Author

AlekSi commented Mar 30, 2023

Tests passes for me, and the CI failure looks sus:

task: [test-integration-pg] go test -count=1 -timeout=30m -race=true -tags=ferretdb_debug,ferretdb_tigris,ferretdb_hana -shuffle=on -coverpkg=../... -coverprofile=integration-pg.txt . -target-backend=ferretdb-pg -target-tls -postgresql-url=postgres://username@127.0.0.1:5432/ferretdb -compat-url='***127.0.0.1:47018/?tls=true&tlsCertificateKeyFile=../build/certs/client.pem&tlsCaFile=../build/certs/rootCA-cert.pem'

2023-03-30T15:55:36.171Z	INFO	setup/startup.go:68	Target system: ferretdb-pg (built-in).
2023-03-30T15:55:36.172Z	INFO	debug	debug/debug.go:95	Starting debug server on http://127.0.0.1:41309/
2023-03-30T15:55:36.323Z	INFO	setup/startup.go:79	Compat system: MongoDB (***127.0.0.1:47018/?tls=true&tlsCertificateKeyFile=../build/certs/client.pem&tlsCaFile=../build/certs/rootCA-cert.pem).
-test.shuffle 1680191736324234125
FAIL

There is no error output…

@AlekSi AlekSi requested review from w84thesun, chilagrow and a team March 31, 2023 10:01
@codecov
Copy link

codecov bot commented Mar 31, 2023

Codecov Report

Merging #2333 (ec9e22b) into main (307c516) will decrease coverage by 7.98%.
The diff coverage is 81.81%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2333      +/-   ##
==========================================
- Coverage   71.55%   63.57%   -7.98%     
==========================================
  Files         382      382              
  Lines       18103    18113      +10     
==========================================
- Hits        12954    11516    -1438     
- Misses       4110     5712    +1602     
+ Partials     1039      885     -154     
Impacted Files Coverage Δ
internal/handlers/tigris/msg_find.go 0.00% <0.00%> (-76.24%) ⬇️
internal/handlers/common/sort_iterator.go 100.00% <100.00%> (ø)
internal/handlers/pg/msg_find.go 70.40% <100.00%> (+0.48%) ⬆️

... and 54 files with indirect coverage changes

Flag Coverage Δ
integration 56.06% <81.81%> (-11.42%) ⬇️
mongodb 4.94% <0.00%> (-0.01%) ⬇️
pg 55.98% <81.81%> (+0.01%) ⬆️
tigris ?
unit 26.88% <0.00%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

@AlekSi AlekSi merged commit 538de1b into FerretDB:main Mar 31, 2023
@AlekSi AlekSi deleted the fix-crash branch March 31, 2023 10:58
efirs added a commit to tigrisdata-archive/ferretdb that referenced this pull request Apr 11, 2023
v1.0.0
https://github.com/FerretDB/FerretDB/releases/tag/v1.0.0
2023-04-03

We are delighted to announce the release of FerretDB 1.0 GA!

* Support `$sum` accumulator of `$group` aggregation by @chilagrow in FerretDB#2292
* Implement `createIndexes` command by @rumyantseva in FerretDB#2244
* Add basic `getMore` command by @AlekSi in FerretDB#2309
* Implement `dropIndexes` command by @chilagrow in FerretDB#2313
* Implement `$limit` aggregation pipeline stage by @noisersup in FerretDB#2270
* Add partial support for `collStats`, `dbStats` and `dataSize` by @AlekSi in FerretDB#2322
* Implement `$skip` aggregation pipeline stage by @w84thesun in FerretDB#2310
* Implement `$unwind` aggregation pipeline stage by @noisersup in FerretDB#2294
* Support `count` and `storageStats` fields in `$collStats` aggregation pipeline stage by @rumyantseva in FerretDB#2338

* Fix dot notation negative index errors by @w84thesun in FerretDB#2246
* Apply `skip` before `limit` by @AlekSi in FerretDB#2351

* Update supported command for `$sum` aggregation operator by @chilagrow in FerretDB#2318
* Add supported shells and GUIs images by @AlekSi in FerretDB#2323
* Publish FerretDB v0.9.4 blog post by @Fashander in FerretDB#2268
* Use dashes instead of underscores or spaces by @AlekSi in FerretDB#2329
* Update documentation sidebar by @Fashander in FerretDB#2347
* Update FerretDB descriptions by @AlekSi in FerretDB#2281
* Improve flags documentation by @AlekSi in FerretDB#2331
* Describe supported fields for `$collStats` aggregation stage by @rumyantseva in FerretDB#2352

* Use iterators for `sort`, `limit`, `skip`, and `projection` by @AlekSi in FerretDB#2254
* Bump dependencies by @AlekSi in FerretDB#2307
* Improve resource tracking by @AlekSi in FerretDB#2319
* Add tests for `find`'s and `count`'s `skip` argument by @w84thesun in FerretDB#2325
* Close iterator properly by @AlekSi in FerretDB#2333
* Improve large numbers initialization in test data by @noisersup in FerretDB#2324
* Ignore `unique` index option for now by @AlekSi in FerretDB#2350

All closed issues and pull requests: https://github.com/FerretDB/FerretDB/milestone/39?closed=1
All commits: FerretDB/FerretDB@v0.9.4...v1.0.0
efirs added a commit to tigrisdata-archive/ferretdb that referenced this pull request Apr 11, 2023
v1.0.0
https://github.com/FerretDB/FerretDB/releases/tag/v1.0.0
2023-04-03

We are delighted to announce the release of FerretDB 1.0 GA!

* Support `$sum` accumulator of `$group` aggregation by @chilagrow in FerretDB#2292
* Implement `createIndexes` command by @rumyantseva in FerretDB#2244
* Add basic `getMore` command by @AlekSi in FerretDB#2309
* Implement `dropIndexes` command by @chilagrow in FerretDB#2313
* Implement `$limit` aggregation pipeline stage by @noisersup in FerretDB#2270
* Add partial support for `collStats`, `dbStats` and `dataSize` by @AlekSi in FerretDB#2322
* Implement `$skip` aggregation pipeline stage by @w84thesun in FerretDB#2310
* Implement `$unwind` aggregation pipeline stage by @noisersup in FerretDB#2294
* Support `count` and `storageStats` fields in `$collStats` aggregation pipeline stage by @rumyantseva in FerretDB#2338

* Fix dot notation negative index errors by @w84thesun in FerretDB#2246
* Apply `skip` before `limit` by @AlekSi in FerretDB#2351

* Update supported command for `$sum` aggregation operator by @chilagrow in FerretDB#2318
* Add supported shells and GUIs images by @AlekSi in FerretDB#2323
* Publish FerretDB v0.9.4 blog post by @Fashander in FerretDB#2268
* Use dashes instead of underscores or spaces by @AlekSi in FerretDB#2329
* Update documentation sidebar by @Fashander in FerretDB#2347
* Update FerretDB descriptions by @AlekSi in FerretDB#2281
* Improve flags documentation by @AlekSi in FerretDB#2331
* Describe supported fields for `$collStats` aggregation stage by @rumyantseva in FerretDB#2352

* Use iterators for `sort`, `limit`, `skip`, and `projection` by @AlekSi in FerretDB#2254
* Bump dependencies by @AlekSi in FerretDB#2307
* Improve resource tracking by @AlekSi in FerretDB#2319
* Add tests for `find`'s and `count`'s `skip` argument by @w84thesun in FerretDB#2325
* Close iterator properly by @AlekSi in FerretDB#2333
* Improve large numbers initialization in test data by @noisersup in FerretDB#2324
* Ignore `unique` index option for now by @AlekSi in FerretDB#2350

All closed issues and pull requests: https://github.com/FerretDB/FerretDB/milestone/39?closed=1
All commits: FerretDB/FerretDB@v0.9.4...v1.0.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code/chore Code maintenance improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Profling causes a panic with relative ease
3 participants