Monitor spring web application on cloudfoundry - monitoring

I intend to monitor execution times of methods in a spring web application deployed on cloudfoundry.
I tried to integrate BTrace with the application during deployment but it didn't work.
Is there any tool which will help?

You could try using Spring Insight on Cloud Foundry: http://insight.cloudfoundry.com/
From their FAQ:
Insight is a byte-code instrumentation monitoring tool for development and production. It is designed to provide light-weight visibility into the operation of a user's application and enable applications to more easily transition into production.

Related

Spring Cloud Data Flow Java DSL for Task / Batch

I am wondering if there is any java dsl support for registering spring batch applications as SCDF taks? Till now I was able to find only streams support for Java DSL.
Any link in this direction will be much helpful. Also how to automatically deploy spring batch as SCDF tasks in production environment without any manual intervention.
Thank you.
There's Java DSL support for Tasks. This was recently introduced in 2.4 as part of the SCDF's IT test-suite, but it is not promoted as part of the SCDF's REST client that we ship as a library — see: spring-cloud/spring-cloud-dataflow#3949 / spring-io/dataflow.spring.io#242. Feel free to contribute the migration if you have cycles.
That said, though, we have end-to-end IT tests that leverage this capability [see: DataFlowIT.java#L771-L906], which we use for each commit based IT test runs internally. You could certainly follow this as a pattern to automate the creation and launch of the task/batch-jobs.

Can we perform load/stress tesing using new relic tool?

We have a requirement to perform stress testing on website for 1000 concurrent users. Is it possible using new relic (without use of jmeter)?
New Relic is a tool for monitoring applications (on the server and the end-user experience), transactions, and servers. You could use it to measure the effects of a large load, but it doesn't apply the load.
You could use something like Blitz, SOASTA, Cloud Assault, or BlazeMeter to apply load and run tests.
Yes it is possible. But if you have 1000 users i think you must use any hosting which provides cloud servers. I used Blazemeter and after testing i had very good reporting. I used their tutorial about new relic plugin

running delayed_job on each app server or on a separate instance?

We're migrating our application www.monaqasat.com from a single server to a distributed infrastructure and we're debating where to run delayed_job from. The two obvious options are:
From each app instance?
From a single (or redundant) utility server?
Any recommendations or pros/cons?
I would prefer to use a single utility server unless it starts to get overwhelming for a single server.
I would also look at Gearman- http://gearman.org/.
If you need some serious messaging then RabbitMq http://www.rabbitmq.com/ is a good choice.

Amazon ElasticBeanstalk vs Cloudfoundry vs other Cloud hosting services

I am looking at options to host my Grails webapp. Being just a new website I don't expect a lot of traffic to begin with but I would like to have the option to be able to expand without jumping through hoops without breaking the bank.
I have been pondering over Cloudfoundry and Amazon ElasticBeanstalk. Can someone point out the pros and cons of these services and also point me to other services that might be out there.
You might want to checkout CloudBees which provides:
CloudBees Grails Plugin - created by Marco Vermeulen leveraging the newly open sourced cloudbees-client-api
This blog post which explains Grails Continuous Deployment
The advantage of CloudBees is that is not only provides you with a runtime environment for your Grails apps but also a Development environment (Git, SVN, Maven repositories, Jenkins as a Services for continuous integration, etc.) that smoothly integrates with the PaaS. Also, CloudBees PaaS offers free apps (actually, you can try all of their features for free), clustering/HA, automatic scalability, and a fancy delta-deployer which makes subsequent uploads of your apps a breeeeeeze.
There is also stax.net. It costs a little more than cloudfoundry (it adds some fees on the aws cost) but the advantage is that you can host more sites on a single vpn. (you can make slices of down to 256 mb). And the hosting for development and testing is free.
Recently it has been acquired and integrated into cloudbees. I don't know how CloudBees is, all I described about stax.net is on previous experience.
I don't have much experience but in the long run my bet will go with Amazon ElasticBeanstalk. Amazon is moving so fast ahead!
I know eApps is getting ready (as in any day now) to release their cloud service publicly. I used the service during their beta period, and it was actually really nice.
I had a VM loaded with ubuntu server, and then I loaded on mySQL, Apache2 and Tomcat, and then installed my app and off it went.
Really it's like a VPS, but cloud based where you can go and control your resources on the fly, so if you are looking for a SaaS solution, this would not be the route to go.
I've tried Amazons Elastic BeanStalk, but found that learning all of their terminology and figuring out the best strategy and services to use was just to complicated for my small app.

Profiler for a Grails Application

Are there any tools that can identify the total memory usage, cpu, and other information on resources of a specific grails web application deployed in a Tomcat server?
Also, if my grails app is using Quartz plugin, can anyone tell me how to profile a specific job instance?
Thanks!
I am using a bunch of tools for profiling and monitoring my own grails application. Here are the plugins/tools that help me to achieve this and work without any problems:
JavaMelody plugin : this tool is a must-have. Just install the plugin and go to /myapp/monitoring and you're done. You'll get all information you need on cpu, mem usage, sql queries, http errors...It should be enough for your needs described in your question
Application Info plugin : this very recent plugin is very useful and almost indispensable. It gives you various info about your application status. For your concerns, you will have access to graphs describing memory usage, information about sessions (opened or closed), detailed information on every aspect of your hibernate layer (cache, tables, entities...). Above all, this plugin is developped and supported by Burt Beckwith, member of SpringSource team.
Perf4j plugin : This plugin helps you collecting performance statistics with minimal effort. I am using it but it has better use whe tuning your application
You can also use other plugins/tools like : p6spy (for logging of SQL queries), Grails Audit Logging plugin (for tracking changes of domain objects) or Profiler plugin for which I can guarantee that they work correctly (not the case for all plugins!).
All of these plugins you can find by tag performance in Grails plugins portal
I hope it helps.
Here is some useful articles about performance tuning:
Tune the performance of Grails apps
GR8Conf 2011: Tuning Grails Applications by Peter Ledbrook
Profiling Grails Applications With VisualVM
http://grails.org/Profiler+Plugin
The profiler plugin that MTH mentions only gives you timing info for various parts of the Grails app. For monitoring resource usage, you're better off using JMX; here are a couple of links that should help.
Tomcat monitoring with JMX
Grails JMX plugin

Resources