This set of Javascript Multiple Choice Questions & Answers (MCQs) focuses on “Remote Logging”.
1. Which of the following are JavaScript logging library?
a) log
b) loglevel
c) leveljavascript
d) jslogjava
View Answer
Explanation: loglevel is a JavaScript logging library that is reliable and extremely easy-to-use over the various console.log() methods. loglevel is a lightweight, minimal and convenient JavaScript logging library which provides a reliable and extremely easy-to-use layer over the various console.log() methods that are often available, with none of their downsides.
2. What is the significance of the JavaScript logging library loglevel?
a) Lightweight
b) Unreliable
c) Minimal usage
d) Inconvenient
View Answer
Explanation: loglevel is a lightweight, minimal and convenient JavaScript logging library which provides a reliable and extremely easy-to-use layer over the various console.log() methods that are often available, with none of their downsides. loglevel makes these methods safe to use by gracefully handling the cases where they don’t exist and also lets you filter the output of these, to only show messages at warn level or above.
3. Which of the following browsers support the usage of the JavaScript logging library log4javascript?
a) IE
b) Safari
c) Opera
d) All of the mentioned
View Answer
Explanation: Apache Log4j is a Java-based logging utility. It was originally written by Ceki Gülcü and is part of the Apache Logging Services project of the Apache Software Foundation. Since a major use of JavaScript logging is in browser testing, log4javascript is tested and works across all recent major browsers, including:
- Internet Explorer 5+ for Windows
- Mozilla, Firefox, Netscape
- Google Chrome
- Safari 1.3+
- Opera 7.5+
- WebKit
- Konqueror 3.4+
4. What is the significance of the JavaScript logging library log4javascript?
a) Fully featured
b) Easy to use
c) Fully featured and easy to use
d) Easily accessible
View Answer
Explanation: Apache Log4j is a Java-based logging utility.log4javascript is a fully-featured, easy-to-use JavaScript logging framework based on the Java logging framework log4j. Its purpose is to provide JavaScript developers with a familiar, robust and flexible logging framework with which to debug JavaScript applications.
5. Which of the following JavaScript logging framework lets one to toggle the plane?
a) Lumberjack
b) Log Hound
c) jsTracer
d) fvlogger
View Answer
Explanation: Lumberjack is a JavaScript utility that hijacks the browser console, makes it more beautiful and enhances it so logs can be split into more manageable chunks. Lumberjack also saves everything that is logged (so you can review later) and colorizes your logs (where supported) to increase legibility.
6. Which of the following JavaScript logging tool is also a debugging tool?
a) Blackbird
b) Log Hound
c) jsTracer
d) fvlogger
View Answer
Explanation: jsTracer is a simple yet feature rich JavaScript logging and debugging tool. It is especially useful for debugging what has been coined “Web 2.0” code. It helps in dynamic tracing for JavaScript, written in JavaScript, providing you insight into your live nodejs applications, at the process, machine, or cluster level.
7. Which of the following JavaScript logging tool is standalone?
a) Blackbird
b) Log Hound
c) jsTracer
d) fvlogger
View Answer
Explanation: Log Hound is a tool that was designed for finding frequent patterns from event log data sets with the help of a breadth-first frequent itemset mining algorithm. LogHound can be employed for mining frequent line patterns from raw event logs, e.g. Log Hound is a standalone JavaScript logging utility that allows you to log messages during execution of JavaScript code.
8. Which of the following is not an appenders?
a) DummyAppender
b) ConsoleAppender
c) FileAppender
d) DeleteAppender
View Answer
Explanation: There are several ways to log using “appender”s. Some of the current available Appenders are:
9. Which of the following reads the textual contents of a URL and returns as a string?
a) spawn(f);
b) load(filename,…);
c) readFile(file);
d) readUrl(url);
View Answer
Explanation: readUrl() opens an input connection to the given string url, read all its bytes and convert them to a string using the specified character coding or default character coding if an explicit coding argument is not given.
10. When does JSNLog have server-side extensions?
a) Use of .NET
b) Use of Java
c) Both .NET and Java
d) Use of C#
View Answer
Explanation: If you use .Net, JSNLog has server side extensions that receive log data from the browser and have it logged on the server. And it lets you configure your loggers in your web.config. It includes a large class library named as Framework Class Library and provides language interoperability across several programming languages.
Sanfoundry Global Education & Learning Series – Javascript Programming.
- Practice Information Science MCQs
- Apply for Computer Science Internship
- Practice Programming MCQs
- Check JavaScript Books
- Check Programming Books