Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members  

DsLogAdmin::Log Interface Reference

The base log interface supported by all logs in the log service. More...

import "DsLogAdmin.idl";

Inherited by DsEventLogAdmin::EventLog, DsLogAdmin::BasicLog, and DsTypedEventLogAdmin::TypedEventLog.

List of all members.

Public Methods

LogMgr my_factory ()
 Return the factory that created this Log object. More...

LogId id ()
 Return the unique identifier of this Log object. More...

QoSList get_log_qos ()
 Return the current quality of service provided by this log. More...

void set_log_qos (in QoSList qos) raises (UnsupportedQoS)
 Set the quality of service provided by this log. More...

unsigned long get_max_record_life ()
 Return the maximum number of seconds that a record is stored in this log. More...

void set_max_record_life (in unsigned long life)
 Set the maximum number of seconds that a record is stored in the log. More...

unsigned long long get_max_size ()
 Return the maximum size of this log measured in bytes. More...

void set_max_size (in unsigned long long size) raises (InvalidParam)
 Set the maximum size of this log. More...

unsigned long long get_current_size ()
 Return the current size of this log measured in bytes. More...

unsigned long long get_n_records ()
 Return the current number of records contained in the log. More...

LogFullActionType get_log_full_action ()
 Get the action to be taken when a log is full. More...

void set_log_full_action (in LogFullActionType action) raises (InvalidLogFullAction)
 Set the action to be taken when a log is full. More...

AdministrativeState get_administrative_state ()
 Get the administrative state of the log. More...

void set_administrative_state (in AdministrativeState state)
 Set the administrative state of the log. More...

ForwardingState get_forwarding_state ()
 Get the forwarding state of the log. More...

void set_forwarding_state (in ForwardingState state)
 Set the forwarding state of the log. More...

OperationalState get_operational_state ()
 Get the operational state of the log. More...

TimeInterval get_interval ()
 Get the time interval in which this log is operational. More...

void set_interval (in TimeInterval interval) raises (InvalidTime, InvalidTimeInterval)
 Set the time interval in which this log is operational. More...

AvailabilityStatus get_availability_status ()
 Returns the availability status of this log. More...

CapacityAlarmThresholdList get_capacity_alarm_thresholds ()
 Get an array of percentage points where this log will generate a warning event. More...

void set_capacity_alarm_thresholds (in CapacityAlarmThresholdList threshs) raises (InvalidThreshold)
 Set an array of percentage points where this log will generate a warning event. More...

WeekMask get_week_mask ()
 Get the week masks in which this log is operational. More...

void set_week_mask (in WeekMask masks) raises (InvalidTime, InvalidTimeInterval, InvalidMask)
 Set the week masks in which this log is operational. More...

RecordList query (in string grammar, in Constraint c, out Iterator i) raises (InvalidGrammar, InvalidConstraint)
 Query the log for records. More...

RecordList retrieve (in TimeT from_time, in long how_many, out Iterator i)
 Retrieve a number of log records. More...

unsigned long match (in string grammar, in Constraint c) raises (InvalidGrammar, InvalidConstraint)
 Same as query except that only the number of records found is returned. More...

unsigned long delete_records (in string grammar, in Constraint c) raises (InvalidGrammar, InvalidConstraint)
 Delete records that match a constraint. More...

unsigned long delete_records_by_id (in RecordIdList ids)
 Delete records with given identification numbers. More...

void write_records (in Anys records) raises (LogFull, LogOffDuty, LogLocked, LogDisabled)
 Write an array of records into this log. More...

void write_recordlist (in RecordList list) raises (LogFull, LogOffDuty, LogLocked, LogDisabled)
 Write an array of records into this log. More...

void set_record_attribute (in RecordId id, in NVList attr_list) raises (InvalidRecordId, InvalidAttribute)
 Set a list of record attributes. More...

unsigned long set_records_attribute (in string grammar, in Constraint c, in NVList attr_list) raises (InvalidGrammar, InvalidConstraint, InvalidAttribute)
 Set the record attributes for all records that match some constraint. More...

NVList get_record_attribute (in RecordId id) raises (InvalidRecordId)
 Get the record attributes for a given log record. More...

