From 0279cc1bd6369c54c790b675d9b12f3c3f38aea0 Mon Sep 17 00:00:00 2001 From: Willi Goesgens Date: Thu, 30 Oct 2014 11:12:54 +0100 Subject: [PATCH 1/4] Output which ip/port we fail to bind. --- lib/Rest/EndpointIp.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Rest/EndpointIp.cpp b/lib/Rest/EndpointIp.cpp index 5c42319ed0..c567de0e66 100644 --- a/lib/Rest/EndpointIp.cpp +++ b/lib/Rest/EndpointIp.cpp @@ -155,9 +155,9 @@ TRI_socket_t EndpointIp::connectSocket (const struct addrinfo* aip, if (result != 0) { // error #ifndef _WIN32 - LOG_ERROR("bind() failed with %d (%s)", errno, strerror(errno)); + LOG_ERROR("bind(address '%s', port %d) failed with %d (%s)", host, (int) _port, errno, strerror(errno)); #else - LOG_ERROR("bind() failed with %d", WSAGetLastError()); + LOG_ERROR("bind(address '%s', port %d) failed with %d", host, (int) _port, WSAGetLastError()); #endif TRI_CLOSE_SOCKET(listenSocket); From e355f890d0884ecf6a12d76c200452663d923210 Mon Sep 17 00:00:00 2001 From: Willi Goesgens Date: Thu, 30 Oct 2014 12:50:51 +0100 Subject: [PATCH 2/4] Follow file renaming --- UnitTests/Makefile.unittests | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/UnitTests/Makefile.unittests b/UnitTests/Makefile.unittests index e495698eea..6cbca84320 100755 --- a/UnitTests/Makefile.unittests +++ b/UnitTests/Makefile.unittests @@ -632,10 +632,10 @@ SHELL_SERVER_AQL = @top_srcdir@/js/server/tests/aql-arithmetic.js \ @top_srcdir@/js/server/tests/aql-queries-fulltext.js \ @top_srcdir@/js/server/tests/aql-queries-geo.js \ @top_srcdir@/js/server/tests/aql-queries-noncollection.js \ - @top_srcdir@/js/server/tests/aql-queries-optimiser-in.js \ + @top_srcdir@/js/server/tests/aql-queries-optimiser-in-noncluster.js \ @top_srcdir@/js/server/tests/aql-queries-optimiser.js \ @top_srcdir@/js/server/tests/aql-queries-optimiser-limit-noncluster.js \ - @top_srcdir@/js/server/tests/aql-queries-optimiser-ref.js \ + @top_srcdir@/js/server/tests/aql-queries-optimiser-ref-noncluster.js \ @top_srcdir@/js/server/tests/aql-queries-optimiser-sort-noncluster.js \ @top_srcdir@/js/server/tests/aql-queries-simple.js \ @top_srcdir@/js/server/tests/aql-queries-variables.js \ From dcfe5bb7006d6e89c74b1fab4cfa6367c8a91128 Mon Sep 17 00:00:00 2001 From: Thomas Schmidts Date: Thu, 30 Oct 2014 13:59:52 +0100 Subject: [PATCH 3/4] Fixed #1046. Substring is now mentioned correctly --- Documentation/Books/Users/Aql/StringFunctions.mdpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/Books/Users/Aql/StringFunctions.mdpp b/Documentation/Books/Users/Aql/StringFunctions.mdpp index 26369373bd..da26fbd101 100644 --- a/Documentation/Books/Users/Aql/StringFunctions.mdpp +++ b/Documentation/Books/Users/Aql/StringFunctions.mdpp @@ -18,7 +18,8 @@ For string processing, AQL offers the following functions: - *SUBSTRING(value, offset, length)*: Return a substring of *value*, starting at *offset* and with a maximum length of *length* characters. Offsets - start at position 0 + start at position 0. Length is optional and if omitted the substring from *offset* + to the end of the string will be returned. - *LEFT(value, LENGTH)*: Returns the *LENGTH* leftmost characters of the string *value* From 501c721e721a62bbab1f88f4eb0a92066b94407f Mon Sep 17 00:00:00 2001 From: Willi Goesgens Date: Thu, 30 Oct 2014 14:16:08 +0100 Subject: [PATCH 4/4] Add jmeter JTL output format to perftests --- js/common/modules/reportgenerator.js | 25 ++++++++++++++++++++++++- js/server/perftests/sort.js | 2 +- 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/js/common/modules/reportgenerator.js b/js/common/modules/reportgenerator.js index 6d41c5fd8e..d1c1de6ee7 100644 --- a/js/common/modules/reportgenerator.js +++ b/js/common/modules/reportgenerator.js @@ -64,5 +64,28 @@ var generatePerfReportGrinderCSV = function (reportName, testdata) { }; +var generatePerfReportJTL = function(reportName, testdata) { + var testFileName = "out_" + reportName + "_perftest.jtl"; + var x = '\n\n'; + + for (var testname in testdata) { + if (testdata.hasOwnProperty(testname)) { + for (var testCalculation in testdata[testname]) { + if (testdata[testname].hasOwnProperty(testCalculation) && + (testCalculation !== 'status')) + { + var s = testdata[testname][testCalculation].duration; + if (!isNaN(s)) { + x = x + '\n' + } + } + } + } + } + x = x + ''; + fs.write(testFileName, x); +} + exports.reportGeneratorXML = generatePerfReportXML; -exports.generatePerfReportGrinderCSV = generatePerfReportGrinderCSV; \ No newline at end of file +exports.generatePerfReportGrinderCSV = generatePerfReportGrinderCSV; +exports.generatePerfReportJTL = generatePerfReportJTL; \ No newline at end of file diff --git a/js/server/perftests/sort.js b/js/server/perftests/sort.js index 5cf4fbf4a8..c110c0158c 100644 --- a/js/server/perftests/sort.js +++ b/js/server/perftests/sort.js @@ -399,7 +399,7 @@ var repgen = require("reportgenerator"); var ret = loadTestRunner.loadTestRunner(optimizerRuleTestSuite, testOptions, testMethods); //require("internal").print(JSON.stringify(ret)); -repgen.generatePerfReportGrinderCSV("sort", ret); +repgen.generatePerfReportJTL("sort", ret); return ret; // Local Variables: