What do you guys use to track performance now that Kadira is gone?

It’s working great now. No more app crashes.

One thing though is my Kadira instance isn’t showing anything other than the configuration screen for Meteor app. How long does it take before I see data for my Meteor app?

Kadira-ui port 4000 is for your nginx server to forward the port 80 to. Please remember to set EXPORT_OPTIONS_URL = “http://yourkadirasite.com:11011” in the /Kadira-server/unit-shell.sh

It usually takes only a minute for the data to pass. You are very close now, I got stuck at the same place before too. :slight_smile:

1 Like

No I think that’s fine I can see the UI for Kadira and everything. I’m saying that after deploying the settings for my app and using it a bit, I still see the configure your app screen on my Kadira instance.

Does it normally take more than a few minutes for data to show up?

Are you sure it’s EXPORT_OPTIONS_URL? Also, shouldn’t it be /kadira-server/init-shell.sh? Thanks!

Yes you are right. iPhone autocorrected the lowercase to uppercase. And the EXPORT_OPTIONS_URL is all upper case.

I updated my file at ~/kadira-server/init-shell.sh

# Engine settings
export ENGINE_PORT=11011
export EXPORT_OPTIONS_URL="http://my.ip.ip.ip:11011"

# UI settings
export UI_PORT=4000
export UI_URL="http://localhost:$UI_PORT"

Do I need to restart anything for these settings to be used?

Happy to report everything working great! The guide from medium was great but left out a lot of small details that I think I can expand upon.

Comprehensive guide coming soon!

Like literally, from A to Z to get your own Kadira running. :slight_smile:

4 Likes

Great to hear you are able to setup Kadira. Sounds you got MongoDB Hosted locally ? I could run run kadira pointing to mlab, but when point to local, the database crashes. Must be some con fig that I am missing.
Waiting for your guide…

Look forward to seeing the guide :smiley:

Tried your A-Z guide, and got it working :slight_smile: However, it seems like the UI does not refresh itself automaticly, like the charts etc. I had my own version running on AWS, and there this worked fine.

Do you know why this happens?

EDIT: It seems like the UI refreshes automaticly, but not very often. Maybe each 30 mins or something.

Guide can be found here! A to Z guide: How to setup your own Kadira instance on a VPS like DigitalOcean

Hey, having the same exact issue with charts auto update. As a quick workaround I noticed that it updates charts if you navigate around tabs (e.g. from “overiview” to “methods” and back) but that’s pretty annoying.
Wondering if you have figured out what’s wrong with it.
Sounds like it’s a config issues rather than code.

OK I was able to figure it out.
I think it’s related to version of meteor I use (I use it on ~1.4 and deploy to heroku using latest buildpack horse).
Looks like 1.4 handles publications differently and actually treats removing and adding documents with same ids as change event rather than remove & create. That’s exactly what we have here https://github.com/kadira-open/kadira-server/blob/master/kadira-ui/packages/kadira-data/lib/server/publish.js#L36-L44

So here https://github.com/kadira-open/kadira-server/blob/master/kadira-ui/packages/kadira-data/lib/client/api.js#L76-L79
added event only fires for the first time you load the page and all the subsequent times it actually fires changed instead, so adding changed handler fixes charts:

diff --git a/packages/kadira-data/lib/client/api.js b/packages/kadira-data/lib/client/api.js
index b06b983..3500ac9 100644
--- a/packages/kadira-data/lib/client/api.js
+++ b/packages/kadira-data/lib/client/api.js
@@ -76,6 +76,10 @@ KadiraData.observeMetrics = function observeMetrics(dataKey, args, callbacks) {
     added: function(doc) {
       KadiraData._metricsCache.set(hash, doc.data);
       dataVariable.set(doc.data);
+    },
+    changed: function(newDoc, oldDoc, atIndex) {
+      KadiraData._metricsCache.set(hash, newDoc.data);
+      dataVariable.set(newDoc.data);
     }
   });

(END)

In conclusion: either stick to older meteor versions or use this simple change.

1 Like

To all who may be interested, NodeChef offers performance monitoring (based on open source kadira). Any meteor app hosted anywhere can use this service!

Hy, thank’s for the guid

I ve an error when I try to set up Kadira Engine; when I run ./run.sh

It throws the error:

starting apm-engine on port 11011
Initialized Mongo Sharded Cluster for shards: one
DDONE
/root/kadira-server/kadira-engine/node_modules/mongodb/lib/mongo_client.js:452
throw err
^

Error: invalid schema, expected mongodb or mongodb+srv
at module.exports (/root/kadira-server/kadira-engine/node_modules/mongodb/lib/url_parser.js:15:21)
at connect (/root/kadira-server/kadira-engine/node_modules/mongodb/lib/mongo_client.js:485:3)
at Function.MongoClient.connect (/root/kadira-server/kadira-engine/node_modules/mongodb/lib/mongo_client.js:250:3)
at /root/kadira-server/kadira-engine/server.js:41:25
at /root/kadira-server/kadira-engine/node_modules/mongo-sharded-cluster/lib/index.js:131:5
at /root/kadira-server/kadira-engine/node_modules/mongo-sharded-cluster/node_modules/async/lib/async.js:52:16
at done (/root/kadira-server/kadira-engine/node_modules/mongo-sharded-cluster/node_modules/async/lib/async.js:248:21)
at /root/kadira-server/kadira-engine/node_modules/mongo-sharded-cluster/node_modules/async/lib/async.js:44:16
at /root/kadira-server/kadira-engine/node_modules/mongo-sharded-cluster/lib/index.js:118:9
at connectCallback (/root/kadira-server/kadira-engine/node_modules/mongodb/lib/mongo_client.js:527:5)
Did I miss anything ?

This might be an easier way to get application monitoring going: https://montiapm.com/

Huge respect to @zodern for his work on this and for revitalizing mup (in a big way). Awesome stuff!

1 Like

It’s not gone.
More characters

Thank’s for this work @zodern; I used it work as charm in local but there is a problem in dependency on deploy; so I can’t deploy it; can see the issue I opened for here, please!!!

@babrahams, did you see an issue like mine before ?