Skip to content

[JBIDE-22127] chanch WatchClient synch blocks to minimize blocking#145

Closed
jcantrill wants to merge 1 commit intoopenshift:masterfrom
jcantrill:22127_watch_blocked
Closed

[JBIDE-22127] chanch WatchClient synch blocks to minimize blocking#145
jcantrill wants to merge 1 commit intoopenshift:masterfrom
jcantrill:22127_watch_blocked

Conversation

@jcantrill
Copy link
Copy Markdown
Contributor

@jcantrill
Copy link
Copy Markdown
Contributor Author

[test]

@jcantrill jcantrill force-pushed the 22127_watch_blocked branch 3 times, most recently from f472fed to aa4bed8 Compare April 6, 2016 20:42
@jcantrill jcantrill force-pushed the 22127_watch_blocked branch from aa4bed8 to 402517e Compare April 6, 2016 21:00
@openshift-bot
Copy link
Copy Markdown
Contributor

Evaluated for javaclient test up to 402517e

@openshift-bot
Copy link
Copy Markdown
Contributor

@fbricon
Copy link
Copy Markdown
Contributor

fbricon commented Apr 6, 2016

Seems much faster now and I couldn't reproduce any blocking issue. So that counts as +1 from me.

@scabanovich, @alexeykazakov, @adietish, @jeffmaury any 2nd opinion on this change?

@adietish
Copy link
Copy Markdown
Member

adietish commented Apr 7, 2016

this requires us to deploy a 4.0.2.Final artifact to repository.jboss.org and reference it in JBoss Tools.

lockTimeout = Long.parseLong(System.getProperty("com.openshift.restclient.watchlocktimeoutms", "30000"));
}catch(NumberFormatException e) {
lockTimeout = 30 * 1000;
}
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.

can we please extract this try/catch-block to a method with a speaking name like #getLockTimeout?

@adietish
Copy link
Copy Markdown
Member

adietish commented Apr 7, 2016

i made my suggested changes in #146

} catch (Exception e) {
throw createOpenShiftException(String.format("Could not start watchClient"),e);
}
if(status.get().equals(Status.Started) || status.get().equals(Status.Starting)) {
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.

enums should be compared with ==, no #equals, like you already do when starting (line 210)

@adietish
Copy link
Copy Markdown
Member

adietish commented Apr 7, 2016

supplanted by #146 with minor changes

@adietish adietish closed this Apr 7, 2016
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.

4 participants