code: protected void maintenance (final String action, final String table)
          throws PersistenceException
      {
          executeUpdate(new Operation<Object>() {
              public Object invoke (Connection conn, DatabaseLiaison liaison)
                  throws SQLException, PersistenceException
              {
                  Statement stmt = null;
                  try {
                      stmt = conn.createStatement();
                      ResultSet rs = stmt.executeQuery(action + " table " + table);
                      while (rs.next()) {
                          String result = rs.getString("Msg_text");
                          if (result == null ||
                              (result.indexOf("up to date") == -1 && !result.equals("OK"))) {
                              log.info("Table maintenance [" + SimpleRepository.toString(rs) + "].");
                          }
                      }
  
                  } finally {
                      JDBCUtil.close(stmt);
                  }
                  return null;
              }
          });
      }
docs: Instructs MySQL to perform table maintenance on the specified table.
  
  @param action <code>analyze</code> recomputes the distribution of the keys for the specified
  table. This can help certain joins to be performed more efficiently. <code>optimize</code>
  instructs MySQL to coalesce fragmented records and reclaim space left by deleted records.
  This can improve a tables efficiency but can take a long time to run on large tables.