log4j Online Quiz


Advertisements

Following quiz provides Multiple Choice Questions (MCQs) related to log4j Framework. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Answer : A

Explanation

filter − The Filter objects can analyze logging information beyond level matching and decide whether logging requests should be handled by a particular Appender or ignored.

Answer : B

Explanation

C − Used to output the fully qualified class name of the caller issuing the logging request. For example, for the class name.* "org.apache.xyz.SomeClass", the pattern %C{1} will output "SomeClass".

Answer : C

Explanation

%.20c − Truncate from the beginning if the category name is longer than 20 characters.

Answer : D

Explanation

Filename − The name of the log file.

Answer : B

Explanation

maxBackupIndex − This property denotes the number of backup files to be created.

Answer : A

Explanation

URL − Sets the JDBC URL.

Q 10 - The Level object defines the granularity and priority of any logging information.

A - true

B - false

Answer : A

Explanation

true − The Level object defines the granularity and priority of any logging information. There are seven levels of logging defined within the API: OFF, DEBUG, INFO, ERROR, WARN, FATAL, and ALL.

log4j_questions_answers.htm
Advertisements