You can subscribe to this list here.
2007 |
Jan
|
Feb
|
Mar
(927) |
Apr
(419) |
May
(352) |
Jun
(431) |
Jul
(463) |
Aug
(345) |
Sep
(304) |
Oct
(596) |
Nov
(466) |
Dec
(414) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2008 |
Jan
(348) |
Feb
(313) |
Mar
(665) |
Apr
(688) |
May
(434) |
Jun
(311) |
Jul
(540) |
Aug
(554) |
Sep
(467) |
Oct
(341) |
Nov
(365) |
Dec
(272) |
2009 |
Jan
(386) |
Feb
(293) |
Mar
(279) |
Apr
(239) |
May
(229) |
Jun
(199) |
Jul
(186) |
Aug
(111) |
Sep
(196) |
Oct
(146) |
Nov
(116) |
Dec
(140) |
2010 |
Jan
(170) |
Feb
(159) |
Mar
(151) |
Apr
(161) |
May
(90) |
Jun
(56) |
Jul
(28) |
Aug
(22) |
Sep
(5) |
Oct
|
Nov
(23) |
Dec
(12) |
2011 |
Jan
(8) |
Feb
(8) |
Mar
(22) |
Apr
(24) |
May
(4) |
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
2012 |
Jan
(5) |
Feb
(1) |
Mar
|
Apr
(1) |
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Doug M. <do...@hy...> - 2010-02-24 19:53:46
|
The original crash happens in the JVM, when using the distribution binary on your system. This crash is clearly happening within the sigar code. If you could do the following, we can see exactly where it's happening: % ant -Djni.debug=true % gdb `which java` (gdb) run -jar sigar-bin/lib/sigar.jar test Assuming this crashes, the last few lines of output should include the filename:linenumber of the crash. |
From: Doug M. <do...@hy...> - 2010-02-24 19:16:57
|
Hi Chakresh, There is a classpath issue running the 'test' command, you can workaround with: cp lib/*.jar sigar-bin/lib Clearly our binary compiled on RHEL 5.2 is not compatible with your SLES 10 system, unclear why however. Is zVM A and B running the same OS? The sources are compiled with -fPIC btw, see: ant -verbose 2>&1 | grep fPIC [cc] gcc -O2 -Wall -m64 -c -fPIC ... -Doug |
From: Doug M. <do...@hy...> - 2010-02-24 18:58:16
|
Hi Anthony, The only Sigar ant tasks that I'm aware of are for building the native binaries. Interested to hear what you had in mind? |
From: <no...@gi...> - 2010-02-24 17:46:25
|
Branch: refs/heads/master Home: http://github.com/hyperic/hqapi Commit: 998d209416ccb9f16811e3d3f4e3f181f50aa48b http://github.com/hyperic/hqapi/commit/998d209416ccb9f16811e3d3f4e3f181f50aa48b Author: Ryan Morgan <rm...@hy...> Date: 2010-02-24 (Wed, 24 Feb 2010) Changed paths: M hqu/hqapi1/app/AlertdefinitionController.groovy M src/org/hyperic/hq/hqapi1/tools/AlertDefinitionCommand.java Log Message: ----------- [HHQ-3745] Clear session after each definition is processed to prevent exponential slowdown. A more general solution to this issue is needed. |
From: <no...@gi...> - 2010-02-24 17:46:04
|
Branch: refs/heads/hqapi-2.x Home: http://github.com/hyperic/hqapi Commit: 5c8734d9b73c1be01e2bbefe1d1c46c551e74427 http://github.com/hyperic/hqapi/commit/5c8734d9b73c1be01e2bbefe1d1c46c551e74427 Author: Ryan Morgan <rm...@hy...> Date: 2010-02-24 (Wed, 24 Feb 2010) Changed paths: M hqu/hqapi1/app/AlertdefinitionController.groovy M src/org/hyperic/hq/hqapi1/tools/AlertDefinitionCommand.java Log Message: ----------- [HHQ-3745] Clear session after each definition is processed to prevent exponential slowdown. A more general solution to this issue is needed. |
From: <bo...@hy...> - 2010-02-24 09:24:46
|
Author: bob Date: 2010-02-24 01:24:37 -0800 (Wed, 24 Feb 2010) New Revision: 14316 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14316 Modified: trunk/etc/version.properties Log: Release 4.3.0 build #1360 Modified: trunk/etc/version.properties =================================================================== --- trunk/etc/version.properties 2010-02-23 22:43:16 UTC (rev 14315) +++ trunk/etc/version.properties 2010-02-24 09:24:37 UTC (rev 14316) @@ -1,3 +1,3 @@ -#Tue Feb 23 00:27:30 PST 2010 +#Wed Feb 24 00:29:14 PST 2010 version=4.3.0 -build=1359 +build=1360 |
From: <dcr...@hy...> - 2010-02-23 22:43:24
|
Author: dcrutchf Date: 2010-02-23 14:43:16 -0800 (Tue, 23 Feb 2010) New Revision: 14315 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14315 Modified: trunk/web/js/schedule.js Log: [HHQ-3684] - Cannot select dates in 2009 from Alert calender Modified: trunk/web/js/schedule.js =================================================================== --- trunk/web/js/schedule.js 2010-02-23 09:22:13 UTC (rev 14314) +++ trunk/web/js/schedule.js 2010-02-23 22:43:16 UTC (rev 14315) @@ -71,7 +71,7 @@ var yearArr = new Array(); for (i=0; i<SEL_NUMYEARS; i++) { - yearArr[i] = i + SEL_STARTYEAR; + yearArr[i] = SEL_STARTYEAR - i; } /*----------- end DECLARATIONS -----------*/ |
From: Girish <sig...@hy...> - 2010-02-23 18:14:26
|
Hi, can i use this application to fetch Values of Remote System, values like Cpu usage, memory, disk space etc. |
From: Chakresh <sig...@hy...> - 2010-02-23 18:14:26
|
Hi Doug Update - running test command on sigar.jar with s390x.so gave the output but it crashed immediately after that (the target server is a 64-bit machine). A snanpshot of javacore file "3XMTHREADINFO "main" (TID:0x0000000080032800, sys_thread_t:0x000000008001B030, state:R, native ID:0x0000000000004A99) prio=5 4XESTACKTRACE at org/hyperic/sigar/Sigar.nativeClose(Native Method) 4XESTACKTRACE at org/hyperic/sigar/Sigar.close(Sigar.java:229) 4XESTACKTRACE at org/hyperic/sigar/cmd/Shell.shutdown(Shell.java:196) 4XESTACKTRACE at org/hyperic/sigar/cmd/Shell.main(Shell.java:230) 4XESTACKTRACE at sun/reflect/NativeMethodAccessorImpl.invoke0(Native Method) 4XESTACKTRACE at sun/reflect/NativeMethodAccessorImpl.invoke(NativeMethodAccessorImp l.java:79)" Also (as in previous post) there is a segmentation error and inaccessible memory address. I tried running 31-bit sigar files on this server and they run fine. Looks like it could be a machine configuration issue. Talked to IBM support and they recommend using the -fPIC flag for compilation and linking and test it out. I am not well versed with build configuration , so can you help me out where i can specify the flags for building sigar files. Thanks Chakresh |
From: Átila V. F. M. de O. <av...@ho...> - 2010-02-23 10:22:04
|
Actually, I want to know if it is possible to get the download speed. Is it? I think that in the other topic I did't make myself clear or I did't understand the concept of link speed... |
From: <bo...@hy...> - 2010-02-23 09:22:46
|
Author: bob Date: 2010-02-23 01:22:13 -0800 (Tue, 23 Feb 2010) New Revision: 14314 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14314 Modified: trunk/etc/version.properties Log: Release 4.3.0 build #1359 Modified: trunk/etc/version.properties =================================================================== --- trunk/etc/version.properties 2010-02-23 00:57:49 UTC (rev 14313) +++ trunk/etc/version.properties 2010-02-23 09:22:13 UTC (rev 14314) @@ -1,3 +1,3 @@ -#Mon Feb 22 00:27:53 PST 2010 +#Tue Feb 23 00:27:30 PST 2010 version=4.3.0 -build=1358 +build=1359 |
From: Chakresh <sig...@hy...> - 2010-02-23 04:28:16
|
This time the error reports different information Unhandled exception Type=Segmentation error vmState=0x00000000 J9Generic_Signal_Number=00000004 Signal_Number=0000000b Error_Value=3bb4f538 Signal_Code=0000 0001 Handler1=00000200002A4900 Handler2=00000200003122FC InaccessibleAddress=00000000238C9000 gpr0=0000000000000020 gpr1=00000000238C9E90 gpr2=0000000080030800 gpr3=0000020023A2DA2E gpr4=0000020023A0CB04 gpr5=0000000000000020 gpr6=3D4CCCD000000000 gpr7=00000200225EC128 gpr8=0000000000000007 gpr9=00000200225EC158 gpr10=00000200225EC158 gpr11=0000000080030800 gpr12=0000000000000000 gpr13=0000000080030800 gpr14=0000020023A0CB04 gpr15=000003FFFFFFD338 psw=0000020023A0CB1A mask=0705E00180000000 fpc=0008000000000000 fpr0 428e800000000000 (f: 0.000000, d: 4.191888e+12) fpr1 3f40000000000000 (f: 0.000000, d: 4.882812e-04) fpr2 3f40000000000000 (f: 0.000000, d: 4.882812e-04) fpr3 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr4 3f73333300000000 (f: 0.000000, d: 4.687499e-03) fpr5 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr6 3d4cccd000000000 (f: 0.000000, d: 2.046367e-13) fpr7 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr8 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr9 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr10 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr11 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr12 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr13 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr14 0000000000000000 (f: 0.000000, d: 0.000000e+00) fpr15 0000000000000000 (f: 0.000000, d: 0.000000e+00) Module=/opt/nsol/nsAaka/agents/nsAgent/lib/libsigar-s390x-linux.so Module_base_address=0000020023A00000 Target=2_30_20091103_45935_BHdSMr (Linux 2.6.5-7.308-s390x) CPU=s390x (2 logical CPUs) (0x139adc000 RAM) JVMDUMP006I Processing dump event "gpf", detail "" - please wait. JVMDUMP032I JVM requested System dump using '/opt/nsol/nsAaka/bin/core.20100222.180522.17981. 0001.dmp' in response to an event JVMDUMP010I System dump written to /opt/nsol/nsAaka/bin/core.20100222.180522.17981.0001.dmp JVMDUMP032I JVM requested Snap dump using '/opt/nsol/nsAaka/bin/Snap.20100222.180522.17981.00 02.trc' in response to an event JVMDUMP010I Snap dump written to /opt/nsol/nsAaka/bin/Snap.20100222.180522.17981.0002.trc JVMDUMP032I JVM requested Java dump using '/opt/nsol/nsAaka/bin/javacore.20100222.180522.1798 1.0003.txt' in response to an event JVMDUMP010I Java dump written to /opt/nsol/nsAaka/bin/javacore.20100222.180522.17981.0003.txt JVMDUMP013I Processed dump event "gpf", detail "". |
From: Chakresh <sig...@hy...> - 2010-02-23 04:28:16
|
Hi Doug I tried to use the new sigar files (compiled on zVM A) on another machine (zVM B) and again i am running into core dump issue. Can you help me out here as to why this is happening? Both machines are 64 bit (s390x). Appreciate all your help Thanks Chakresh |
From: <pn...@hy...> - 2010-02-23 00:57:59
|
Author: pnguyen Date: 2010-02-22 16:57:49 -0800 (Mon, 22 Feb 2010) New Revision: 14313 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14313 Modified: trunk/installer/data/hq-engine/jboss-log4j.xml Log: Remove leading spaces Modified: trunk/installer/data/hq-engine/jboss-log4j.xml =================================================================== --- trunk/installer/data/hq-engine/jboss-log4j.xml 2010-02-22 09:30:20 UTC (rev 14312) +++ trunk/installer/data/hq-engine/jboss-log4j.xml 2010-02-23 00:57:49 UTC (rev 14313) @@ -175,7 +175,7 @@ <!-- Use this category to log every instance of a group alert firing. Comment out if the log messages become unwieldy. - <category name=" org.hyperic.hq.galerts.processor.MemGalertDef.Fired"> + <category name="org.hyperic.hq.galerts.processor.MemGalertDef.Fired"> <priority value="DEBUG" /> </category> --> |
From: <no...@gi...> - 2010-02-22 20:53:18
|
Branch: refs/heads/master Home: http://github.com/hyperic/hqapi Commit: ff3dafd0067a4979b36d295119bc1c1cf0d1f689 http://github.com/hyperic/hqapi/commit/ff3dafd0067a4979b36d295119bc1c1cf0d1f689 Author: pnguyen <pnguyen@192.168.0.98> Date: 2010-02-22 (Mon, 22 Feb 2010) Changed paths: M src/org/hyperic/hq/hqapi1/tools/AlertCommand.java Log Message: ----------- [HHQ-3481] Add command line functionality to fix alerts with a reason/comment Commit: 4012db0921d4584decb96b5872cbab88c0b6f239 http://github.com/hyperic/hqapi/commit/4012db0921d4584decb96b5872cbab88c0b6f239 Author: pnguyen <pnguyen@192.168.0.98> Date: 2010-02-22 (Mon, 22 Feb 2010) Changed paths: M ChangeLog Log Message: ----------- Add ChangeLog for HHQ-3481 |
From: <bo...@hy...> - 2010-02-22 09:30:29
|
Author: bob Date: 2010-02-22 01:30:20 -0800 (Mon, 22 Feb 2010) New Revision: 14312 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14312 Modified: trunk/etc/version.properties Log: Release 4.3.0 build #1358 Modified: trunk/etc/version.properties =================================================================== --- trunk/etc/version.properties 2010-02-21 09:27:49 UTC (rev 14311) +++ trunk/etc/version.properties 2010-02-22 09:30:20 UTC (rev 14312) @@ -1,3 +1,3 @@ -#Sun Feb 21 00:27:44 PST 2010 +#Mon Feb 22 00:27:53 PST 2010 version=4.3.0 -build=1357 +build=1358 |
From: Chakresh <sig...@hy...> - 2010-02-21 18:32:54
|
Doug I compiled the source and was able to generate sigar.jar and libsigar-s390x-linux.so. Tried running 2 commands and below is the output (looks like there is some progress) etpgluz:/opt/sigar/hyperic-sigar-1.6.3-src/bindings/java/sigar-bin/lib # /opt/ibm/java-s390x-60/jre/bin/java -jar sigar.jar version Sigar version.......java=1.6.3.0, native=1.6.3.0 Build date..........java=02/17/2010 05:08 PM, native=02/17/2010 05:08 PM SCM rev.............java=exported, native=exported Archlib.............libsigar-s390x-linux.so Current fqdn........etpgluz.dal-ebis.ihost.com Hostname............etpgluz Current user........root OS description......SuSE 10 OS name.............Linux OS arch.............s390x OS machine..........s390x OS version..........2.6.16.60-0.54.5-default OS patch level......unknown OS vendor...........SuSE OS vendor version...10 OS code name........ OS data model.......64 OS cpu endian.......null Java vm version.....2.4 Java vm vendor......IBM Corporation Java home.........../opt/ibm/java-s390x-60/jre etpgluz:/opt/sigar/hyperic-sigar-1.6.3-src/bindings/java/sigar-bin/lib # /opt/ibm/java-s390x-60/jre/bin/java -jar sigar.jar test unknown command: test Is this the expected output for test command? I am wondering what change happened by compiling on this machine? Please let me know if you want me to try some other things. Thanks |
From: Chakresh <sig...@hy...> - 2010-02-21 18:32:51
|
Doug I ran this command "strace -f -o strace.txt /opt/ibm/java-s390x-60/jre/bin/java -jar sigar.jar version" and attaching stack trace file for the same. Thanks |
From: <bo...@hy...> - 2010-02-21 09:27:57
|
Author: bob Date: 2010-02-21 01:27:49 -0800 (Sun, 21 Feb 2010) New Revision: 14311 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14311 Modified: trunk/etc/version.properties Log: Release 4.3.0 build #1357 Modified: trunk/etc/version.properties =================================================================== --- trunk/etc/version.properties 2010-02-20 09:26:30 UTC (rev 14310) +++ trunk/etc/version.properties 2010-02-21 09:27:49 UTC (rev 14311) @@ -1,3 +1,3 @@ -#Sat Feb 20 00:26:58 PST 2010 +#Sun Feb 21 00:27:44 PST 2010 version=4.3.0 -build=1356 +build=1357 |
From: <bo...@hy...> - 2010-02-20 09:26:38
|
Author: bob Date: 2010-02-20 01:26:30 -0800 (Sat, 20 Feb 2010) New Revision: 14310 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14310 Modified: trunk/etc/version.properties Log: Release 4.3.0 build #1356 Modified: trunk/etc/version.properties =================================================================== --- trunk/etc/version.properties 2010-02-19 22:50:56 UTC (rev 14309) +++ trunk/etc/version.properties 2010-02-20 09:26:30 UTC (rev 14310) @@ -1,3 +1,3 @@ -#Fri Feb 19 00:27:35 PST 2010 +#Sat Feb 20 00:26:58 PST 2010 version=4.3.0 -build=1355 +build=1356 |
From: <dcr...@hy...> - 2010-02-19 22:51:05
|
Author: dcrutchf Date: 2010-02-19 14:50:56 -0800 (Fri, 19 Feb 2010) New Revision: 14309 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14309 Modified: trunk/src/org/hyperic/hq/ui/action/resource/hub/ResourceHubPortalAction.java Log: [HHQ-3746] - Clicking Applications at ResourceHub leads to stack trace at UI Modified: trunk/src/org/hyperic/hq/ui/action/resource/hub/ResourceHubPortalAction.java =================================================================== --- trunk/src/org/hyperic/hq/ui/action/resource/hub/ResourceHubPortalAction.java 2010-02-19 09:23:37 UTC (rev 14308) +++ trunk/src/org/hyperic/hq/ui/action/resource/hub/ResourceHubPortalAction.java 2010-02-19 22:50:56 UTC (rev 14309) @@ -337,7 +337,7 @@ List ids = new ArrayList(); if (resources != null) { - if (resources.size() > 0 && AppdefEntityConstants.APPDEF_TYPE_APPLICATION != resourceType) { + if (resources.size() > 0 && DEFAULT_RESOURCE_TYPE != resourceType && AppdefEntityConstants.APPDEF_TYPE_APPLICATION != resourceType) { // ...use the first element to check permission, since there's not an easy way to this that I know of... try { AuthzBoss authzBoss = ContextUtils.getAuthzBoss(ctx); |
From: Anthony S. <an...@dt...> - 2010-02-19 19:13:09
|
I can find no reference to mapping the SIGAR classes into Ant tasks searching this and development list. Does anyone know if there's an effort to produce Ant tasks underway anywhere? I'm part of the ControlTier project (http://controltier.org/wiki/Main_Page) and having such a set of tasks available would be an excellent interface into our (natively Ant) modules. Anthony Shortland, Mountain View, CA |
From: <bo...@hy...> - 2010-02-19 09:23:48
|
Author: bob Date: 2010-02-19 01:23:37 -0800 (Fri, 19 Feb 2010) New Revision: 14308 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14308 Modified: trunk/etc/version.properties Log: Release 4.3.0 build #1355 Modified: trunk/etc/version.properties =================================================================== --- trunk/etc/version.properties 2010-02-19 01:56:43 UTC (rev 14307) +++ trunk/etc/version.properties 2010-02-19 09:23:37 UTC (rev 14308) @@ -1,3 +1,3 @@ -#Thu Feb 18 00:27:03 PST 2010 +#Fri Feb 19 00:27:35 PST 2010 version=4.3.0 -build=1354 +build=1355 |
Author: dcrutchf Date: 2010-02-18 17:56:43 -0800 (Thu, 18 Feb 2010) New Revision: 14307 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14307 Modified: trunk/src/org/hyperic/hq/bizapp/server/session/GalertBossEJBImpl.java trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/ListAlertAction.java trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/PortalAction.java trunk/web/resource/common/monitor/alerts/ListAlerts.jsp Log: [HQ-2066] - User with no Fixed/Ack permission is able to see Ack icon on Alert list page for Group and Resouce alerts Modified: trunk/src/org/hyperic/hq/bizapp/server/session/GalertBossEJBImpl.java =================================================================== --- trunk/src/org/hyperic/hq/bizapp/server/session/GalertBossEJBImpl.java 2010-02-18 23:55:45 UTC (rev 14306) +++ trunk/src/org/hyperic/hq/bizapp/server/session/GalertBossEJBImpl.java 2010-02-19 01:56:43 UTC (rev 14307) @@ -45,6 +45,7 @@ import org.hyperic.hq.authz.server.session.ResourceGroup; import org.hyperic.hq.authz.server.session.ResourceGroupManagerEJBImpl; import org.hyperic.hq.authz.shared.PermissionException; +import org.hyperic.hq.bizapp.shared.AuthzBoss; import org.hyperic.hq.common.SystemException; import org.hyperic.hq.escalation.server.session.Escalatable; import org.hyperic.hq.escalation.server.session.Escalation; @@ -63,6 +64,7 @@ import org.hyperic.hq.galerts.server.session.GtriggerTypeInfo; import org.hyperic.hq.galerts.shared.GalertManagerLocal; import org.hyperic.hq.galerts.shared.GtriggerManagerLocal; +import org.hyperic.hq.ui.util.ContextUtils; import org.hyperic.util.TimeUtil; import org.hyperic.util.config.ConfigResponse; import org.hyperic.util.pager.PageControl; @@ -359,8 +361,10 @@ JSONArray jarr = new JSONArray(); try { - // ...check that user can view alert definitions... - SessionBase.canViewAlertDefinition(subj, new AppdefEntityID(g.getResource())); + AppdefEntityID entityId = new AppdefEntityID(g.getResource()); + + // ...check that user can view alert definitions... + SessionBase.canViewAlertDefinition(subj, entityId); alertLogs = _galertMan.findAlertLogsByTimeWindow(g, begin, end, pc); @@ -379,16 +383,27 @@ maxPauseTime = esc.getMaxPauseTime(); } + boolean canTakeAction = false; + + try { + // ...check that the user can fix/acknowledge... + SessionBase.canFixAcknowledgeAlerts(subj, entityId); + + canTakeAction = true; + } catch(PermissionException e) { + // ...the user can't fix/acknowledge... + } + jarr.put(new JSONObject() .put("id", alert.getId()) .put("time", date) .put("name", alert.getAlertDefinitionInterface().getName()) .put("defId", alert.getAlertDefinitionInterface().getId()) - .put("priority", - alert.getAlertDefinitionInterface().getPriority()) + .put("priority", alert.getAlertDefinitionInterface().getPriority()) .put("reason", alert.getShortReason()) .put("fixed", alert.isFixed()) .put("acknowledgeable", alert.isAcknowledgeable()) + .put("canTakeAction", canTakeAction) .put("maxPauseTime", maxPauseTime)); } } catch (PermissionException e) { Modified: trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/ListAlertAction.java =================================================================== --- trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/ListAlertAction.java 2010-02-18 23:55:45 UTC (rev 14306) +++ trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/ListAlertAction.java 2010-02-19 01:56:43 UTC (rev 14307) @@ -153,8 +153,6 @@ } catch(PermissionException e) { // ...the user can't fix/acknowledge... } - - request.setAttribute(Constants.CAN_TAKE_ACTION_ON_ALERT_ATTR, canTakeAction); for (Iterator<Alert> itr = alerts.iterator();itr.hasNext();) { Alert alert = itr.next(); Modified: trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/PortalAction.java =================================================================== --- trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/PortalAction.java 2010-02-18 23:55:45 UTC (rev 14306) +++ trunk/src/org/hyperic/hq/ui/action/resource/common/monitor/alerts/PortalAction.java 2010-02-19 01:56:43 UTC (rev 14307) @@ -40,6 +40,9 @@ import org.apache.struts.action.ActionMapping; import org.apache.struts.util.MessageResources; import org.hyperic.hq.appdef.shared.AppdefEntityID; +import org.hyperic.hq.authz.server.session.AuthzSubject; +import org.hyperic.hq.authz.shared.PermissionException; +import org.hyperic.hq.bizapp.shared.AuthzBoss; import org.hyperic.hq.bizapp.shared.EventsBoss; import org.hyperic.hq.bizapp.shared.GalertBoss; import org.hyperic.hq.escalation.server.session.Escalatable; @@ -47,6 +50,7 @@ import org.hyperic.hq.events.server.session.Alert; import org.hyperic.hq.events.server.session.AlertDefinition; import org.hyperic.hq.events.server.session.ClassicEscalationAlertType; +import org.hyperic.hq.events.server.session.SessionBase; import org.hyperic.hq.events.shared.AlertDefinitionValue; import org.hyperic.hq.events.shared.AlertValue; import org.hyperic.hq.galerts.server.session.GalertEscalationAlertType; @@ -119,8 +123,28 @@ Portal portal = Portal.createPortal(); AppdefEntityID aeid = RequestUtils.getEntityId(request); + + boolean canTakeAction = false; + + try { + ServletContext ctx = getServlet().getServletContext(); + int sessionId = RequestUtils.getSessionId(request).intValue(); + AuthzBoss authzBoss = ContextUtils.getAuthzBoss(ctx); + AuthzSubject subject = authzBoss.getCurrentSubject(sessionId); + + // ...check that the user can fix/acknowledge... + SessionBase.canFixAcknowledgeAlerts(subject, aeid); + + canTakeAction = true; + } catch(PermissionException e) { + // ...the user can't fix/acknowledge... + } + + request.setAttribute(Constants.CAN_TAKE_ACTION_ON_ALERT_ATTR, canTakeAction); + setTitle(aeid, portal, "alerts.alert.platform.AlertList.Title"); portal.setDialog(false); + if (aeid.isGroup()) { portal.addPortlet(new Portlet(".events.group.alert.list"), 1); Modified: trunk/web/resource/common/monitor/alerts/ListAlerts.jsp =================================================================== --- trunk/web/resource/common/monitor/alerts/ListAlerts.jsp 2010-02-18 23:55:45 UTC (rev 14306) +++ trunk/web/resource/common/monitor/alerts/ListAlerts.jsp 2010-02-19 01:56:43 UTC (rev 14307) @@ -351,7 +351,7 @@ <display:column width="7%" property="fixed" title="alerts.alert.AlertList.ListHeader.Fixed"> <display:booleandecorator flagKey="yesno"/> </display:column> - <display:column width="11%" property="acknowledgeable" title="alerts.alert.AlertList.ListHeader.Acknowledge" + <display:column width="11%" property="acknowledgeableAndCanTakeAction" title="alerts.alert.AlertList.ListHeader.Acknowledge" href="/alerts/RemoveAlerts.do?eid=${Resource.entityId.appdefKey}&alerts=${Alert.id}&buttonAction=ACKNOWLEDGE"> <display:booleandecorator flagKey="acknowledgeable"/> </display:column> |
From: <dcr...@hy...> - 2010-02-19 01:00:28
|
Author: dcrutchf Date: 2010-02-18 15:55:45 -0800 (Thu, 18 Feb 2010) New Revision: 14306 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=14306 Modified: trunk/src/org/hyperic/hq/authz/shared/ResourceOperationsHelper.java trunk/src/org/hyperic/hq/events/server/session/SessionBase.java Log: Made methods on ResourceOperationHelper static Modified: trunk/src/org/hyperic/hq/authz/shared/ResourceOperationsHelper.java =================================================================== --- trunk/src/org/hyperic/hq/authz/shared/ResourceOperationsHelper.java 2010-02-18 17:42:01 UTC (rev 14305) +++ trunk/src/org/hyperic/hq/authz/shared/ResourceOperationsHelper.java 2010-02-18 23:55:45 UTC (rev 14306) @@ -36,7 +36,7 @@ private static List operationsList; - public ResourceOperationsHelper() { + static { // ArrayList containing all the operations for each resource type... // ORDER IS IMPORTANT! operationsList = new ArrayList(48); @@ -88,74 +88,74 @@ operationsList.add(AuthzConstants.escOpModifyEscalation); operationsList.add(AuthzConstants.escOpRemoveEscalation); operationsList.add(null); - operationsList.add(null); + operationsList.add(null); } - - public String getOperationName(int resourceTypeCode, int operationCode) { + + public static String getOperationName(int resourceTypeCode, int operationCode) { return (String) operationsList.get(resourceTypeCode + operationCode); } - public String getCreateOperation(Resource resource) + public static String getCreateOperation(Resource resource) throws IllegalArgumentException { return getOperation(resource, CREATE); } - public String getReadOperation(Resource resource) + public static String getReadOperation(Resource resource) throws IllegalArgumentException { return getOperation(resource, READ); } - public String getUpdateOperation(Resource resource) + public static String getUpdateOperation(Resource resource) throws IllegalArgumentException { return getOperation(resource, UPDATE); } - public String getDeleteOperation(Resource resource) + public static String getDeleteOperation(Resource resource) throws IllegalArgumentException { return getOperation(resource, DELETE); } - public String getManageAlertOperation(Resource resource) + public static String getManageAlertOperation(Resource resource) throws IllegalArgumentException { return getOperation(resource, MANAGE_ALERTS); } - public String getManageControlOperation(Resource resource) + public static String getManageControlOperation(Resource resource) throws IllegalArgumentException { return getOperation(resource, MANAGE_CONTROLS); } - public String getCreateOperation(int resourceTypeId) + public static String getCreateOperation(int resourceTypeId) throws IllegalArgumentException { return getOperation(resourceTypeId, CREATE); } - public String getReadOperation(int resourceTypeId) + public static String getReadOperation(int resourceTypeId) throws IllegalArgumentException { return getOperation(resourceTypeId, READ); } - public String getUpdateOperation(int resourceTypeId) + public static String getUpdateOperation(int resourceTypeId) throws IllegalArgumentException { return getOperation(resourceTypeId, UPDATE); } - public String getDeleteOperation(int resourceTypeId) + public static String getDeleteOperation(int resourceTypeId) throws IllegalArgumentException { return getOperation(resourceTypeId, DELETE); } - public String getManageAlertOperation(int resourceTypeId) + public static String getManageAlertOperation(int resourceTypeId) throws IllegalArgumentException { return getOperation(resourceTypeId, MANAGE_ALERTS); } - public String getManageControlOperation(int resourceTypeId) + public static String getManageControlOperation(int resourceTypeId) throws IllegalArgumentException { return getOperation(resourceTypeId, MANAGE_CONTROLS); } - public String getResourceType(Resource resource) + public static String getResourceType(Resource resource) throws IllegalArgumentException, UnsupportedOperationException { if (resource == null || resource.getResourceType() == null) { throw new IllegalArgumentException("resource must be not be null and must have a valid resource type."); @@ -166,7 +166,7 @@ return getResourceType(resourceTypeId); } - public String getResourceType(int resourceTypeId) + public static String getResourceType(int resourceTypeId) throws IllegalArgumentException, UnsupportedOperationException { switch (resourceTypeId) { case AppdefEntityConstants.APPDEF_TYPE_PLATFORM: @@ -182,14 +182,14 @@ } } - private String getOperation(Resource resource, int operationCode) + private static String getOperation(Resource resource, int operationCode) throws IllegalArgumentException { int resourceTypeId = resource.getResourceType().getId().intValue(); return getOperation(resourceTypeId, operationCode); } - private String getOperation(int resourceTypeId, int operationCode) + private static String getOperation(int resourceTypeId, int operationCode) throws IllegalArgumentException { int resourceTypeCode; @@ -217,7 +217,7 @@ return getOperationName(resourceTypeCode, operationCode); } - public CodePair getResourceTypeOperationCodePair(String operationName) { + public static CodePair getResourceTypeOperationCodePair(String operationName) { int index = operationsList.indexOf(operationName); int resourceTypeCode = ((index < MULTIPLIER) ? 0 : index/MULTIPLIER) * MULTIPLIER; int operationCode = index - resourceTypeCode; @@ -225,7 +225,7 @@ return new CodePair(resourceTypeCode, operationCode); } - public class CodePair { + public static class CodePair { int resourceTypeCode; int operationCode; Modified: trunk/src/org/hyperic/hq/events/server/session/SessionBase.java =================================================================== --- trunk/src/org/hyperic/hq/events/server/session/SessionBase.java 2010-02-18 17:42:01 UTC (rev 14305) +++ trunk/src/org/hyperic/hq/events/server/session/SessionBase.java 2010-02-18 23:55:45 UTC (rev 14306) @@ -164,8 +164,6 @@ return ResourceManagerEJBImpl.getOne().findResource(id); } - private static ResourceOperationsHelper resourceOperationsHelper = new ResourceOperationsHelper(); - public static void canViewResourceTypeAlertDefinitionTemplate(AuthzSubject user) throws PermissionException { // ...right now, you have to be a member of the super user's role to do anything with @@ -210,14 +208,14 @@ throws PermissionException { // ...we need to check the resource associated with the alert definition to determine // if the user can view the alert definition. Must have read permission on resource... - checkAlertDefinitionPermission(user, entityId, resourceOperationsHelper.getReadOperation(entityId.getType())); + checkAlertDefinitionPermission(user, entityId, ResourceOperationsHelper.getReadOperation(entityId.getType())); } public static void canModifyAlertDefinition(AuthzSubject user, AppdefEntityID entityId) throws PermissionException { // ...we need to check the resource associated with the alert definition to determine // if the user can modify the alert definition. Must have modify permission on resource... - checkAlertDefinitionPermission(user, entityId, resourceOperationsHelper.getUpdateOperation(entityId.getType())); + checkAlertDefinitionPermission(user, entityId, ResourceOperationsHelper.getUpdateOperation(entityId.getType())); } public static void canCreateAlertDefinition(AuthzSubject user, AppdefEntityID entityId) @@ -226,7 +224,7 @@ // if the user can modify the alert definition. Must have modify permission on resource... // TODO ...If we introduce finer grained permission for Alert definition, we can make the change here // and the rest should just work... - checkAlertDefinitionPermission(user, entityId, resourceOperationsHelper.getUpdateOperation(entityId.getType())); + checkAlertDefinitionPermission(user, entityId, ResourceOperationsHelper.getUpdateOperation(entityId.getType())); } public static void canDeleteAlertDefinition(AuthzSubject user, AppdefEntityID entityId) @@ -235,7 +233,7 @@ // if the user can modify the alert definition. Must have modify permission on resource... // TODO ...If we introduce finer grained permission for Alert definition, we can make the change here // and the rest should just work... - checkAlertDefinitionPermission(user, entityId, resourceOperationsHelper.getUpdateOperation(entityId.getType())); + checkAlertDefinitionPermission(user, entityId, ResourceOperationsHelper.getUpdateOperation(entityId.getType())); } private static void checkAlertDefinitionPermission(AuthzSubject user, AppdefEntityID id, String operationName) @@ -303,9 +301,9 @@ // ...then check if we have fix/acknowledge permissions on alert... checkPermission(user.getId(), - resourceOperationsHelper.getResourceType(resourceTypeId), + ResourceOperationsHelper.getResourceType(resourceTypeId), entityId.getId(), - resourceOperationsHelper.getManageAlertOperation(resourceTypeId)); + ResourceOperationsHelper.getManageAlertOperation(resourceTypeId)); } } |