Log copy (out LogId id)
 Create a new log that is a clone of this log. More...

Log copy_with_id (in LogId id) raises (LogIdAlreadyExists)
 Create a new log that is a clone of this log. More...

void flush () raises (UnsupportedQoS)
 Flush the records received by this log object. More...


Detailed Description

The base log interface supported by all logs in the log service.


Member Function Documentation

Log DsLogAdmin::Log::copy out LogId    id
 

Create a new log that is a clone of this log.

m <code>id</code> - The unique identifier of the newly created
log object.
Returns:
A new Log object.

Log DsLogAdmin::Log::copy_with_id in LogId    id raises (LogIdAlreadyExists)
 

Create a new log that is a clone of this log.

m <code>id</code> - The desired unique identifier of the newly
created log object.
Returns:
A new Log object. @raises LogIdAlreadyExists If a log object with that unique identifier already exists.

unsigned long DsLogAdmin::Log::delete_records in string    grammar,
in Constraint    c
raises (InvalidGrammar, InvalidConstraint)
 

Delete records that match a constraint.

m <code>grammar</code> - The grammar to use for this query.
m <code>c</code> - The query constraint.
Returns:
Number of records that operation deleted. @raises InvalidGrammar If the grammar is not supported by this implementation of the log service. @raises InvalidConstraint If the constraint is not valid for the grammar.

unsigned long DsLogAdmin::Log::delete_records_by_id in RecordIdList    ids
 

Delete records with given identification numbers.

m <code>ids</code> - A sequence of identification numbers.
Returns:
Number of records that operation deleted.

void DsLogAdmin::Log::flush   raises (UnsupportedQoS)
 

Flush the records received by this log object.

This operation does nothing as all log records are flushed by default when received by the log. @raises UnsupportedQoS Never raised.

AdministrativeState DsLogAdmin::Log::get_administrative_state  
 

Get the administrative state of the log.

If the state is unlocked, use of the log is permitted. If locked, the log will not create new records. Even if the log is locked, events will be forwarded and records may be deleted.

Returns:
The administrative state of this log.

AvailabilityStatus DsLogAdmin::Log::get_availability_status  
 

Returns the availability status of this log.

The log_full field indicates whether or not the log is full. The on_duty field is only set to true is the following conditions are satified:

  • The operational state is enabled.
  • The administrative state is unlocked.
  • The time at which this operation was invoked falls within the log duration time.
  • The time at which this operation was invoked falls within the log scheduling time (the week masks).
Returns:
The availability status of this log.

CapacityAlarmThresholdList DsLogAdmin::Log::get_capacity_alarm_thresholds  
 

Get an array of percentage points where this log will generate a warning event.

Returns:
An array of alarm thresholds.

unsigned long long DsLogAdmin::Log::get_current_size  
 

Return the current size of this log measured in bytes.

Returns:
The size of this log.

ForwardingState DsLogAdmin::Log::get_forwarding_state  
 

Get the forwarding state of the log.

Returns:
The forwarding state of this log.

TimeInterval DsLogAdmin::Log::get_interval  
 

Get the time interval in which this log is operational.

Returns:
The operational time interval of this log.

LogFullActionType DsLogAdmin::Log::get_log_full_action  
 

Get the action to be taken when a log is full.

This implementation of the log service currently supports two different actions:

  • wrap: The oldest records in the log (based on the log time) will be deleted to free resources for the creation of new records.
  • halt: No more records will be logged and all incoming events will be discarded. Records already in the log will be retained.
Returns:
The action to take when log is full.

QoSList DsLogAdmin::Log::get_log_qos  
 

Return the current quality of service provided by this log.

Returns:
An array with QoS settings.

unsigned long DsLogAdmin::Log::get_max_record_life  
 

Return the maximum number of seconds that a record is stored in this log.

A value of zero means that records are stored until the log is destroyed.

Returns:
The maximum record life time in seconds.

unsigned long long DsLogAdmin::Log::get_max_size  
 

Return the maximum size of this log measured in bytes.

If no maximum size has been set, the value zero is returned.

Returns:
The maximum size of this log.

unsigned long long DsLogAdmin::Log::get_n_records  
 

