Skip to content

Don't use timekey.object_id for Metadata instance comparison on Windows. Fix #2713#2778

Merged
cosmo0920 merged 1 commit into
masterfrom
do-not-use-hash-to-metadata-on-windows
Jan 17, 2020
Merged

Don't use timekey.object_id for Metadata instance comparison on Windows. Fix #2713#2778
cosmo0920 merged 1 commit into
masterfrom
do-not-use-hash-to-metadata-on-windows

Conversation

@cosmo0920

@cosmo0920 cosmo0920 commented Jan 16, 2020

Copy link
Copy Markdown
Contributor

Because this data will be differed unexpectedly on Windows.
This unexpected differing caused flood of buffer files
due to wrong metadata comparision.
hash method inside Metadata struct should be used on non-Windows environment.

This object_id value's unstability is monitored as follows:

{:timekey_object_id=>36247560}
{:timekey_object_id=>36247560}
{:timekey_object_id=>38199640}
{:timekey_object_id=>38199640}
{:timekey_object_id=>38199640}
{:timekey_object_id=>38240520}
{:timekey_object_id=>38240520}
{:timekey_object_id=>38240520}
{:timekey_object_id=>38277560}
{:timekey_object_id=>38277560}
{:timekey_object_id=>38277560}
{:timekey_object_id=>38314220}
{:timekey_object_id=>38314220}
{:timekey_object_id=>38314220}
{:timekey_object_id=>40539060}
{:timekey_object_id=>40539060}
{:timekey_object_id=>40539060}
{:timekey_object_id=>40598620}
{:timekey_object_id=>40598620}
{:timekey_object_id=>40598620}
{:timekey_object_id=>40764680}
{:timekey_object_id=>40764680}
{:timekey_object_id=>40764680}
{:timekey_object_id=>40613600}
{:timekey_object_id=>40613600}
{:timekey_object_id=>40613600}
{:timekey_object_id=>40741660}
{:timekey_object_id=>40741660}
{:timekey_object_id=>40741660}
{:timekey_object_id=>40895360}
{:timekey_object_id=>40895360}
{:timekey_object_id=>40895360}
{:timekey_object_id=>40926520}
<snip>

Signed-off-by: Hiroshi Hatake hatake@clear-code.com

Which issue(s) this PR fixes:
Fixes #2713

What this PR does / why we need it:
Prevent flood of buffer files which cause BufferOverflowError due to fd limit on Windows.

Docs Changes:
No need.

Release Note:
Same as title.

Because this data will be differed unexpectedly on Windows.
This unexpected differing caused flood of buffer files
due to wrong metadata comparision.
`hash` method inside Metadata struct should be used on non-Windows environment.

This object_id value's unstability is monitored as follows:

```
{:timekey_object_id=>36247560}
{:timekey_object_id=>36247560}
{:timekey_object_id=>38199640}
{:timekey_object_id=>38199640}
{:timekey_object_id=>38199640}
{:timekey_object_id=>38240520}
{:timekey_object_id=>38240520}
{:timekey_object_id=>38240520}
{:timekey_object_id=>38277560}
{:timekey_object_id=>38277560}
{:timekey_object_id=>38277560}
{:timekey_object_id=>38314220}
{:timekey_object_id=>38314220}
{:timekey_object_id=>38314220}
{:timekey_object_id=>40539060}
{:timekey_object_id=>40539060}
{:timekey_object_id=>40539060}
{:timekey_object_id=>40598620}
{:timekey_object_id=>40598620}
{:timekey_object_id=>40598620}
{:timekey_object_id=>40764680}
{:timekey_object_id=>40764680}
{:timekey_object_id=>40764680}
{:timekey_object_id=>40613600}
{:timekey_object_id=>40613600}
{:timekey_object_id=>40613600}
{:timekey_object_id=>40741660}
{:timekey_object_id=>40741660}
{:timekey_object_id=>40741660}
{:timekey_object_id=>40895360}
{:timekey_object_id=>40895360}
{:timekey_object_id=>40895360}
{:timekey_object_id=>40926520}
<snip>
```

Signed-off-by: Hiroshi Hatake <hatake@clear-code.com>
@cosmo0920 cosmo0920 requested a review from ganmacs January 16, 2020 07:30

@ganmacs ganmacs left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thank you!!!

@cosmo0920 cosmo0920 changed the title Don't use timekey.object_id for Metadata instance comparison. Fix #2713 Don't use timekey.object_id for Metadata instance comparison on Windows. Fix #2713 Jan 16, 2020
@cosmo0920 cosmo0920 self-assigned this Jan 16, 2020
@cosmo0920 cosmo0920 requested a review from repeatedly January 17, 2020 01:05
@cosmo0920 cosmo0920 merged commit cf2bc0b into master Jan 17, 2020
@cosmo0920 cosmo0920 deleted the do-not-use-hash-to-metadata-on-windows branch January 17, 2020 02:51
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.

Buffer's chunk_limit_size not working as expected on Windows platform

3 participants