If we have more number of packages in the Meteor Application, Is it going to effect the application speed ? (Like the server side operations and loading time).
-Thanks
I think it just needs a little more time to load all the packages and start your app.
But if you manage your publications and subscriptions properly, and don't load unnecessary data when you don't need it, you should be good.
Related
I am working on Meteor app(e-commerce site), became very large. It almost takes 9secs to view static part of homepage till then it only shows white/blank screen. After that it starts showing data from DB(mongoDB). The whole site with data takes ~24secs to come at client side. I think the whole bundle is too much huge and that is why it takes more time to download. And it is causing 9secs of white screen. Any solution guys. Thanks in advance!
Alraedy Tried:
1. Fast Render(Flowrouter subscriptions) package
2. Appcache package
3. Query Optimization/Indexing
4. Removed global subscriptions
5. Sending minimal data via pub/sub
6. this.unblock() for publications
7. Not saving files in DB instead saving url's
You are working on an e-commerce website and so you might have a huge admin module bundled with your website. You should consider building the admin module as a separate Meteor app sharing the same Mongo DB collections with the e-commerce website. You can reduce the size of you app considerably using this approach. You can find more details here
You should also be really careful about your subscriptions and use pagination on the server side publications, subscribing to only what data is actually required
For starters, try to remove unused packages which aren't used anymore by any frontend code. Check your entire package.json and all imports.
Reduce the size of all you subscriptions, you probably have tons of them with entire or too big documents, which is easy while developing, but an overkill in production. Try to limit the fields and the amount of loaded objects to what you visualise for the user.
Don't wait for all subscriptions to finsih loading before showing something, load the website and it's design already, but only show a 'loading' icon on the parts that do require data to be shown dynamically.
Make sure your javascript is minified before it's published, this saves a lot of bandwidth.
After implementing these your load times should have decreased.
Providing a detailed network analytic from the debugger of your browser might also help to notcie problems.
I have to deploy now my app and I was wondering to my self if is a good idea bring apps to production with the account-base package. Wouldn't be better to manage this with our own methods?
I think trying to manage it all yourself is a sure fire way to run into problems in the future. The concept of accounts seems simple, but the implementation never is especially when you start sprinkling in all the extra complexities (registration, resetting passwords, validation emails, 3rd party authentication, role based authorization, complete integration with your app, etc.).
At the end of the day, you dont gain much by spending days (or more) implementing and testing (hoping that you got everything right) that stuff when you could be spending​ that time on building the next big app. I'd much rather use tried and try packages that have verified by thousands of users across thousands of apps instead of trying to roll my own.
It depends on your purposes and preferences. Since account-base seems to fit well on my projects, I recommend you to get the most out of it and don't waste your time reinvent the wheel.
However, in the scope of meteor, if you want to make changes to the package, you can clone it to the packages directory and modify it your way.
The solution is create as many fields as I want and onCreateUser get them and save this on my ddbb
More info: http://docs.meteor.com/api/accounts-multi.html#AccountsServer-onCreateUser
I currently manage Web App on a LAMP stack hosted with GreenGeeks. As it has scaled up, I have started learning MeteorJS on my local machine and am thinking about redeveloping the app in Meteor to support more concurrent connections. My questions are:
Can Meteor simply be hosted in a Simple Amazon S3 Bucket with no need for a stack of any kind? Is this smart? When something seems this simple, I get nervous.
Is Meteor as portable as it feels? Migrating a LAMP app from one server to another can be a real pain. This "feels" like it's as simple as zipping up the whole thing and simply dragging it anywhere. Again, feels too simple = nervous.
Is meteor the right choice if I am looking to maximize concurrent connections and reduce the number of times I need to go to the server for information? My app loads about 2 MB of data per user and I'd love a situation where this can be loaded once and the user has it available to interact with without going to the server (unless it changes).
Ok answers to your questions:
Well actually You can deploy your meteor app into an Amazon EC2 instance, the process is pretty easy, take a look to This video
Meteor is incredible portable, actually it was made with nodejs, therefore it inherits its features
You are in the right way, you know meteor is reactive, it acts in real time, also uses mongoDB, which is incredible faster than a regular SQL database, so in general meteor's performance is amazing, in fact, there are lots of packages that improve even more the performance of your app like this one and many others
I need design a dashboard for my meteor app. I need obtain profiling data: collections, publishhing, client subscriptions, etc
Is it possible ?
Of course it is possible, Kadira has done just that. There is also meteor-analytics package, more info on that in this video.
Is there an alternative to meteor's spiderable package that caches the phantomjs-rendered pages? I have a site with over 50,000 pages. If I use spiderable then not only are the page load times higher than they should be -- which affects search engine performance -- it also bogs down my machine.
I'm OK forking the spiderable package and adding a caching function to it, but if there is an alternative then I'd like to hear about it. I don't want to use the server-side handlebars package, and also Arunoda's great new ssr package is not quite for me, because it would still require a good amount of reworking on my app.
If your pages don't change often, you could put a caching reverse proxy like Varnish in front of your Meteor app. This should relieve a lot of strain on the app itself.
I went ahead and created a cached version of the spiderable package.
https://atmospherejs.com/chfritz/spiderable