[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-27 Thread Nicolas Liochon (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14227721#comment-14227721
 ] 

Nicolas Liochon commented on HBASE-12557:
-

bq.  Still looking for a way to make lengthy DNS related call.
kill suspend (-STOP) the dns process should do it?

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-27 Thread Andrew Purtell (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14227759#comment-14227759
 ] 

Andrew Purtell commented on HBASE-12557:


This is for a unit test. I think you can mock the resolver class with Mockito 
and add a sleep() before calling the real method. 

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-27 Thread Nicolas Liochon (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14227785#comment-14227785
 ] 

Nicolas Liochon commented on HBASE-12557:
-

Agreed (or you can add a hook to ease tests, this save you from using mockito). 
If you want to test that we don't leak resources (i.e. that the dns client 
implementation supports correctly an interruption), then you can't do that but 
it will be an integration test then

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-27 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14227979#comment-14227979
 ] 

Hadoop QA commented on HBASE-12557:
---

{color:green}+1 overall{color}.  Here are the results of testing the latest 
attachment 
  http://issues.apache.org/jira/secure/attachment/12684094/12557-v3.txt
  against master branch at commit 0f8894cd6435ed6962ec3d7c81be4cb0d4f7657e.
  ATTACHMENT ID: 12684094

{color:green}+1 @author{color}.  The patch does not contain any @author 
tags.

{color:green}+1 tests included{color}.  The patch appears to include 3 new 
or modified tests.

{color:green}+1 javac{color}.  The applied patch does not increase the 
total number of javac compiler warnings.

{color:green}+1 javac{color}.  The applied patch does not increase the 
total number of javac compiler warnings.

{color:green}+1 javadoc{color}.  The javadoc tool did not generate any 
warning messages.

{color:green}+1 checkstyle{color}.  The applied patch does not increase the 
total number of checkstyle errors

{color:green}+1 findbugs{color}.  The patch does not introduce any new 
Findbugs (version 2.0.3) warnings.

{color:green}+1 release audit{color}.  The applied patch does not increase 
the total number of release audit warnings.

{color:green}+1 lineLengths{color}.  The patch does not introduce lines 
longer than 100

  {color:green}+1 site{color}.  The mvn site goal succeeds with this patch.

{color:green}+1 core tests{color}.  The patch passed unit tests in .

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//testReport/
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-hadoop-compat.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-prefix-tree.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-examples.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-server.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-common.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-rest.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-protocol.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-client.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-thrift.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-hadoop2-compat.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/newPatchFindbugsWarningshbase-annotations.html
Checkstyle Errors: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//artifact/patchprocess/checkstyle-aggregate.html

  Console output: 
https://builds.apache.org/job/PreCommit-HBASE-Build/11856//console

This message is automatically generated.

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt, 12557-v3.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-21 Thread Andrew Purtell (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14221636#comment-14221636
 ] 

Andrew Purtell commented on HBASE-12557:


Spelling error DETEMINDER

Missing a test that this actually works

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-21 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14221641#comment-14221641
 ] 

Ted Yu commented on HBASE-12557:


Good catch, Andrew. Corrected the typo.

As for the test, I am looking among related hadoop tests to see if I can find 
something.

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-21 Thread stack (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14221643#comment-14221643
 ] 

stack commented on HBASE-12557:
---

I'd suggest also breaking dns so you get long timeout and seeing if the cancel 
actual cancels the ongoing lookup and doesn't leave resources laying around

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-21 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14221654#comment-14221654
 ] 

Ted Yu commented on HBASE-12557:


Browsed through hadoop tests, such as TestJobHistoryParsing, which use custom 
resolver.
In the new test for this JIRA, I can issue long I/O operation in the resolve() 
method and see if the cancellation works.

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (HBASE-12557) Introduce timeout mechanism for IP to rack resolution

2014-11-21 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-12557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14221810#comment-14221810
 ] 

Ted Yu commented on HBASE-12557:


ThreadPoolExecutor can provide count of threads that are executing tasks.

In the following code:
{code}
  InetSocketAddress isa = new InetSocketAddress(zxy.org, 321);
  try {
InetAddress addr = isa.getAddress();
String ipAddressString = DNS.reverseDns(addr, null);
{code}
if I replace zxy.org with zxyy.org , isa.getAddress() returns null.
Still looking for a way to make lengthy DNS related call.

 Introduce timeout mechanism for IP to rack resolution
 -

 Key: HBASE-12557
 URL: https://issues.apache.org/jira/browse/HBASE-12557
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 12557-v1.txt


 Config parameter, hbase.util.ip.to.rack.determiner, determines the class 
 which does IP to rack resolution.
 The actual resolution may be lengthy.
 This JIRA is continuation of HBASE-12554 where a mock DNSToSwitchMapping is 
 used for rack resolution.
 A timeout parameter, hbase.ip.to.rack.determiner.timeout, is proposed whose 
 value governs the duration which RackManager waits before rack resolution is 
 stopped.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)