[
https://issues.apache.org/jira/browse/HBASE-12454?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14205827#comment-14205827
]
Hadoop QA commented on HBASE-12454:
-----------------------------------
{color:green}+1 overall{color}. Here are the results of testing the latest
attachment
http://issues.apache.org/jira/secure/attachment/12680706/HBASE-12454.patch
against trunk revision .
ATTACHMENT ID: 12680706
{color:green}+1 @author{color}. The patch does not contain any @author
tags.
{color:green}+1 tests included{color}. The patch appears to include 4 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/11629//testReport/
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-prefix-tree.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-examples.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-common.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-annotations.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-hadoop-compat.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-rest.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-client.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-thrift.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-protocol.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-server.html
Findbugs warnings:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/newPatchFindbugsWarningshbase-hadoop2-compat.html
Checkstyle Errors:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//artifact/patchprocess/checkstyle-aggregate.html
Console output:
https://builds.apache.org/job/PreCommit-HBASE-Build/11629//console
This message is automatically generated.
> Setting didPerformCompaction early in HRegion#compact
> -----------------------------------------------------
>
> Key: HBASE-12454
> URL: https://issues.apache.org/jira/browse/HBASE-12454
> Project: HBase
> Issue Type: Bug
> Affects Versions: 0.98.8
> Reporter: Andrew Purtell
> Assignee: Andrew Purtell
> Fix For: 2.0.0, 0.98.8, 0.99.2
>
> Attachments: HBASE-12454.patch, HBASE-12454.patch
>
>
> It appears we are setting 'didPerformCompaction' to "true" before attempting
> the compaction in HRegion#compact. If Store#compact throws an exception or is
> interrupted, we won't call Store#cancelRequestedCompaction in the last
> finally block of the method as it looks like we should.
> {code}
> ---
> a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
> +++
> b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
> @@ -1540,58 +1540,58 @@ public class HRegion implements HeapSize,
> PropagatingConfigurationObserver {
> return false;
> }
>
> status = TaskMonitor.get().createStatus("Compacting " + store + " in "
> + this);
> if (this.closed.get()) {
> String msg = "Skipping compaction on " + this + " because closed";
> LOG.debug(msg);
> status.abort(msg);
> return false;
> }
> boolean wasStateSet = false;
> try {
> synchronized (writestate) {
> if (writestate.writesEnabled) {
> wasStateSet = true;
> ++writestate.compacting;
> } else {
> String msg = "NOT compacting region " + this + ". Writes
> disabled.";
> LOG.info(msg);
> status.abort(msg);
> return false;
> }
> }
> LOG.info("Starting compaction on " + store + " in region " + this
> + (compaction.getRequest().isOffPeak()?" as an off-peak
> compaction":""));
> doRegionCompactionPrep();
> try {
> status.setStatus("Compacting store " + store);
> - didPerformCompaction = true;
> store.compact(compaction);
> + didPerformCompaction = true;
> } catch (InterruptedIOException iioe) {
> String msg = "compaction interrupted";
> LOG.info(msg, iioe);
> status.abort(msg);
> return false;
> }
> } finally {
> if (wasStateSet) {
> synchronized (writestate) {
> --writestate.compacting;
> if (writestate.compacting <= 0) {
> writestate.notifyAll();
> }
> }
> }
> }
> status.markComplete("Compaction complete");
> return true;
> } finally {
> try {
> if (!didPerformCompaction)
> store.cancelRequestedCompaction(compaction); <-----
> if (status != null) status.cleanup();
> } finally {
> lock.readLock().unlock();
> }
> }
> }{code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)