Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Note

Moved this over from advanced user guide since it's really about the implementation details hence server internals.

Note
titleWork in progress

This site is in the process of being reviewed and updated.

Introduction

We don't have any way to define snapshots in the server. This is a very interesting functionality we may want to have. XWhat will it be good for ?

  • being able to log all the requests for debug purpose or for post-mortem analysis
  • create a journal we can replay from a specific point if the server has crashed and we want to restore the backend to a valid state
  • being able to rollback the backend up to a previous state (like SVN/CVS does)
  • use the journal to update other instances remotly and asynchronously
  • many more usages I don't have on top of my head right now (wink)

To be able to implement all those functionalities, we have to implement some basic bricks :

  • a new interceptor to store all the requests
  • some extended operations to set a Tag, to rollback or to discard a tag
  • define the exact semantic of each new functionalities

Simple Logger

The first very basic functionality is to implement a basic logger. It has already been added, but some more elements need to be defined, like the way to start the logger, either via an LDAP extended request, or programmatically.

There is an existing page started by Ersin where you have a description of the existing ChangeLog interceptor :
Logging Subsystem

Semantic

We need to be able to start the logger, to stop it, to configure it, to select the requests, to select the users, etc. Here are a list of parameters we may want to set :

Parameter

Description

Mandatory

Logger name

The logger's name

(tick)

Active

Activate or desactivate the log. Default to TRUE, and when set to FALSE, no other parameters should be given


(error)

Max Size

The maximum size of the log file

(error)

Saved Requests

The list of requests we want to save (AddRequest, DelRequest, for instance)
Default to ALL_REQUESTS



(error)

Saved Attribute

A list of attributes we want to store in the file. It may be associated with the 
previous  selection. '*' and '+' will be used for 'all users attribute' and 'all
operationnal attributes'
Default to '*'


(error)

Subentry

Define the subentry we want the logger to apply when logging. The user may want
to allow some users to log or not, or may define a set of entries which may be logged, etc. 
Default to null : everything is loggable by default


(error)

Rotate

Define the way the file will be rotated : Daily, when exceeding a given size, after a certain period of time


(error)

Active

Activate or desactivate the log. Default to TRUE

 

When we have defined those parameters, we will have to describe them using ASN.1, and to implement the ExtendedOperation.