[ 
https://issues.apache.org/jira/browse/HBASE-15218?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15134744#comment-15134744
 ] 

stack commented on HBASE-15218:
-------------------------------

[~ram_krish]  But I think that will happen only when replaying the WAL and 
should not have much impact.

Yeah, exactly, that was my concern.

So looking in KeyValueCodecWithTags, only difference that I see is in the 
encoder. It sets true on this line:

      KeyValueUtil.oswrite(cell, out, true);

So now we write tags where before we didn't. If tags present, we'll write and 
read slower but default case will be as it was.

This KeyValueCodecWithTags dups most of KeyValueCodec. Can we fix that? Or, can 
we just have KeyValueCodec and do away with this 'withTags'... at least going 
forward.

I did a more extensive compare of before and after patch passing 
WALPrettyPrinter 30 WALs to get a longer run in. There is no diff (we should 
work on those branch misses and cs counts):

Before
{code}

 Performance counter stats for './hbase/bin/hbase --config 
/home/stack/conf_hbase org.apache.hadoop.hbase.wal.WALPrettyPrinter ....

     467491.668911 task-clock                #    1.277 CPUs utilized
           239,096 context-switches          #    0.511 K/sec
            22,701 cpu-migrations            #    0.049 K/sec
           107,307 page-faults               #    0.230 K/sec
 1,168,798,024,496 cycles                    #    2.500 GHz
   <not supported> stalled-cycles-frontend
   <not supported> stalled-cycles-backend
 2,398,911,354,038 instructions              #    2.05  insns per cycle
   467,617,537,336 branches                  # 1000.269 M/sec
     1,252,456,504 branch-misses             #    0.27% of all branches

     366.201978093 seconds time elapsed
{code}

After (with patch)
{code}
perf stat ./hbase/bin/hbase --config ~/conf_hbase 
org.apache.hadoop.hbase.wal.WALPrettyPrinter `cat /tmp/x.txt` > /dev/null
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in 
[jar:file:/home/stack/hbase-1.2.0/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in 
[jar:file:/home/stack/hadoop-2.7.0-SNAPSHOT/share/hadoop/common/lib/slf4j-log4j12-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]





 Performance counter stats for './hbase/bin/hbase --config 
/home/stack/conf_hbase org.apache.hadoop.hbase.wal.WALPrettyPrinter  ....
     465647.060002 task-clock                #    1.284 CPUs utilized
           238,915 context-switches          #    0.513 K/sec
            22,223 cpu-migrations            #    0.048 K/sec
            99,487 page-faults               #    0.214 K/sec
 1,160,328,822,985 cycles                    #    2.492 GHz
   <not supported> stalled-cycles-frontend
   <not supported> stalled-cycles-backend
 2,401,013,786,251 instructions              #    2.07  insns per cycle
   467,104,149,437 branches                  # 1003.129 M/sec
     1,232,205,021 branch-misses             #    0.26% of all branches

     362.517152719 seconds time elapsed
{code}




> On RS crash and replay of WAL, loosing all Tags in Cells
> --------------------------------------------------------
>
>                 Key: HBASE-15218
>                 URL: https://issues.apache.org/jira/browse/HBASE-15218
>             Project: HBase
>          Issue Type: Bug
>          Components: Recovery, regionserver, security
>    Affects Versions: 2.0.0, 0.98.13, 1.0.2, 1.2.0, 1.1.1
>            Reporter: Anoop Sam John
>            Assignee: Anoop Sam John
>            Priority: Blocker
>             Fix For: 2.0.0, 1.2.0, 1.3.0, 1.1.4, 1.0.4, 0.98.18
>
>         Attachments: HBASE-15218-0.98.patch, HBASE-15218-branch-1.1.patch, 
> HBASE-15218-branch-1.2.patch, HBASE-15218.patch
>
>
> The KeyValueCodec's Decoder makes NoTagsKeyValue. The WalCellCodec also makes 
> this Decoder and so while reading Cells after RS crash, we will loose all 
> tags in Cells.



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

Reply via email to