diff --git a/README.md b/README.md index ee3ce2b..e0bf267 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ raygun4cfml Raygun.io API client for CFML. -Current Version: 1.2.1 (Jun 16 2021) +Current Version: 1.3.0 (July 21 2021) Dependencies: diff --git a/box.json b/box.json index c27fde3..d1c13c5 100644 --- a/box.json +++ b/box.json @@ -1,7 +1,7 @@ { "name":"raygun4cfml", - "version":"1.2.1", - "location":"MindscapeHQ/raygun4cfml#1.2.1", + "version":"1.3.0", + "location":"MindscapeHQ/raygun4cfml#1.3.0", "author":"Kai Koenig ", "homepage":"https://github.com/MindscapeHQ/raygun4cfml/", "documentation":"https://github.com/MindscapeHQ/raygun4cfml/blob/master/README.md", diff --git a/changelog.md b/changelog.md index 1e71bba..f0f7749 100644 --- a/changelog.md +++ b/changelog.md @@ -1,6 +1,10 @@ History ======= +1.3.0 (Jul 21 2021) + +- Raygun4CFML is now tracking heap memory in the `availableVirtualMemory` and `availableFreeMemory` fields and not physical memory anymore. Fixed accessibility issues of internal classes post-Java 8 and the library should now be working fine across all JDKs. + 1.2.1 (Jun 16 2021) - Minor changes to stacktrace handling @@ -8,7 +12,7 @@ History 1.2.0 (Jun 8 2021) -- Support for version (#34) +- Support for version (#33) - Fixed stack traces to work better with Lucee and ACF 2021 1.1.0 (Jan 2 2016) diff --git a/src/nz/co/ventego-creative/raygun4cfml/RaygunEnvironmentMessage.cfc b/src/nz/co/ventego-creative/raygun4cfml/RaygunEnvironmentMessage.cfc index 8f293f3..69d7f53 100644 --- a/src/nz/co/ventego-creative/raygun4cfml/RaygunEnvironmentMessage.cfc +++ b/src/nz/co/ventego-creative/raygun4cfml/RaygunEnvironmentMessage.cfc @@ -31,13 +31,13 @@ limitations under the License. var runtime = createObject("java", "java.lang.System"); var props = runtime.getProperties(); var mf = createObject("java", "java.lang.management.ManagementFactory"); - var osbean = mf.getOperatingSystemMXBean(); + var heapMem = mf.getMemoryMXBean().getHeapMemoryUsage(); + returnContent["availableVirtualMemory"] = heapMem.getCommitted()-heapMem.getUsed(); + returnContent["totalVirtualMemory"] = heapMem.getCommitted(); returnContent["architecture"] = props["os.arch"]; - returnContent["availablePhysicalMemory"] = osbean.getFreePhysicalMemorySize(); returnContent["osVersion"] = props["os.version"]; returnContent["packageVersion"] = props["java.vm.vendor"] & "|" & props["java.runtime.version"] & "|" & props["java.vm.name"]; - returnContent["totalPhysicalMemory"] = osbean.getTotalPhysicalMemorySize(); returnContent["platform"] = props["os.name"]; return returnContent;