Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nsqadmin: connections count fixes #1134

Merged
merged 4 commits into from
Feb 11, 2019
Merged

Conversation

ploxiln
Copy link
Member

@ploxiln ploxiln commented Feb 8, 2019

The total connections count on the Topic page was accidentally broken recently in #1118.

I'm not sure when the rate column in the Totals row of the Channel page started having an issue, the code has been that way since 2015 ...

I also had some problems with gulp:

with nodejs 10.x:

$ ./gulp clean build
internal/util/inspect.js:31
const types = internalBinding('types');
              ^

ReferenceError: internalBinding is not defined
    at internal/util/inspect.js:31:15
    at req_ (/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/node_modules/natives/index.js:137:5)
    at require (/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/node_modules/natives/index.js:110:12)
    at util.js:25:21
    at req_ (/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/node_modules/natives/index.js:137:5)
    at require (/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/node_modules/natives/index.js:110:12)
    at fs.js:42:21
    at req_ (/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/node_modules/natives/index.js:137:5)
    at Object.req [as require] (/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/node_modules/natives/index.js:54:10)
    at Object.<anonymous> (/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/node_modules/graceful-fs/fs.js:1:99)

first attempt with nodejs 8.x:

$ ./gulp clean build
[16:54:15] Using gulpfile ~/go/src/github.com/nsqio/nsq/nsqadmin/gulpfile.js
[16:54:15] Starting 'clean'...
[16:54:15] Finished 'clean' after 6.57 ms
[16:54:15] Starting 'sass'...
[16:54:15] Finished 'sass' after 2.8 ms
[16:54:15] Starting 'browserify'...
[16:54:15] Starting 'sync-static-assets'...
[16:54:15] Starting 'vendor-build-js'...
[16:54:15] 'sync-static-assets' errored after 61 ms
[16:54:15] Error: EEXIST: file already exists, mkdir '/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/static/build'
events.js:183
      throw er; // Unhandled 'error' event
      ^

Error: ENOENT: no such file or directory, open '/Users/pierce/go/src/github.com/nsqio/nsq/nsqadmin/static/build/base.css'
Segmentation fault: 11

just doing a "gulp clean" on its own seemed to resolve all my issues after that.

cc @mreiferson @jehiah

@ploxiln
Copy link
Member Author

ploxiln commented Feb 8, 2019

a bit more reference, from https://github.com/gulpjs/gulp-cli#flags

--series |   | Run tasks given on the CLI in series (the default is parallel).

nsqadmin/README.md Outdated Show resolved Hide resolved
@mreiferson
Copy link
Member

LGTM otherwise

@mreiferson mreiferson added the bug label Feb 8, 2019
@ploxiln ploxiln force-pushed the nsqadmin_client_count branch from 11fbb2f to 8c730f2 Compare February 8, 2019 23:26
@ploxiln
Copy link
Member Author

ploxiln commented Feb 8, 2019

By the way, I think the gulp issue I ran into was not because clean and build were run in parallel (that might be new in gulp 4.x and the --series flag is also new), I think it was because of sync-static-assets,vendor-build-js, and browserify running in parallel (https://github.com/gulpjs/gulp/blob/v3.9.1/docs/API.md#gulptaskname--deps-fn) and while I think they should be independent, they can all try to "mkdir build" if it is missing.

clients array is no longer populated if only count is needed
seems our versions of npm packages does not work with nodejs 10.x
gulp clean and build in parallel does not always work
@ploxiln ploxiln force-pushed the nsqadmin_client_count branch from 8c730f2 to 69cdeba Compare February 10, 2019 01:18
@ploxiln ploxiln merged commit cbdcd54 into nsqio:master Feb 11, 2019
@ploxiln ploxiln deleted the nsqadmin_client_count branch August 27, 2019 07:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants