@@ -309,19 +309,12 @@ class XAPrepareEvent(BinLogEvent):
309309 An XA prepare event is generated for a XA prepared transaction.
310310 Like Xid_event, it contains XID of the **prepared** transaction.
311311
312- For more information: `[see details] <https://dev.mysql.com/doc/refman/8.0/en/xa-statements.html>`_.
313-
314- <<<<<<< HEAD
315- :ivar one_phase: current XA transaction commit method
316- :ivar xid_format_id: a number that identifies the format used by the gtrid and bqual values
317- :ivar xid: serialized XID representation of XA transaction (xid_gtrid + xid_bqual)
318- =======
319- In detail, the class creates the following python objects in the constructor:
312+ For more information: `[see XAPrepareEvent] <https://dev.mysql.com/doc/refman/8.0/en/xa-statements.html>`_.
320313
321314 :ivar one_phase: str - current XA transaction commit method
322315 :ivar xid_format_id: int - a number that identifies the format used by the gtrid and bqual values
323316 :ivar xid: str - serialized XID representation of XA transaction (xid_gtrid + xid_bqual)
324- >>>>>>> 07b561d (add type hints to the rest of the events, improve docstring readability in some events)
317+
325318 """
326319 def __init__ (self ,
327320 from_packet : Type [MysqlPacket ],
@@ -354,35 +347,14 @@ def _dump(self) -> None:
354347
355348class FormatDescriptionEvent (BinLogEvent ):
356349 """
357- <<<<<<< HEAD
358- Represents a Format Description Event in the MySQL binary log.
350+ The event Represents a Format Description Event in the MySQL binary log.
359351
360352 This event is written at the start of a binary log file for binlog version 4.
361353 It provides the necessary information to decode subsequent events in the file.
362354
363355 :ivar binlog_version: int - Version of the binary log format.
364356 :ivar mysql_version_str: str - Server's MySQL version in string format.
365357 """
366-
367- def __init__ (self , from_packet , event_size , table_map , ctl_connection , ** kwargs ):
368- super ().__init__ (from_packet , event_size , table_map ,
369- ctl_connection , ** kwargs )
370- self .binlog_version = struct .unpack ('<H' , self .packet .read (2 ))
371- self .mysql_version_str = self .packet .read (50 ).rstrip (b'\0 ' ).decode ()
372- numbers = self .mysql_version_str .split ('-' )[0 ]
373- self .mysql_version = tuple (map (int , numbers .split ('.' )))
374- == == == =
375- The event represents a Format Description Event in the MySQL binary log .
376-
377- This event is written at the start of a binary log file for binlog version 4.
378- It provides the necessary information to decode subsequent events in the file .
379-
380- In detail , the class creates the following python objects in the constructor :
381- >> >> >> > 07 b561d (add type hints to the rest of the events , improve docstring readability in some events )
382-
383- :ivar binlog_version : str - Version of the binary log format
384- :ivar mysql_version_str : str - Server 's MySQL version in string format
385- """
386358 def __init__ (self ,
387359 from_packet : Type [MysqlPacket ],
388360 event_size : int ,
@@ -409,22 +381,12 @@ class StopEvent(BinLogEvent):
409381class XidEvent (BinLogEvent ):
410382< << << << HEAD
411383 """
412- A COMMIT event generated when COMMIT of a transaction that modifies one or more tables of an XA - capable storage engine occurs .
413-
414- For more information : `[see details] <https://mariadb.com/kb/en/xid_event/>` _ .
415-
416- :ivar xid : uint - Transaction ID for 2 Phase Commit .
417- == == == =
418- >> > >> > > 07 b561d (add type hints to the rest of the events , improve docstring readability in some events )
419- """
420- A COMMIT event is generated when COMMIT of a transaction that modifies
384+ A COMMIT event generated when COMMIT of a transaction that modifies
421385 one or more tables of an XA-capable storage engine occurs.
422386
423- For more information : `[see details ] <https://mariadb.com/kb/en/xid_event/>`_.
387+ For more information: `[see XidEvent ] <https://mariadb.com/kb/en/xid_event/>`_.
424388
425- In detail, the class creates the following python objects in the constructor:
426-
427- :ivar xid: int - Transaction ID for 2 Phase Commit
389+ :ivar xid: uint - Transaction ID for 2 Phase Commit.
428390 """
429391 def __init__ (self ,
430392 from_packet : Type [MysqlPacket ],
@@ -457,19 +419,11 @@ class HeartbeatLogEvent(BinLogEvent):
457419 (see Binlog_sender::send_events in sql/rpl_binlog_sender.cc)
458420
459421 Warning:
460- <<<<<<< HEAD
461422 That makes 106 bytes of data for skipped event in the binlog.
462423 *this is also the case with GTID replication*.
463424 To mitigate such behavior, you are expected to keep the binlog small
464425 (see max_binlog_size, defaults to 1G).
465426 In any case, the timestamp is 0 (as in 1970-01-01T00:00:00).
466- =======
467- That makes 106 bytes of data for skipped event in the binlog.
468- *this is also the case with GTID replication*.
469- To mitigate such behavior, you are expected to keep the binlog small
470- (see max_binlog_size, defaults to 1G).
471- In any case, the timestamp is 0 (as in 1970-01-01T00:00:00).
472- >>>>>>> 07b561d (add type hints to the rest of the events, improve docstring readability in some events)
473427
474428 In detail, the class creates the following python objects in the constructor:
475429
@@ -532,15 +486,9 @@ def __init__(self,
532486 self .schema : str = self .packet .read (self .schema_length )
533487 self .packet .advance (1 )
534488
535- << << < << HEAD
536- query = self .packet .read (event_size - 13 - self .status_vars_length
537- - self .schema_length - 1 )
538- self .query = query .decode ("utf-8" , errors = 'backslashreplace' )
539- == == == =
489+ #string[EOF] query
540490 self .query : str = self .packet .read (event_size - 13 - self .status_vars_length
541491 - self .schema_length - 1 ).decode ("utf-8" )
542- >> >> > >> 07 b561d (add type hints to the rest of the events , improve docstring readability in some events )
543- #string[EOF] query
544492
545493 def _dump (self ) -> None :
546494 """Dump the python objects for the event."""
@@ -605,11 +553,7 @@ def _read_status_vars_value_for_key(self, key: int) -> Union[None, NoReturn]:
605553 elif key == Q_TIME_ZONE_CODE : # 0x05
606554 time_zone_len = self .packet .read_uint8 ()
607555 if time_zone_len :
608- << < << < < HEAD
609- self .time_zone = self .packet .read (time_zone_len )
610- == == == =
611556 self .time_zone : str = self .packet .read (time_zone_len )
612- >> >> > >> 07 b561d (add type hints to the rest of the events , improve docstring readability in some events )
613557 elif key == Q_CATALOG_NZ_CODE : # 0x06
614558 catalog_len = self .packet .read_uint8 ()
615559 if catalog_len :
@@ -756,19 +700,11 @@ def _dump(self) -> None:
756700
757701class IntvarEvent (BinLogEvent ):
758702 """
759- <<<<<<< HEAD
760703 Stores the value of auto-increment variables.
761704 This event will be created just before a QueryEvent.
762705
763706 :ivar type: int - 1 byte identifying the type of variable stored.
764- =======
765- The event stores the value of auto-increment variables.
766- It will be created just before a QueryEvent.
767-
768- In detail, the class creates the following python objects in the constructor:
769-
770- :ivar type: int - 1 byte identifying the type of variable stored. \
771- >>>>>>> 07b561d (add type hints to the rest of the events, improve docstring readability in some events)
707+
772708 Can be either LAST_INSERT_ID_EVENT (1) or INSERT_ID_EVENT (2).
773709 :ivar value: int - The value of the variable
774710 """
@@ -804,11 +740,7 @@ class RandEvent(BinLogEvent):
804740 :ivar seed1: int - value for the first seed
805741 :ivar seed2: int - value for the second seed
806742 """
807- << < << << HEAD
808- def __init__ (self , from_packet , event_size , table_map , ctl_connection , ** kwargs ):
809- super ().__init__ (from_packet , event_size , table_map ,
810- ctl_connection , ** kwargs )
811- == == == =
743+
812744 def __init__ (self ,
813745 from_packet : Type [MysqlPacket ],
814746 event_size : int ,
@@ -817,7 +749,6 @@ def __init__(self,
817749 ** kwargs : str ):
818750 super ().__init__ (from_packet , event_size , table_map , ctl_connection , ** kwargs )
819751
820- >> > >> >> 07 b561d (add type hints to the rest of the events , improve docstring readability in some events )
821752 # Payload
822753 self ._seed1 : int = self .packet .read_uint64 ()
823754 self ._seed2 : int = self .packet .read_uint64 ()
0 commit comments