Class JsonLoggerUpdateListener

java.lang.Object
org.kawanfw.sql.api.server.listener.JsonLoggerUpdateListener
All Implemented Interfaces:
UpdateListener

public class JsonLoggerUpdateListener
extends Object
implements UpdateListener
Concrete implementation of UpdateListener. The updateActionPerformed(ClientEvent, Connection) logs using JSON format the ClientEvent.
Since:
9.0
Author:
Nicolas de Pomereu
  • Constructor Details

    • JsonLoggerUpdateListener

      public JsonLoggerUpdateListener()
  • Method Details

    • updateActionPerformed

      public void updateActionPerformed​(SqlEvent evt, Connection connection) throws IOException, SQLException
      Logs using JSON format the ClientEvent into a Logger with parameters:
      • Output file pattern: user.home/.kawansoft/log/JsonLoggerUpdateListener.log.
      • Limit: 1Gb.
      • Count (number of files to use): 3.
      Specified by:
      updateActionPerformed in interface UpdateListener
      Parameters:
      evt - the SQL update event that is successfully processed
      connection - the Connection in use for the SQL update event
      Throws:
      IOException - if an IOException occurs
      SQLException - if a SQLException occurs