Class StringSerializer
java.lang.Object
kieker.monitoring.writer.serializer.AbstractMonitoringRecordSerializer
kieker.monitoring.writer.serializer.StringSerializer
- All Implemented Interfaces:
IMonitoringRecordSerializer
String serializer for monitoring records based on the record's toString
method.
- Since:
- 1.13
- Author:
- Holger Knoche
-
Constructor Summary
ConstructorsConstructorDescriptionStringSerializer(Configuration configuration) Creates a new serializer using the given configuration. -
Method Summary
Modifier and TypeMethodDescriptionvoidCalled by the collector during initialization (before any records are written).voidCalled by the collector upon termination (after remaining records have been flushed).intserializeRecord(IMonitoringRecord record, ByteBuffer buffer) Serializes a single record into the given byte buffer.intserializeRecords(Collection<IMonitoringRecord> records, ByteBuffer buffer) Serializes multiple monitoring records into the given byte buffer.
-
Constructor Details
-
StringSerializer
Creates a new serializer using the given configuration.- Parameters:
configuration- The configuration to use
-
-
Method Details
-
serializeRecord
Description copied from interface:IMonitoringRecordSerializerSerializes a single record into the given byte buffer.- Parameters:
record- The record to serializebuffer- The buffer to write to- Returns:
- The number of bytes written to the buffer
-
serializeRecords
Description copied from interface:IMonitoringRecordSerializerSerializes multiple monitoring records into the given byte buffer.- Parameters:
records- The records to serializebuffer- The buffer to write to- Returns:
- The number of bytes written to the buffer
-
onInitialization
public void onInitialization()Description copied from interface:IMonitoringRecordSerializerCalled by the collector during initialization (before any records are written). -
onTermination
public void onTermination()Description copied from interface:IMonitoringRecordSerializerCalled by the collector upon termination (after remaining records have been flushed).
-