[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-30 Thread Hudson (JIRA)

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

Hudson commented on HBASE-4032:
---

Integrated in HBase-TRUNK #2065 (See 
[https://builds.apache.org/job/HBase-TRUNK/2065/])
HBASE-4032 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

tedyu : 
Files : 
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/HRegionInfo.java
* /hbase/trunk/CHANGES.txt
* 
/hbase/trunk/src/test/java/org/apache/hadoop/hbase/regionserver/TestHRegionInfo.java


 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032-v2.txt, 4032-v3.txt, 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-29 Thread stack (JIRA)

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

stack commented on HBASE-4032:
--

Need a review please (and someone to commit if +1)

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032-v2.txt, 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-29 Thread Ted Yu (JIRA)

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

Ted Yu commented on HBASE-4032:
---

There is already hbase/regionserver/TestHRegionInfo.java
Shall we name the test as hbase/regionserver/TestTableDescOfHRegionInfo.java ?

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032-v2.txt, 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-29 Thread stack (JIRA)

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

stack commented on HBASE-4032:
--

Thats my bad.  Copy the method from o.a.h.h.THRI into o.a.h.h.r.THRI?

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032-v2.txt, 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-28 Thread Andrew Purtell (JIRA)

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

Andrew Purtell commented on HBASE-4032:
---

It is not deprecation to actually break a method until after a release cycle 
where the API in question is marked as deprecated. So either we agree that 
public APIs get deprecated, or our users have to assume that anything 
arbitrarily can break at every release.

Returning null from a method that used to return a valid object is a no no. 
Substituting something that produces the same result but is more expensive is 
acceptable.

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-28 Thread Andrew Purtell (JIRA)

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

Andrew Purtell commented on HBASE-4032:
---

bq. Substituting something that produces the same result but is more expensive 
is acceptable.

To be clear I mean the existing API stays in place, the thing you want to 
deprecate gets decorated with @Deprecated, and the implementation of it can 
change to do something expensive as necessary to maintain the current contract.

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-28 Thread stack (JIRA)

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

stack commented on HBASE-4032:
--

np. let me fix.

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-28 Thread Gary Helmling (JIRA)

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

Gary Helmling commented on HBASE-4032:
--

{quote}
Returning null from a method that used to return a valid object is a no no. 
Substituting something that produces the same result but is more expensive is 
acceptable.
{quote}

I agree.  I would much rather have the deprecated method result in a expensive 
call which we can provide a javadoc warning for.

Returning null forces any users to deal with a runtime issue with no warning 
due to the change.  I would rather even see us make a one-time exception to the 
deprecation rule and remove the the method entirely.  At least then it could be 
dealt with as a compile time issue.

But would be best if we can keep the functionality in place as deprecated, even 
if it's a bit ugly and expensive.  Then we can remove on next release.

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-27 Thread Ted Yu (JIRA)

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

Ted Yu commented on HBASE-4032:
---

The most common usage of HRegionInfo#getTableDesc is 
hri.getTableDesc().getNameAsString() which has equivalent in TRUNK already.
I think HRegionInfo#getTableDesc returning null is a fail-fast approach so that 
the caller knows alternative should be sought. This is better than a temporary 
solution which would cause performance issue.

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-27 Thread stack (JIRA)

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

stack commented on HBASE-4032:
--

Whats the equivalent Ted?

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-27 Thread Ted Yu (JIRA)

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

Ted Yu commented on HBASE-4032:
---

HRegionInfo#getTableNameAsString() can be used in place of 
hri.getTableDesc().getNameAsString()


 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-27 Thread stack (JIRA)

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

stack commented on HBASE-4032:
--

I could note that in the deprecated note AND leave this expensive call in place

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0

 Attachments: 4032.txt


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-05 Thread Ted Yu (JIRA)

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

Ted Yu commented on HBASE-4032:
---

HBASE-451 is an incompatible change.
I wonder why HRegionInfo#getTableDesc should return a meaningful table 
descriptor after the change where HRegionInfo no longer keeps reference to 
table descriptor.

Unit test code has been retrofitted to not depend on HRegionInfo#getTableDesc.
I doubt user would write code that explicitly uses HRegionInfo#getTableDesc.

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-07-05 Thread Ted Yu (JIRA)

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

Ted Yu commented on HBASE-4032:
---

I am not sure Andrew wanted a 'hack' when he created this JIRA.

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HBASE-4032) HBASE-451 improperly breaks public API HRegionInfo#getTableDesc

2011-06-24 Thread stack (JIRA)

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

stack commented on HBASE-4032:
--

Let me fix this.   Thanks for fingering it Andy 

 HBASE-451 improperly breaks public API HRegionInfo#getTableDesc
 ---

 Key: HBASE-4032
 URL: https://issues.apache.org/jira/browse/HBASE-4032
 Project: HBase
  Issue Type: Bug
Reporter: Andrew Purtell
Assignee: stack
Priority: Blocker
 Fix For: 0.92.0


 After HBASE-451, HRegionInfo#getTableDesc has been modified to always return 
 {{null}}. 
 One immediate effect is broken unit tests.
 That aside, it is not in the spirit of deprecation to actually break the 
 method until after the deprecation cycle, it's a bug.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira