You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by so...@apache.org on 2016/11/02 16:47:19 UTC

[trafficserver] branch 6.2.x updated (2b7ce34 -> 9cc8348)

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

sorber pushed a change to branch 6.2.x
in repository https://git-dual.apache.org/repos/asf/trafficserver.git.

      from  2b7ce34   TS-4732: Changing the do_io_read API so it can be called with NULL and 0 byte values.  Allowing do_io_read and do_io_write to not warn on closed connection when we are only trying to disable the reads and writes for it. Removed some macros that were used in a few places (not all the time) and a couple that were not used at all.
       new  c70125b   TS-4498: Log plugin remap error message.
       new  9cc8348   TS-4498: Log plugin remap error message.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "adds" were already present in the repository and have only
been added to this reference.


Summary of changes:
 proxy/ControlMatcher.h          |  2 +-
 proxy/http/remap/RemapConfig.cc | 10 ++++------
 2 files changed, 5 insertions(+), 7 deletions(-)

-- 
To stop receiving notification emails like this one, please contact
['"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>'].

[trafficserver] 01/02: TS-4498: Log plugin remap error message.

Posted by so...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sorber pushed a commit to branch 6.2.x
in repository https://git-dual.apache.org/repos/asf/trafficserver.git

commit c70125b79aefb16608d65614990132ff0a37411b
Author: Peter Chou <pb...@labs.att.com>
AuthorDate: Wed Jun 1 15:44:08 2016 -0700

    TS-4498: Log plugin remap error message.
    
    Add error logging of the returned error message if a remap plugin
    fails to initialize. Currently it just says "bailing out" which is
    not as useful.
    
    (cherry-picked from commit 42becd0857b7cb4e39c6fc15efd4fc1e25fafe20)
---
 proxy/ControlMatcher.h          | 2 +-
 proxy/http/remap/RemapConfig.cc | 9 ++++-----
 2 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/proxy/ControlMatcher.h b/proxy/ControlMatcher.h
index 8592ec4..3d78669 100644
--- a/proxy/ControlMatcher.h
+++ b/proxy/ControlMatcher.h
@@ -106,7 +106,7 @@
     if (_already == false)                                  \
       pmgmt->signalManager(MGMT_SIGNAL_CONFIG_ERROR, _buf); \
     _already = true;                                        \
-    Warning("%s", _buf);                                    \
+    Error("%s", _buf);                                      \
   }
 
 class HostLookup;
diff --git a/proxy/http/remap/RemapConfig.cc b/proxy/http/remap/RemapConfig.cc
index 4565fb2..06ac82e 100644
--- a/proxy/http/remap/RemapConfig.cc
+++ b/proxy/http/remap/RemapConfig.cc
@@ -800,7 +800,8 @@ remap_load_plugin(const char **argv, int argc, url_mapping *mp, char *errbuf, in
       ri.tsremap_version = TSREMAP_VERSION;
 
       if (pi->fp_tsremap_init(&ri, tmpbuf, sizeof(tmpbuf) - 1) != TS_SUCCESS) {
-        Warning("Failed to initialize plugin %s (non-zero retval) ... bailing out", pi->path);
+        snprintf(errbuf, errbufsize, "Failed to initialize plugin \"%s\": %s", pi->path,
+                 tmpbuf[0] ? tmpbuf : "Unknown plugin error");
         return -5;
       }
     } // done elevating access
@@ -867,9 +868,8 @@ remap_load_plugin(const char **argv, int argc, url_mapping *mp, char *errbuf, in
   ats_free(parv[1]); // toURL
 
   if (res != TS_SUCCESS) {
-    snprintf(errbuf, errbufsize, "Can't create new remap instance for plugin \"%s\" - %s", c,
+    snprintf(errbuf, errbufsize, "Failed to create instance for plugin \"%s\": %s", c,
              tmpbuf[0] ? tmpbuf : "Unknown plugin error");
-    Warning("Failed to create new instance for plugin %s (not a TS_SUCCESS return)", pi->path);
     return -8;
   }
 
@@ -1346,8 +1346,7 @@ remap_parse_config_bti(const char *path, BUILD_TABLE_INFO *bti)
 
   // Deal with error / warning scenarios
   MAP_ERROR:
-    Warning("Could not add rule at line #%d; Aborting!", cln + 1);
-    snprintf(errBuf, sizeof(errBuf), "%s %s at line %d", modulePrefix, errStr, cln + 1);
+    snprintf(errBuf, sizeof(errBuf), "%s failed to add remap rule at %s line %d: %s", modulePrefix, path, cln + 1, errStr);
     SignalError(errBuf, alarm_already);
     delete reg_map;
     delete new_mapping;

-- 
To stop receiving notification emails like this one, please contact
"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>.

[trafficserver] 02/02: TS-4498: Log plugin remap error message.

Posted by so...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sorber pushed a commit to branch 6.2.x
in repository https://git-dual.apache.org/repos/asf/trafficserver.git

commit 9cc83482e3c4e2cbd21d14280e9c8e296ca2679f
Author: Peter Chou <pb...@labs.att.com>
AuthorDate: Wed Sep 14 13:36:16 2016 -0700

    TS-4498: Log plugin remap error message.
    
    Ran clang-format [6.2.x] produced different results than [7.0.x].
---
 proxy/http/remap/RemapConfig.cc | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/proxy/http/remap/RemapConfig.cc b/proxy/http/remap/RemapConfig.cc
index 06ac82e..fd50297 100644
--- a/proxy/http/remap/RemapConfig.cc
+++ b/proxy/http/remap/RemapConfig.cc
@@ -868,8 +868,7 @@ remap_load_plugin(const char **argv, int argc, url_mapping *mp, char *errbuf, in
   ats_free(parv[1]); // toURL
 
   if (res != TS_SUCCESS) {
-    snprintf(errbuf, errbufsize, "Failed to create instance for plugin \"%s\": %s", c,
-             tmpbuf[0] ? tmpbuf : "Unknown plugin error");
+    snprintf(errbuf, errbufsize, "Failed to create instance for plugin \"%s\": %s", c, tmpbuf[0] ? tmpbuf : "Unknown plugin error");
     return -8;
   }
 

-- 
To stop receiving notification emails like this one, please contact
"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>.