question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

In "compare" mode HTML output only displays stats of first server

See original GitHub issue

Hi,

I’m using this code:

'use strict';

var fs = require('fs');
var open = require('open');
var apiBenchmark = require('api-benchmark');

var services = {
  server1: "http://localhost:4000/",
  server2: "http://localhost:9999/"
};

var routes = { route1: '/create/email' };

var opts = {
  runMode: 'parallel',
  minSamples: 5000
}

apiBenchmark.compare(services, routes, opts, function(err, results){
  apiBenchmark.getHtml(results, function(error, html){
    fs.writeFile('./output.html', html, function () {
      open('./output.html');
    });
  });
});

The HTML output opens correctly in the browser, but it only displays stats from “server1”. Is this the expected behavior? Shouldn’t it compare the performance of both (possibly wuth different colored lines)? Also, the “Request details” and “Response details” tabs don’t seem to work in this case.

screenshot

Thanks!

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
arufiancommented, Dec 14, 2018

Is this still unresolved ? I got the same issue, plus I couldn’t go to the other menu beside stats. I got this error on my console log.

benchmark.html:175 Uncaught TypeError: Cannot read property 'end' of undefined
    at Object.route (benchmark.html:175)
    at HTMLDocument.<anonymous> (benchmark.html:294)
    at l (jquery.min.js:4)
    at Object.fireWith [as resolveWith] (jquery.min.js:4)
    at Function.ready (jquery.min.js:4)
    at HTMLDocument.S (jquery.min.js:4)
0reactions
matteofiguscommented, Jan 28, 2019

I think this is still unresolved. Happy if anyone wants to attempt a Pull Request and/or Review existing ones 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Edit form and Display form controls in Power Apps
Display, edit, and create a record in a data source. ... DefaultMode - The initial mode of the form control. See the description...
Read more >
HTML output Tag
The <output> tag is used to represent the result of a calculation (like one performed by a script). Browser Support. The numbers in...
Read more >
tshark(1) Manual Page
TShark is a network protocol analyzer. It lets you capture packet data from a live network, or read packets from a previously saved...
Read more >
28.2. The Cumulative Statistics System
PostgreSQL's cumulative statistics system supports collection and reporting of information about server activity. Presently, accesses to tables and indexes ...
Read more >
4 Formatting Query Results
This chapter explains how to format your query results to produce a finished ... When displaying column headings, you can either use the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found