sleeplessman / javamelody

Automatically exported from code.google.com/p/javamelody
0 stars 0 forks source link

Allow monitoring-path to be configured on the collector server as well #442

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Change the monitoring-path of the application to be monitored in web.xml:
       <init-param>
           <param-name>monitoring-path</param-name>
           <param-value>performance</param-value>
       </init-param>
and deploy it on an application server. In this example it is running on port 
8180.

2. Configure the application server where the collector server will be deployed 
with:
-Djavamelody.monitoring-path=app-monitoring
For this example the application server for the collector server will be 
running on port 8080.

3. Start the application server of the collector server

3. Try to add the web application of 1 by providing 
Name of application to monitor : myapp
URL(s) : http://localhost:8180/myapp

What is the expected output? What do you see instead?
I would expect the application myapp to be added to the collector server.
Instead I get this error:
Have you configured JavaMelody in this application ?
java.io.FileNotFoundException: 
http://localhost:8180/myapp/monitoring?collector=stop&format=serialized

What version of the product are you using? On what application server, JDK,
operating system?
javamelody 1.53.0 built from svn tag
jdk1.7.0_67
jboss 5.0.1-jdk6

Please provide any additional information below.
We've been using (and liking!) java melody for a couple of years now. Since we 
use a collector server but do not use the standard /monitoring path, we feel 
that we should be able to configure the monitoring path there as well. I have 
created a patch file (though from git) which I hope you will find usefull and 
incorporate in your next release.

Original issue reported on code.google.com by dmo...@gmail.com on 21 Oct 2014 at 2:00

Attachments:

GoogleCodeExporter commented 9 years ago
Hi,
Sorry for the delay. But thanks for the patch.

I have changed it a bit and it's committed in trunk
(revision 3965: refactoring without feature change, and revision 3966: this 
feature).
And it's ready for the next release (1.54).

If you want to use the version from trunk or v1.54, note that:
- the monitoring-path parameter was supposed to start with "/"
- my changes suppose that, unlike the patch,
- and so, you may need then to change your configuration. For example, use 
"/performance" as value for this parameter (not "performance").

In the release notes for this feature in v1.54, I will note "dmouch" for this, 
or whatever name you may wish for this. You may add comments in this issue if 
you want.

Original comment by evernat@free.fr on 13 Nov 2014 at 10:03

GoogleCodeExporter commented 9 years ago
Hi, 
thank you. Please enter Dimitris Mouchritsas & Manolis Pitarokilis.
The 2nd person is my manager and he did the initial work on this.

Original comment by dmo...@gmail.com on 14 Nov 2014 at 12:40

GoogleCodeExporter commented 9 years ago
ok

Original comment by evernat@free.fr on 14 Nov 2014 at 1:27