Return the current number of records contained in the log.

Returns:
The number of records stored in this log.

OperationalState DsLogAdmin::Log::get_operational_state  
 

Get the operational state of the log.

If enabled, the log is operational and ready to use. If disabled, a run-time problem has occurred and the log can not function.

Returns:
The operational state of this log.

NVList DsLogAdmin::Log::get_record_attribute in RecordId    id raises (InvalidRecordId)
 

Get the record attributes for a given log record.

m <code>id</code> - The log record identifier.
Returns:
The attributes for the log record with said identifier. @raises InvalidRecordId If the log does not contain a record with the specified identifier.

WeekMask DsLogAdmin::Log::get_week_mask  
 

Get the week masks in which this log is operational.

Returns:
An array of week masks indicating when this log is active.

LogId DsLogAdmin::Log::id  
 

Return the unique identifier of this Log object.

Returns:
The identifier of this log.

unsigned long DsLogAdmin::Log::match in string    grammar,
in Constraint    c
raises (InvalidGrammar, InvalidConstraint)
 

Same as query except that only the number of records found is returned.

m <code>grammar</code> - The grammar to use for this query.
m <code>c</code> - The query constraint.
Returns:
Number of records that match this constraint. @raises InvalidGrammar If the grammar is not supported by this implementation of the log service. @raises InvalidConstraint If the constraint is not valid for the grammar.

LogMgr DsLogAdmin::Log::my_factory  
 

Return the factory that created this Log object.

Returns:
A LogMgr object. This object can be narrowed to a specific log factory.

RecordList DsLogAdmin::Log::query in string    grammar,
in Constraint    c,
out Iterator    i
raises (InvalidGrammar, InvalidConstraint)
 

Query the log for records.

m <code>grammar</code> - The grammar to use for this query.
m <code>c</code> - The query constraint.
m <code>i</code> - An iterator if a large number of records
are returned.
Returns:
An array of log records. @raises InvalidGrammar If the grammar is not supported by this implementation of the log service. @raises InvalidConstraint If the constraint is not valid for the grammar.

RecordList DsLogAdmin::Log::retrieve in TimeT    from_time,
in long    how_many,
out Iterator    i
 

Retrieve a number of log records.

m <code>from_time</code> - The time to start from. Only log
records written after this time are returned.
m <code>how_many</code> - The maximum number of records to
return from this operation. The remaining records are returned by means of the iterator.
m <code>i</code> - An iterator with remaining records if the
operation would have returned more than how_many records.
Returns:
An array of log records.

void DsLogAdmin::Log::set_administrative_state in AdministrativeState    state
 

Set the administrative state of the log.

m <code>state</code> - The new administrative state of this log.

void DsLogAdmin::Log::set_capacity_alarm_thresholds in CapacityAlarmThresholdList    threshs raises (InvalidThreshold)
 

Set an array of percentage points where this log will generate a warning event.

Each elements in the array must have a value between 0 and 100 percent. This log will generate an capacity threshold alarm event when the log size exceeds each of the values in threshs.

m <code>threshs</code> - An array with new alarm thresholds.
@raises InvalidThreshold If any of the elements in threshs are not in the range 0-100.

void DsLogAdmin::Log::set_forwarding_state in ForwardingState    state
 

Set the forwarding state of the log.

When the state is set to off this log will not forward events from its suppliers to its consumers.

m <code>state</code> - The new forwarding state of this log.

void DsLogAdmin::Log::set_interval in TimeInterval    interval raises (InvalidTime, InvalidTimeInterval)
 

Set the time interval in which this log is operational.

Setting the start time to zero means that the log should start logging immediately. If the start time is before the time at which this operation is invoked, the log will start logging immediately. If the stop time is set to zero, the log will continue to log until it is destroyed. Note that the log interval only affects the writing of records. The log will forward events regardless of this setting until the log is destroyed.

m <code>interval</code> - The operational time interval of this
log. @raises InvalidTime If the stop time is before the time at which this operation is invoked. @raises InvalidTimeInterval If the stop time is before the start time.

void DsLogAdmin::Log::set_log_full_action in LogFullActionType    action raises (InvalidLogFullAction)
 

Set the action to be taken when a log is full.

