Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
N
network-communication
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
joubran.mansour
network-communication
Commits
3c04a810
Commit
3c04a810
authored
Jan 16, 2024
by
Mohamad Bashar Desoki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add logging
parent
d98f5993
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
98 additions
and
2 deletions
+98
-2
pom.xml
httpclient/pom.xml
+22
-2
logback.xml
httpclient/src/main/resources/logback.xml
+31
-0
pom.xml
httpserver/pom.xml
+14
-0
logback.xml
httpserver/src/main/resources/logback.xml
+31
-0
No files found.
httpclient/pom.xml
View file @
3c04a810
...
...
@@ -7,11 +7,31 @@
<groupId>
org.example
</groupId>
<artifactId>
httpclient
</artifactId>
<version>
1.0-SNAPSHOT
</version>
<build>
<plugins>
<plugin>
<groupId>
org.apache.maven.plugins
</groupId>
<artifactId>
maven-compiler-plugin
</artifactId>
<configuration>
<source>
17
</source>
<target>
17
</target>
</configuration>
</plugin>
</plugins>
</build>
<properties>
<maven.compiler.source>
17
</maven.compiler.source>
<maven.compiler.target>
17
</maven.compiler.target>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<java.version>
17
</java.version>
<logback.version>
1.2.3
</logback.version>
</properties>
<dependencies>
<dependency>
<groupId>
ch.qos.logback
</groupId>
<artifactId>
logback-classic
</artifactId>
<version>
${logback.version}
</version>
</dependency>
</dependencies>
</project>
\ No newline at end of file
httpclient/src/main/resources/logback.xml
0 → 100644
View file @
3c04a810
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<property
name=
"HOME_LOG"
value=
"logs/app.log"
/>
<appender
name=
"CONSOLE"
class=
"ch.qos.logback.core.ConsoleAppender"
>
<layout
class=
"ch.qos.logback.classic.PatternLayout"
>
<Pattern>
%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} - %msg%n
</Pattern>
</layout>
</appender>
<appender
name=
"FILE"
class=
"ch.qos.logback.core.FileAppender"
>
<file>
${HOME_LOG}
</file>
<append>
true
</append>
<immediateFlush>
true
</immediateFlush>
<encoder>
<pattern>
%d %p %c{1.} [%t] %m%n
</pattern>
</encoder>
</appender>
<!-- Log Level: ERROR, WARN, INFO, DEBUG, TRACE-->
<logger
name=
"Client"
level=
"DEBUG"
additivity=
"false"
>
<appender-ref
ref=
"CONSOLE"
/>
<appender-ref
ref=
"FILE"
/>
</logger>
<root
level=
"error"
>
<appender-ref
ref=
"CONSOLE"
/>
</root>
</configuration>
\ No newline at end of file
httpserver/pom.xml
View file @
3c04a810
...
...
@@ -20,5 +20,19 @@
</plugins>
</build>
<properties>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<java.version>
17
</java.version>
<logback.version>
1.2.3
</logback.version>
</properties>
<dependencies>
<dependency>
<groupId>
ch.qos.logback
</groupId>
<artifactId>
logback-classic
</artifactId>
<version>
${logback.version}
</version>
</dependency>
</dependencies>
</project>
\ No newline at end of file
httpserver/src/main/resources/logback.xml
0 → 100644
View file @
3c04a810
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<property
name=
"HOME_LOG"
value=
"logs/app.log"
/>
<appender
name=
"CONSOLE"
class=
"ch.qos.logback.core.ConsoleAppender"
>
<layout
class=
"ch.qos.logback.classic.PatternLayout"
>
<Pattern>
%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} - %msg%n
</Pattern>
</layout>
</appender>
<appender
name=
"FILE"
class=
"ch.qos.logback.core.FileAppender"
>
<file>
${HOME_LOG}
</file>
<append>
true
</append>
<immediateFlush>
true
</immediateFlush>
<encoder>
<pattern>
%d %p %c{1.} [%t] %m%n
</pattern>
</encoder>
</appender>
<!-- Log Level: ERROR, WARN, INFO, DEBUG, TRACE-->
<logger
name=
"Server"
level=
"DEBUG"
additivity=
"false"
>
<appender-ref
ref=
"CONSOLE"
/>
<appender-ref
ref=
"FILE"
/>
</logger>
<root
level=
"error"
>
<appender-ref
ref=
"CONSOLE"
/>
</root>
</configuration>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment