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

Support Meteor 3 #93

Open
wants to merge 374 commits into
base: master
Choose a base branch
from
Open

Support Meteor 3 #93

wants to merge 374 commits into from

Conversation

leonardoventurini
Copy link
Contributor

@leonardoventurini leonardoventurini commented Feb 3, 2023

Remove fibers from the agent and integrate with Async Hooks and Async Local Storage.

@leonardoventurini
Copy link
Contributor Author

Milestone

Tests pass on Meteor's future release 3.0 branch

image

@leonardoventurini
Copy link
Contributor Author

Right now there is no way to know if a promise has been awaited or resolved in the background. What we can do is assume that an event which does not have other events in parallel has been awaited.

lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/tracer/tracer.js Outdated Show resolved Hide resolved
lib/ntp.js Outdated Show resolved Hide resolved
@@ -81,12 +80,6 @@ SystemModel.prototype.buildPayload = function () {
metrics.mongoPoolCheckedOutConnections = driverMetrics.checkedOut;
metrics.mongoPoolCreatedConnections = driverMetrics.created;

const fiberMetrics = getFiberMetrics();
Copy link
Member

@zodern zodern Jun 5, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would there be any async hooks/ALS metrics that would be useful instead? Can we track how many hooks or ASL stores are being used in the app?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can, will research.

lib/common/utils.js Outdated Show resolved Hide resolved
lib/common/utils.js Show resolved Hide resolved
lib/als/async-hook.js Outdated Show resolved Hide resolved
lib/als/async-hook.js Outdated Show resolved Hide resolved
lib/als/async-hook.js Outdated Show resolved Hide resolved
lib/als/async-hook.js Outdated Show resolved Hide resolved
lib/als/async-hook.js Outdated Show resolved Hide resolved
lib/als/async-hook.js Outdated Show resolved Hide resolved
@alisnic
Copy link

alisnic commented Jan 28, 2025

@zodern beta14 fixed TLA issue I reported in #134, but not completely. Right now it appears only in unit tests:

$ meteor test --driver-package meteortesting:mocha --settings config/unit-test.json --port 5005 --raw-logs --exclude-archs 'web.browser.legacy, web.browser'

[[[[[ Tests ]]]]]                             

=> Started proxy.                             
=> Started MongoDB.                           

=> Linted your app. No linting errors.        
RedisOplog - Established connection to redis. 

packages/core-runtime.js:189
            throw error;
            ^

TypeError: TwitterMediaUpload is not a constructor
    at Suite.<anonymous> (<snip>/mediaUpload.tests.ts:29:18)
    at Object.create (/Users/alisnic/.meteor/packages/meteortesting_mocha-core/.8.2.0.1s90yp2.o02v++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/mocha/lib/interfaces/common.js:148:19)

Mocha versions:

meteortesting:mocha@3.2.0
meteortesting:mocha-core@8.2.0

If I start the server, the error does not appear. If I remove montiapm:agent from .meteor/packages, the error does not appear as well

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

Successfully merging this pull request may close these issues.

7 participants