This operation is delegated to the associated LogStore plug-in object.

m <code>action</code> - The new action to take when log is full.
@raises InvalidLogFullAction If the LogStore plug-in object did not supported the supplied setting.

void DsLogAdmin::Log::set_log_qos in QoSList    qos raises (UnsupportedQoS)
 

Set the quality of service provided by this log.

This is delegated to the LogStore plug-in object used for persistence.

m <code>qos</code> - An array with new QoS settings.
@raises UnsupportedQoS If any of the elements in qos do not have the value of QoSReliability.

void DsLogAdmin::Log::set_max_record_life in unsigned long    life
 

Set the maximum number of seconds that a record is stored in the log.

A value of zero means that records are stored until the log is destroyed.

m <code>life</code> - The new maximum record life time in seconds.

void DsLogAdmin::Log::set_max_size in unsigned long long    size raises (InvalidParam)
 

Set the maximum size of this log.

The unit of this parameter is bytes. A value of zero means that the maximum size of the log is unlimited.

m <code>size</code> - The new maximum size of this log.
@raises InvalidParam If size is less than the current size of the log.

void DsLogAdmin::Log::set_record_attribute in RecordId    id,
in NVList    attr_list
raises (InvalidRecordId, InvalidAttribute)
 

Set a list of record attributes.

A log record supports any number of records attributes. Since an attribute is merely a name-value pair, it is up to client applications to define meaningful record attributes.

m <code>id</code> - The log record identifier.
m <code>attr_list</code> - A sequence of attributes.
@raises InvalidRecordId If the log does not contain a record with the specified identifier. @raises InvalidAttribute Not raised by this implementation of the log service.

unsigned long DsLogAdmin::Log::set_records_attribute in string    grammar,
in Constraint    c,
in NVList    attr_list
raises (InvalidGrammar, InvalidConstraint, InvalidAttribute)
 

Set the record attributes for all records that match some constraint.

A log record supports any number of records attributes. Since an attribute is merely a name-value pair, it is up to client applications to define meaningful record attributes.

m <code>grammar</code> - The grammar to use for this query.
m <code>c</code> - The constraint that records must match.
m <code>attr_list</code> - A sequence of attributes.
Returns:
Number of records that operation affected. @raises InvalidGrammar If the grammar is not supported by this implementation of the log service. @raises InvalidRecordId If the log does not contain a record with the specified identifier. @raises InvalidAttribute Not raised by this implementation of the log service.

void DsLogAdmin::Log::set_week_mask in WeekMask    masks raises (InvalidTime, InvalidTimeInterval, InvalidMask)
 

Set the week masks in which this log is operational.

When no week masks are specified, the log will be operational during the entire week. Each element in the masks sequence indicates a start time and a stop time and a bit mask of days where this time interval should be applied. Note that the week masks only affects the writing of records.The log will forward events regardless of this setting until the log is destroyed.

m <code>masks</code> - An array of week masks indicating when
this log is active. @raises InvalidTime If the value of the hour field is not within the interval 0-23 or if the value of the minute field is not within the interval 0-59. @raises InvalidTimeInterval If the start time of day is after the stop time of day. @raises InvalidMask If the days field of a week mask is not a valid bit field.

void DsLogAdmin::Log::write_recordlist in RecordList    list raises (LogFull, LogOffDuty, LogLocked, LogDisabled)
 

Write an array of records into this log.

The log records are logged but not forwarded.

m <code>records</code> - A sequence of log records.
@raises LogFull If the log is full and the LogFullAction property is set to halt. @raises LogOffDuty If the log's availability status is "off_duty". @raises LogLocked If the log's administrative state is locked. @raises LogDisabled If the log's operational state is "disabled".

void DsLogAdmin::Log::write_records in Anys    records raises (LogFull, LogOffDuty, LogLocked, LogDisabled)
 

Write an array of records into this log.

The log records are logged but not forwarded.

m <code>records</code> - A sequence of records.
@raises LogFull If the log is full and the LogFullAction property is set to halt. @raises LogOffDuty If the log's availability status is "off_duty". @raises LogLocked If the log's administrative state is locked. @raises LogDisabled If the log's operational state is "disabled".