LCOV - differential code coverage report
Current view: top level - src/backend/access/rmgrdesc - replorigindesc.c (source / functions) Coverage Total Hit UNC UBC DUB
Current: c70b6db34ffeab48beef1fb4ce61bcad3772b8dd vs 06473f5a344df8c9594ead90a609b86f6724cff8 Lines: 0.0 % 24 0 1 23 1
Current Date: 2025-09-06 07:49:51 +0900 Functions: 0.0 % 2 0 1 1
Baseline: lcov-20250906-005545-baseline Branches: 0.0 % 6 0 6
Baseline Date: 2025-09-05 08:21:35 +0100 Line coverage date bins:
Legend: Lines:     hit not hit
Branches: + taken - not taken # not executed
(30,360] days: 0.0 % 1 0 1
(360..) days: 0.0 % 23 0 23
Function coverage date bins:
(360..) days: 0.0 % 2 0 1 1
Branch coverage date bins:
(360..) days: 0.0 % 6 0 6

 Age         Owner                    Branch data    TLA  Line data    Source code
                                  1                 :                : /*-------------------------------------------------------------------------
                                  2                 :                :  *
                                  3                 :                :  * replorigindesc.c
                                  4                 :                :  *    rmgr descriptor routines for replication/logical/origin.c
                                  5                 :                :  *
                                  6                 :                :  * Portions Copyright (c) 2015-2025, PostgreSQL Global Development Group
                                  7                 :                :  *
                                  8                 :                :  *
                                  9                 :                :  * IDENTIFICATION
                                 10                 :                :  *    src/backend/access/rmgrdesc/replorigindesc.c
                                 11                 :                :  *
                                 12                 :                :  *-------------------------------------------------------------------------
                                 13                 :                :  */
                                 14                 :                : #include "postgres.h"
                                 15                 :                : 
                                 16                 :                : #include "replication/origin.h"
                                 17                 :                : 
                                 18                 :                : void
 3783 andres@anarazel.de         19                 :UBC           0 : replorigin_desc(StringInfo buf, XLogReaderState *record)
                                 20                 :                : {
                                 21                 :              0 :     char       *rec = XLogRecGetData(record);
                                 22                 :              0 :     uint8       info = XLogRecGetInfo(record) & ~XLR_INFO_MASK;
                                 23                 :                : 
                                 24      [ #  #  # ]:              0 :     switch (info)
                                 25                 :                :     {
                                 26                 :              0 :         case XLOG_REPLORIGIN_SET:
                                 27                 :                :             {
                                 28                 :                :                 xl_replorigin_set *xlrec;
                                 29                 :                : 
                                 30                 :              0 :                 xlrec = (xl_replorigin_set *) rec;
                                 31                 :                : 
   61 alvherre@kurilemu.de       32                 :UNC           0 :                 appendStringInfo(buf, "set %u; lsn %X/%08X; force: %d",
 3783 andres@anarazel.de         33                 :UBC           0 :                                  xlrec->node_id,
 1656 peter@eisentraut.org       34                 :              0 :                                  LSN_FORMAT_ARGS(xlrec->remote_lsn),
 3783 andres@anarazel.de         35                 :              0 :                                  xlrec->force);
                                 36                 :              0 :                 break;
                                 37                 :                :             }
                                 38                 :              0 :         case XLOG_REPLORIGIN_DROP:
                                 39                 :                :             {
                                 40                 :                :                 xl_replorigin_drop *xlrec;
                                 41                 :                : 
                                 42                 :              0 :                 xlrec = (xl_replorigin_drop *) rec;
                                 43                 :                : 
                                 44                 :              0 :                 appendStringInfo(buf, "drop %u", xlrec->node_id);
                                 45                 :              0 :                 break;
                                 46                 :                :             }
                                 47                 :                :     }
                                 48                 :              0 : }
                                 49                 :                : 
                                 50                 :                : const char *
                                 51                 :              0 : replorigin_identify(uint8 info)
                                 52                 :                : {
                                 53      [ #  #  # ]:              0 :     switch (info)
                                 54                 :                :     {
                                 55                 :              0 :         case XLOG_REPLORIGIN_SET:
                                 56                 :              0 :             return "SET";
                                 57                 :              0 :         case XLOG_REPLORIGIN_DROP:
                                 58                 :              0 :             return "DROP";
                                 59                 :              0 :         default:
                                 60                 :              0 :             return NULL;
                                 61                 :                :     }
                                 62                 :                : }
        

Generated by: LCOV version 2.4-beta