This is an automated email from the ASF dual-hosted git repository.

burcham pushed a commit to branch sni
in repository https://gitbox.apache.org/repos/asf/geode-benchmarks.git


The following commit(s) were added to refs/heads/sni by this push:
     new 56ffbfd  turn on haproxy debug logging
56ffbfd is described below

commit 56ffbfd7b937188db70c5a04c229691c26db01b1
Author: Bill Burcham <bburc...@pivotal.io>
AuthorDate: Fri May 29 15:15:19 2020 -0700

    turn on haproxy debug logging
---
 .../java/org/apache/geode/benchmark/tasks/StartSniProxy.java   | 10 +++++++++-
 .../org/apache/geode/benchmark/tasks/StartSniProxyTest.java    |  5 ++++-
 2 files changed, 13 insertions(+), 2 deletions(-)

diff --git 
a/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tasks/StartSniProxy.java
 
b/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tasks/StartSniProxy.java
index d305a07..ebf0764 100644
--- 
a/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tasks/StartSniProxy.java
+++ 
b/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tasks/StartSniProxy.java
@@ -95,7 +95,15 @@ public class StartSniProxy implements Task {
     final Iterable<String> serversInternal = 
serversInternalStream.collect(Collectors.toList());
     final Iterable<String> serversExternal = 
serversExternalStream.collect(Collectors.toList());
 
-    final StringBuilder stuff = new StringBuilder("defaults\n"
+    final StringBuilder stuff = new StringBuilder(
+        /*
+         log to stdout per:
+          
https://www.haproxy.com/documentation/hapee/latest/administration/docker-logging/
+         */
+          "global\n"
+        + "  log stdout format raw local0 debug\n"
+        + "defaults\n"
+        + "  log global\n"
         + "  timeout client 1000\n"
         + "  timeout connect 1000\n"
         + "  timeout server 1000\n"
diff --git 
a/geode-benchmarks/src/test/java/org/apache/geode/benchmark/tasks/StartSniProxyTest.java
 
b/geode-benchmarks/src/test/java/org/apache/geode/benchmark/tasks/StartSniProxyTest.java
index 43195cb..2eb4170 100644
--- 
a/geode-benchmarks/src/test/java/org/apache/geode/benchmark/tasks/StartSniProxyTest.java
+++ 
b/geode-benchmarks/src/test/java/org/apache/geode/benchmark/tasks/StartSniProxyTest.java
@@ -31,7 +31,10 @@ class StartSniProxyTest {
             Stream.of("locator-one-external"),
             Stream.of("server-one-internal", "server-two-internal"),
             Stream.of("server-one-external", "server-two-external"));
-    assertThat(config).isEqualTo("defaults\n"
+    assertThat(config).isEqualTo("global\n"
+        + "  log stdout format raw local0 debug\n"
+        + "defaults\n"
+        + "  log global\n"
         + "  timeout client 1000\n"
         + "  timeout connect 1000\n"
         + "  timeout server 1000\n"

Reply via email to