LCOV - code coverage report
Current view: top level - src/backend/access/rmgrdesc - logicalmsgdesc.c (source / functions) Hit Total Coverage
Test: PostgreSQL Lines: 0 12 0.0 %
Date: 2017-09-29 15:12:54 Functions: 0 2 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /*-------------------------------------------------------------------------
       2             :  *
       3             :  * logicalmsgdesc.c
       4             :  *    rmgr descriptor routines for replication/logical/message.c
       5             :  *
       6             :  * Portions Copyright (c) 2015-2017, PostgreSQL Global Development Group
       7             :  *
       8             :  *
       9             :  * IDENTIFICATION
      10             :  *    src/backend/access/rmgrdesc/logicalmsgdesc.c
      11             :  *
      12             :  *-------------------------------------------------------------------------
      13             :  */
      14             : #include "postgres.h"
      15             : 
      16             : #include "replication/message.h"
      17             : 
      18             : void
      19           0 : logicalmsg_desc(StringInfo buf, XLogReaderState *record)
      20             : {
      21           0 :     char       *rec = XLogRecGetData(record);
      22           0 :     uint8       info = XLogRecGetInfo(record) & ~XLR_INFO_MASK;
      23             : 
      24           0 :     if (info == XLOG_LOGICAL_MESSAGE)
      25             :     {
      26           0 :         xl_logical_message *xlrec = (xl_logical_message *) rec;
      27             : 
      28           0 :         appendStringInfo(buf, "%s message size %zu bytes",
      29           0 :                          xlrec->transactional ? "transactional" : "nontransactional",
      30             :                          xlrec->message_size);
      31             :     }
      32           0 : }
      33             : 
      34             : const char *
      35           0 : logicalmsg_identify(uint8 info)
      36             : {
      37           0 :     if ((info & ~XLR_INFO_MASK) == XLOG_LOGICAL_MESSAGE)
      38           0 :         return "MESSAGE";
      39             : 
      40           0 :     return NULL;
      41             : }

Generated by: LCOV version 1.11