cashlalala / javamelody

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

systems-actions no longer appear #109

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Somewhere between .26 and .28 (I think in .27) my systems-actions disappeared 
(e.g.:
    View deployment descriptor 
MBeans MBeans     
View OS processes 
JNDI tree     
Opened jdbc connections
Database Database )

They show up in .26
My web.xml config for the filter:

    <filter>
        <description>Does monitoring through javamelody - see http://code.google.com/p/javamelody/wiki/UserGuide</description>
        <filter-name>javamelodyMonitoringFilter</filter-name>
        <filter-class>net.bull.javamelody.MonitoringFilter</filter-class>
        <init-param>
            <description>See http://code.google.com/p/javamelody/wiki/UserGuide, enables system cmds</description>
            <param-name>system-actions-enabled</param-name>
            <param-value>true</param-value>
        </init-param>
        <init-param>
            <description>Set this param to true to disable monitoring all together</description>
            <param-name>disable</param-name>
            <param-value>false</param-value>
        </init-param>
        <init-param>
            <description>Which metrics to display</description>
            <param-name>displayed-counters</param-name>
            <param-value>http,sql,error,log,jsp,spring,services</param-value>
        </init-param>
    </filter>

Original issue reported on code.google.com by davidkar...@gmail.com on 9 May 2011 at 8:31

GoogleCodeExporter commented 9 years ago
I do not reproduce the issue.
Are you sure that the system actions currently show up when you replace the 
v1.28 dependency with the v1.26 dependency?

Do you have a system property like -Djavamelody.system-actions-enabled=false 
when you start this server?
Do you have a call like System.setProperty("javamelody.system-actions-enabled", 
...) in your java code?
Do you have a context parameter javamelody.system-actions-enabled in your 
server configuration? (for example, in a xml file like 
Catalina/localhost/mywebapp.xml in Tomcat)
And do you use the official 1.28 build from googlecode or from the maven 
repository?

Original comment by evernat@free.fr on 11 May 2011 at 6:02

GoogleCodeExporter commented 9 years ago
I set no sys props and absoulutely not in code, no context params either.
jm from maven repo.
I'll try a downgrade tomorrow to test for sure.

Original comment by davidkar...@gmail.com on 11 May 2011 at 6:46

GoogleCodeExporter commented 9 years ago
do you have any news on this?

Original comment by evernat@free.fr on 30 May 2011 at 9:14

GoogleCodeExporter commented 9 years ago
I've double and triple checked my deployment descriptors and they look correct.
It is however probably not an javamelody error as it behaves the same in older 
versions - I suspect it to be a jetty problem.

Haven't had time to track it down though.

Setting the sysprops enables it for me - so I've used that as an workaround.

Original comment by davidkar...@gmail.com on 31 May 2011 at 12:10

GoogleCodeExporter commented 9 years ago
I had the same problem and used the same workaround as David. It works for each 
app, but not for the collector server. This is how i start it: java -server 
-Xmx128m -jar javamelody-1.29.0.war --httpPort=9990 --ajp13Port=8009 
-Djavamelody.system-actions-enabled=true

Original comment by stei...@gmail.com on 30 Jun 2011 at 11:37

GoogleCodeExporter commented 9 years ago
I am also having the same problem for the collector server, with the following 
configuration:
Application: jdk 1.6.0_25-b06, application is clustered on JBoss 5.1.0 with 2 
nodes
Collector server: jdk 1.6, tomcat-6.0.32
I am setting system-actions-enabled filter parameter to "true" inside my 
web.xml 
The links to the system actions are not visible, however the target URLs are 
accessible when I manually access them e.g.
http://collector-server/monitoring?part=sessions

Original comment by manolis....@gmail.com on 14 Jul 2011 at 2:18

GoogleCodeExporter commented 9 years ago
It's true that currently, the system actions must be enabled in the application 
AND in the collector server when a collector server is used.
For example with a system property when the collector server is started:
-Djavamelody.system-actions-enabled=true

It may be unfortunate indeed that the links to the system actions are not 
displayed for an application in the collector server just when they are enabled 
in the application itself.

But, I do not think that there was a collector server involved in the initial 
issue. 

Original comment by evernat@free.fr on 16 Jul 2011 at 11:41

GoogleCodeExporter commented 9 years ago
I think that there is a probably needed and simple fix: enable the system 
actions by default in the applications and in the collector server. Anyway, I 
always enable them in each application and probably a lot of users also.

When the system actions were created, the system actions were not enabled by 
default for:
- simplicity for beginners (ease understanding by removing some overwhelming 
and complex data from display)
- performance (GC and heap dumps can slow down the server for example)
- security and stability by default (GC and heap dump may be abused and 
invalidating sessions or killing a thread may alter the behavior of the server).

Finally, I don't think that the first two are really justified in the current 
UI and worth the trouble of enabling them in each application.
And if it is needed to disable the system actions for security reasons, it 
could be done whatever the default parameter value.

What do you think? Should the system actions be enabled by default?
I may then ask for feedback in the users' group.

Original comment by evernat@free.fr on 18 Jul 2011 at 11:41

GoogleCodeExporter commented 9 years ago
I think its a good idea to enable them by default. This however won't solve the 
bug. I have enabled it on all applications and it works for each application. 
Problem is that it does not work for the collector server even with the 
property -Djavamelody.system-actions-enabled=true set.

Original comment by stei...@gmail.com on 1 Aug 2011 at 12:31

GoogleCodeExporter commented 9 years ago
Hi all!

I have this problem too. I have an application (.war file). I started it on 
Jetty 7.4.1.
I set option system-actions-enabled to "true" in such way like you - in my 
web.xml (as described in UserGuide).

But, unfortunately, there are no any advanced options. My main goal is to 
monitor of classes and objects which captured most of cpu memory.

Is there some workaround how to activate this?

P.S.
What is collector server? Should I start it as standalone war? Or it's enough 
to deploy javamelody.jar in my .war as described in UserGuide?

Original comment by mighty.b...@gmail.com on 10 Aug 2011 at 7:56

GoogleCodeExporter commented 9 years ago
Hi,
Can you please say if you are in the case of the issue 147 which I have just 
created?
Thanks

(if the problem is in the collect server, your are not concerned)

Original comment by evernat@free.fr on 4 Oct 2011 at 9:42

GoogleCodeExporter commented 9 years ago

Original comment by evernat@free.fr on 4 Oct 2011 at 9:47

GoogleCodeExporter commented 9 years ago
Main issue was finally a duplicate of the newly created issue 147 as said by 
David Karlsen in issue 147 (the issue 109 was a hint of the problem).

And finally, system actions are now enabled by default as hinted above and 
because they are really useful.

So closing this issue as duplicate.
Thanks everyone here for your involvement.

Original comment by evernat@free.fr on 8 Oct 2011 at 9:21