Svecco commented on PR #2452:
URL: https://github.com/apache/iggy/pull/2452#issuecomment-3734033137

   Hi, I've completed some initial modifications and added integration tests.
   
   I first manually observed the runtime behavior locally by running in the 
terminal: 
   `RUST_LOG=trace cargo run --bin iggy-server -- --fresh 
--with-default-root-credentials` &&
   `cargo run --bin iggy-bench -- -T 1000MB pp -p 1 quic`
   I verified that the current log rotation behavior is working as expected by 
monitoring with 
   `watch -n 0.1 "eza -la ~/Apache/iggy/local_data/logs"`
   
   <details>
   <summary>eza -la with 10:100</summary>
   
   ```Console
   Every 0.1s: eza -la ~/Apache/iggy/local_data/logs
   
   .rw-r--r--@ 2.4M svecco 11 Jan 13:10 iggy-server.log
   .rw-r--r--@  10M svecco 11 Jan 13:04 iggy-server.log.1
   .rw-r--r--@  10M svecco 11 Jan 13:04 iggy-server.log.2
   .rw-r--r--@  10M svecco 11 Jan 13:04 iggy-server.log.3
   .rw-r--r--@  10M svecco 11 Jan 13:04 iggy-server.log.4
   .rw-r--r--@  10M svecco 11 Jan 13:04 iggy-server.log.5
   .rw-r--r--@  10M svecco 11 Jan 13:04 iggy-server.log.6
   .rw-r--r--@  10M svecco 11 Jan 13:03 iggy-server.log.7
   .rw-r--r--@  10M svecco 11 Jan 13:03 iggy-server.log.8
   .rw-r--r--@  10M svecco 11 Jan 13:03 iggy-server.log.9
   ```
   </details>
   
   Additionally, the result of the simple integration test `cargo test -p 
integration server::specific::log_rotation_should_launch -- --nocapture` 
execution seems fine, by generating sufficient logs by sending a large volume 
of messages to trigger the log rotation mechanism.
   
   <details>
   <summary>Console</summary>
   
   ```console
   ╭─ $ [svecco] ~/A/iggy git!(46-size-logs)
   ╰─ > cargo test -p integration server::specific::log_rotation_should_launch 
-- --nocapture
      Compiling libz-sys v1.1.23
      Compiling liblzma-sys v0.4.4
      Compiling hwlocality-sys v0.6.4
      Compiling libgit2-sys v0.18.3+1.9.2
      Compiling liblzma v0.4.5
      Compiling hwlocality v1.0.0-alpha.11
      Compiling compression-codecs v0.4.35
      Compiling async-compression v0.4.36
      Compiling async_zip v0.0.18
      Compiling git2 v0.20.3
      Compiling vergen-git2 v1.0.7
      Compiling server v0.6.1-edge.3 (/home/svecco/host/apache/iggy/core/server)
      Compiling integration v0.0.1 
(/home/svecco/host/apache/iggy/core/integration)
       Finished `test` profile [unoptimized + debuginfo] target(s) in 7.71s
        Running unittests src/lib.rs 
(target/debug/deps/integration-375a7f260e09ad62)
   
   running 0 tests
   
   test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; 
finished in 0.00s
   
        Running tests/mod.rs (target/debug/deps/mod-0f48c9a972f7dba1)
   
   running 1 test
   Log directory verified: 
local_data_136642763006894046097605999160554396417/logs
   Succeeded Verified Log Rotation
   test server::specific::log_rotation_should_launch ... ok
   
   test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 1190 filtered 
out; finished in 2.12s
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to