question: public boolean processEvent ( ) throws ReplicatorException , InterruptedException { MySQLPacket packet = MySQLPacket . readPacket ( input , readTimeout * 1000 ) ; if ( packet == null ) { if ( logger . isDebugEnabled ( ) ) { logger . debug ( "No packet returned from network" ) ; } return false ; } int length = packet . getDataLength ( ) ; int number = packet . getPacketNumber ( ) ; short type = packet . getUnsignedByte ( ) ; if ( logger . isDebugEnabled ( ) ) { logger . debug ( "Received packet: number=" + number + " length=" + length + " type=" + type ) ; } switch ( type ) { case 0 : try { processBinlogEvent ( packet ) ; } catch ( IOException e ) { throw new ExtractorException ( "Error processing binlog: " + e . getMessage ( ) , e ) ; } break ; case 0xFE : throw new ExtractorException ( "EOF packet received" ) ; case 0xFF : int errno = packet . getShort ( ) ; packet . getByte ( ) ; String sqlState = packet . getString ( 5 ) ; String errMsg = packet . getString ( ) ; String msg = "Error packet received: errno=" + errno + " sqlstate=" + sqlState + " error=" + errMsg ; throw new ExtractorException ( msg ) ; default : throw new ExtractorException ( "Unexpected response while fetching binlog data: packet=" + packet . toString ( ) ) ; } return true ; }
target:  Process next event packet from MySQL.