Main Content

loggederror

Error information for Kafka stream operation

Since R2022b

    This function requires Streaming Data Framework for MATLAB® Production Server™.

    Description

    txt = loggederror(ks) return the text txt of the most recent error that is logged in the Kafka® error log. To obtain all Kafka log information, see Obtain Kafka Event Stream Log Files.

    example

    Examples

    collapse all

    Assume that you have a Kafka server running at the network address kafka.host.com:9092 that has a topic RecamanSequence.

    Create a KafkaStream object connected to the RecamanSequence topic. If the host you specify when creating the KafkaStream object does not exist, an error occurs if you call readtimetable.

    ks = kafkaStream("kafka.host123.com",9092,"RecamanSequence");
    tt = readtimetable(ks);
    
    loggederror(ks)
    
    ans =
    
        '... - Failed to start connector with exception:
               ...
         '

    Input Arguments

    collapse all

    Object connected to a Kafka stream topic, specified as a KafkaStream object.

    Version History

    Introduced in R2022b