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

fix restTime bug #954

Merged
merged 4 commits into from
May 3, 2019
Merged

fix restTime bug #954

merged 4 commits into from
May 3, 2019

Conversation

CoffeeLatte007
Copy link
Contributor

Ⅰ. Describe what this PR did

fix restTime bug

Ⅱ. Does this pull request fix one issue?

Ⅲ. Why don't you add test cases (unit test/integration test)?

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

@codecov-io
Copy link

codecov-io commented Apr 30, 2019

Codecov Report

Merging #954 into develop will decrease coverage by 0.06%.
The diff coverage is 100%.

Impacted file tree graph

@@              Coverage Diff              @@
##             develop     #954      +/-   ##
=============================================
- Coverage      37.17%   37.11%   -0.07%     
  Complexity      1027     1027              
=============================================
  Files            225      225              
  Lines           8906     8905       -1     
  Branches        1070     1070              
=============================================
- Hits            3311     3305       -6     
- Misses          5209     5212       +3     
- Partials         386      388       +2
Impacted Files Coverage Δ Complexity Δ
...in/java/io/seata/server/session/GlobalSession.java 84.35% <100%> (-1.76%) 50 <0> (ø)
...o/seata/server/coordinator/DefaultCoordinator.java 47.46% <0%> (-1.27%) 17% <0%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f4469ea...c9deada. Read the comment docs.

Copy link
Contributor

@nikyotensai nikyotensai left a comment

Choose a reason for hiding this comment

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

I think that the unit of restTime is wrong.Should change it to nanosecond?

@CoffeeLatte007
Copy link
Contributor Author

I think that the unit of restTime is wrong.Should change it to nanosecond?

why? mills is enough

@nikyotensai
Copy link
Contributor

I think that the unit of restTime is wrong.Should change it to nanosecond?

why? mills is enough

long parkTime = backOffTime < restTime ? backOffTime : restTime;
LockSupport.parkNanos(parkTime);

The unit between backOffTime and restTime is different.

@CoffeeLatte007
Copy link
Contributor Author

restTime

long parkTime = backOffTime < restTime ? backOffTime : restTime;
LockSupport.parkNanos(parkTime);

The unit between backOffTime and restTime is different.

I think that the unit of restTime is wrong.Should change it to nanosecond?

why? mills is enough

long parkTime = backOffTime < restTime ? backOffTime : restTime;
LockSupport.parkNanos(parkTime);

The unit between backOffTime and restTime is different.

yes , i will fix it

@CoffeeLatte007
Copy link
Contributor Author

I think that the unit of restTime is wrong.Should change it to nanosecond?

why? mills is enough

long parkTime = backOffTime < restTime ? backOffTime : restTime;
LockSupport.parkNanos(parkTime);

The unit between backOffTime and restTime is different.

i fix it, please review

@nikyotensai
Copy link
Contributor

I think that the unit of restTime is wrong.Should change it to nanosecond?

why? mills is enough

long parkTime = backOffTime < restTime ? backOffTime : restTime;
LockSupport.parkNanos(parkTime);

The unit between backOffTime and restTime is different.

i fix it, please review

The PARK_TIMES_BASE will be 1000 times of its original value,I'm not sure whether it is right or not.

@CoffeeLatte007
Copy link
Contributor Author

I think that the unit of restTime is wrong.Should change it to nanosecond?

why? mills is enough

long parkTime = backOffTime < restTime ? backOffTime : restTime;
LockSupport.parkNanos(parkTime);

The unit between backOffTime and restTime is different.

i fix it, please review

The PARK_TIMES_BASE will be 1000 times of its original value,I'm not sure whether it is right or not.

fix it PARK_TIMES_BASE_MILLS = 1

Copy link
Contributor

@nikyotensai nikyotensai left a comment

Choose a reason for hiding this comment

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

LGTM

@xingfudeshi xingfudeshi self-requested a review May 2, 2019 13:04
Copy link
Member

@slievrly slievrly left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@xingfudeshi xingfudeshi left a comment

Choose a reason for hiding this comment

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

LGTM.

@xingfudeshi xingfudeshi merged commit 32cea2e into apache:develop May 3, 2019
nick-tan pushed a commit to nick-tan/seata that referenced this pull request Jul 12, 2019
@wangliang181230 wangliang181230 added this to the 0.5.* milestone Aug 9, 2021
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.

6 participants