Skip to content
This repository has been archived by the owner on Jul 27, 2022. It is now read-only.

Event loop blocking #6

Open
confuser opened this issue Jan 15, 2016 · 2 comments
Open

Event loop blocking #6

confuser opened this issue Jan 15, 2016 · 2 comments

Comments

@confuser
Copy link

https://github.com/apigee/apigee-access/blob/master/lib/index.js#L208
https://github.com/apigee/apigee-access/blob/master/lib/index.js#L217
https://github.com/apigee/apigee-access/blob/master/lib/index.js#L220
https://github.com/apigee/apigee-access/blob/master/lib/index.js#L233
https://github.com/apigee/apigee-access/blob/master/lib/index.js#L239
https://github.com/apigee/apigee-access/blob/master/lib/index.js#L245

Calling getVault getQuota etc, all block the main process, the first time they're called.

If this is intentional, then can this please be documented, alongside an explanation, as blocking the event loop like this without any warning is unnerving.

@gbrail
Copy link
Contributor

gbrail commented Jan 15, 2016

I see what you mean -- most of those are require statements (so they're only blocked on file I/O) although some of them call into Java code inside Edge. Did you have a specific problem with one of these, or is it more of a general observation?

@confuser
Copy link
Author

I'm fairly new to the apigee platform, however as a Node.js developer, when I see code like that, alarm bells start ringing. It was more of a general observation, especially if Apigee ever allow running of native Node.js under v8, it will cause problems in the future.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants