Preguntas y respuestas de entrevista mas solicitadas y pruebas en linea
Plataforma educativa para preparacion de entrevistas, pruebas en linea, tutoriales y practica en vivo

Desarrolla tus habilidades con rutas de aprendizaje enfocadas, examenes de practica y contenido listo para entrevistas.

WithoutBook reune preguntas de entrevista por tema, pruebas practicas en linea, tutoriales y guias comparativas en un espacio de aprendizaje responsivo.

Preparar entrevista

Examenes simulados

Poner como pagina de inicio

Guardar esta pagina en marcadores

Suscribirse con correo electronico

Without Book Hacer una pregunta

Pregunta. log4j.xml or log4j.properties in java log configuration.

- Which one I should prefer - log4j.xml or log4j.properties to configure log in my java app.

Publicado el Jul 23, 2014 Publicado por Ruby Singh
Respuesta. Properties can be defined by a properties file or by an XML file. Log4j looks for a file named log4j.xml and then for a file named log4j.properties. Both must be placed in the src folder.

The property file is less verbose than an XML file. The XML requires the log4j.dtd to be placed in the source folder as well. The XML requires a dom4j.jar which might not be included in older Java versions.

The properties file does not support some advanced configuration options like Filters, custom ErrorHandlers and a special type of appenders, i.e. AsyncAppender. ErrorHandlers defines how errors in log4j itself are handled, for example badly configured appenders. Filters are more interesting. From the available filters, I think that the level range filter is really missing for property files.
Publicado el Jul 26, 2014 Publicado por Johny Verma

Ingresa tu respuesta

Nombre
Direccion de correo electronico
Respuesta
Verificacion de seguridad
Resuelve esto para continuar: 7 + 3 = ?
Copyright © 2026, WithoutBook.