diff --git a/hs_err_pid2272.log b/hs_err_pid2272.log new file mode 100644 index 0000000..9adb074 --- /dev/null +++ b/hs_err_pid2272.log @@ -0,0 +1,822 @@ +# +# There is insufficient memory for the Java Runtime Environment to continue. +# Native memory allocation (malloc) failed to allocate 1048576 bytes. Error detail: AllocateHeap +# Possible reasons: +# The system is out of physical RAM or swap space +# This process is running with CompressedOops enabled, and the Java Heap may be blocking the growth of the native heap +# Possible solutions: +# Reduce memory load on the system +# Increase physical memory or swap space +# Check if swap backing store is full +# Decrease Java heap size (-Xmx/-Xms) +# Decrease number of Java threads +# Decrease Java thread stack sizes (-Xss) +# Set larger code cache with -XX:ReservedCodeCacheSize= +# JVM is running with Unscaled Compressed Oops mode in which the Java heap is +# placed in the first 4GB address space. The Java Heap base address is the +# maximum limit for the native heap growth. Please use -XX:HeapBaseMinAddress +# to set the Java Heap base and to place the Java Heap above 4GB virtual address. +# This output file may be truncated or incomplete. +# +# Out of Memory Error (allocation.cpp:44), pid=2272, tid=18716 +# +# JRE version: OpenJDK Runtime Environment Temurin-21.0.9+10 (21.0.9+10) (build 21.0.9+10-LTS) +# Java VM: OpenJDK 64-Bit Server VM Temurin-21.0.9+10 (21.0.9+10-LTS, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, parallel gc, windows-amd64) +# No core dump will be written. Minidumps are not enabled by default on client versions of Windows +# + +--------------- S U M M A R Y ------------ + +Command Line: --add-modules=ALL-SYSTEM --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/sun.nio.fs=ALL-UNNAMED -Declipse.application=org.eclipse.jdt.ls.core.id1 -Dosgi.bundles.defaultStartLevel=4 -Declipse.product=org.eclipse.jdt.ls.core.product -Djava.import.generatesMetadataFilesAtProjectRoot=false -DDetectVMInstallationsJob.disabled=true -Dfile.encoding=utf8 -XX:+UseParallelGC -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -Dsun.zip.disableMemoryMapping=true -Xmx2G -Xms100m -Xlog:disable -javaagent:c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\lombok\lombok-1.18.39-4050.jar -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=c:\Users\Ajith\AppData\Roaming\Antigravity\User\workspaceStorage\a973566b49b2f02afff9ce8c986b3b69\redhat.java -Daether.dependencyCollector.impl=bf c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\server\plugins\org.eclipse.equinox.launcher_1.7.100.v20251111-0406.jar -configuration c:\Users\Ajith\AppData\Roaming\Antigravity\User\globalStorage\redhat.java\1.50.0\config_win -data c:\Users\Ajith\AppData\Roaming\Antigravity\User\workspaceStorage\a973566b49b2f02afff9ce8c986b3b69\redhat.java\jdt_ws --pipe=\\.\pipe\lsp-89eacfa0f44d6960932ad0e50fc86c6c-sock + +Host: AMD Ryzen 3 5300U with Radeon Graphics , 8 cores, 7G, Windows 11 , 64 bit Build 22621 (10.0.22621.5415) +Time: Mon Dec 15 18:00:17 2025 India Standard Time elapsed time: 287777.756378 seconds (3d 7h 56m 17s) + +--------------- T H R E A D --------------- + +Current thread (0x000001e03eda6d50): JavaThread "Attach Listener" daemon [_thread_in_vm, id=18716, stack(0x000000967f200000,0x000000967f300000) (1024K)] + +Stack: [0x000000967f200000,0x000000967f300000] +Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) +V [jvm.dll+0x6d6e29] +V [jvm.dll+0x8b4b76] +V [jvm.dll+0x8b712e] +V [jvm.dll+0x8b7813] +V [jvm.dll+0x283d86] +V [jvm.dll+0xc1277] +V [jvm.dll+0x6d76d9] +V [jvm.dll+0x133466] +V [jvm.dll+0x3f7ea6] +V [jvm.dll+0x85e9ad] +V [jvm.dll+0x6d565d] +C [ucrtbase.dll+0x29333] +C [KERNEL32.DLL+0x1259d] +C [ntdll.dll+0x5af78] + + +--------------- P R O C E S S --------------- + +Threads class SMR info: +_java_thread_list=0x000001e087f09d60, length=41, elements={ +0x000001e026423380, 0x000001e0264db2a0, 0x000001e0264dcaa0, 0x000001e03eda4fc0, +0x000001e03eda6d50, 0x000001e03eda8c40, 0x000001e03edaba20, 0x000001e03edac850, +0x000001e0817cb3b0, 0x000001e08194ada0, 0x000001e081ac71f0, 0x000001e086780720, +0x000001e086850800, 0x000001e08632e990, 0x000001e086398fc0, 0x000001e086ab7200, +0x000001e08193e930, 0x000001e0866aac10, 0x000001e08682dc20, 0x000001e08682c870, +0x000001e08682e2b0, 0x000001e08682e940, 0x000001e089d3cda0, 0x000001e089d3d430, +0x000001e089d40f40, 0x000001e089d3ee70, 0x000001e089d3dac0, 0x000001e089d3e150, +0x000001e089d408b0, 0x000001e089d436a0, 0x000001e089d422f0, 0x000001e089d415d0, +0x000001e08b994390, 0x000001e08b996af0, 0x000001e08b990f10, 0x000001e08b994a20, +0x000001e08b996460, 0x000001e08b9922c0, 0x000001e0890e2270, 0x000001e089d3e7e0, +0x000001e089d3fb90 +} + +Java Threads: ( => current thread ) + 0x000001e026423380 JavaThread "main" [_thread_blocked, id=31884, stack(0x000000967eb00000,0x000000967ec00000) (1024K)] + 0x000001e0264db2a0 JavaThread "Reference Handler" daemon [_thread_blocked, id=22560, stack(0x000000967ef00000,0x000000967f000000) (1024K)] + 0x000001e0264dcaa0 JavaThread "Finalizer" daemon [_thread_blocked, id=14220, stack(0x000000967f000000,0x000000967f100000) (1024K)] + 0x000001e03eda4fc0 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=32184, stack(0x000000967f100000,0x000000967f200000) (1024K)] +=>0x000001e03eda6d50 JavaThread "Attach Listener" daemon [_thread_in_vm, id=18716, stack(0x000000967f200000,0x000000967f300000) (1024K)] + 0x000001e03eda8c40 JavaThread "Service Thread" daemon [_thread_blocked, id=15552, stack(0x000000967f300000,0x000000967f400000) (1024K)] + 0x000001e03edaba20 JavaThread "Monitor Deflation Thread" daemon [_thread_blocked, id=36128, stack(0x000000967f400000,0x000000967f500000) (1024K)] + 0x000001e03edac850 JavaThread "C2 CompilerThread0" daemon [_thread_blocked, id=37496, stack(0x000000967f500000,0x000000967f600000) (1024K)] + 0x000001e0817cb3b0 JavaThread "C1 CompilerThread0" daemon [_thread_blocked, id=11064, stack(0x000000967f600000,0x000000967f700000) (1024K)] + 0x000001e08194ada0 JavaThread "Common-Cleaner" daemon [_thread_blocked, id=15304, stack(0x000000967f700000,0x000000967f800000) (1024K)] + 0x000001e081ac71f0 JavaThread "Notification Thread" daemon [_thread_blocked, id=22824, stack(0x000000967f800000,0x000000967f900000) (1024K)] + 0x000001e086780720 JavaThread "Active Thread: Equinox Container: 09546355-1349-4e2a-a90c-5f12bce13486" [_thread_blocked, id=4432, stack(0x0000009600000000,0x0000009600100000) (1024K)] + 0x000001e086850800 JavaThread "Refresh Thread: Equinox Container: 09546355-1349-4e2a-a90c-5f12bce13486" daemon [_thread_blocked, id=29540, stack(0x0000009600100000,0x0000009600200000) (1024K)] + 0x000001e08632e990 JavaThread "Framework Event Dispatcher: Equinox Container: 09546355-1349-4e2a-a90c-5f12bce13486" daemon [_thread_blocked, id=21196, stack(0x0000009600300000,0x0000009600400000) (1024K)] + 0x000001e086398fc0 JavaThread "Start Level: Equinox Container: 09546355-1349-4e2a-a90c-5f12bce13486" daemon [_thread_blocked, id=11556, stack(0x0000009600400000,0x0000009600500000) (1024K)] + 0x000001e086ab7200 JavaThread "Bundle File Closer" daemon [_thread_blocked, id=23556, stack(0x0000009600600000,0x0000009600700000) (1024K)] + 0x000001e08193e930 JavaThread "SCR Component Actor" daemon [_thread_blocked, id=36296, stack(0x0000009600500000,0x0000009600600000) (1024K)] + 0x000001e0866aac10 JavaThread "Worker-JM" [_thread_blocked, id=28216, stack(0x0000009600900000,0x0000009600a00000) (1024K)] + 0x000001e08682dc20 JavaThread "Java indexing" daemon [_thread_blocked, id=9584, stack(0x0000009600800000,0x0000009600900000) (1024K)] + 0x000001e08682c870 JavaThread "JNA Cleaner" daemon [_thread_blocked, id=9712, stack(0x0000009600c00000,0x0000009600d00000) (1024K)] + 0x000001e08682e2b0 JavaThread "Thread-1" daemon [_thread_in_native, id=37544, stack(0x0000009601200000,0x0000009601300000) (1024K)] + 0x000001e08682e940 JavaThread "Thread-2" daemon [_thread_in_native, id=15136, stack(0x0000009601300000,0x0000009601400000) (1024K)] + 0x000001e089d3cda0 JavaThread "Thread-3" daemon [_thread_in_native, id=35804, stack(0x0000009601400000,0x0000009601500000) (1024K)] + 0x000001e089d3d430 JavaThread "Thread-4" daemon [_thread_in_native, id=1916, stack(0x0000009601500000,0x0000009601600000) (1024K)] + 0x000001e089d40f40 JavaThread "Thread-5" daemon [_thread_in_native, id=12676, stack(0x0000009601600000,0x0000009601700000) (1024K)] + 0x000001e089d3ee70 JavaThread "Thread-6" daemon [_thread_in_native, id=33444, stack(0x0000009601700000,0x0000009601800000) (1024K)] + 0x000001e089d3dac0 JavaThread "Thread-7" daemon [_thread_in_native, id=20968, stack(0x0000009601800000,0x0000009601900000) (1024K)] + 0x000001e089d3e150 JavaThread "Thread-8" daemon [_thread_in_native, id=30404, stack(0x0000009601900000,0x0000009601a00000) (1024K)] + 0x000001e089d408b0 JavaThread "Thread-9" daemon [_thread_in_native, id=29108, stack(0x0000009601a00000,0x0000009601b00000) (1024K)] + 0x000001e089d436a0 JavaThread "pool-2-thread-1" [_thread_blocked, id=33900, stack(0x0000009601b00000,0x0000009601c00000) (1024K)] + 0x000001e089d422f0 JavaThread "WorkspaceEventsHandler" [_thread_blocked, id=31756, stack(0x0000009601c00000,0x0000009601d00000) (1024K)] + 0x000001e089d415d0 JavaThread "pool-1-thread-1" [_thread_blocked, id=34404, stack(0x0000009601d00000,0x0000009601e00000) (1024K)] + 0x000001e08b994390 JavaThread "Java Debug Server" daemon [_thread_in_native, id=27464, stack(0x0000009603c00000,0x0000009603d00000) (1024K)] + 0x000001e08b996af0 JavaThread "pool-6-thread-1" [_thread_in_native, id=4220, stack(0x0000009603d00000,0x0000009603e00000) (1024K)] + 0x000001e08b990f10 JavaThread "Cleaner-0" daemon [_thread_blocked, id=8688, stack(0x0000009603e00000,0x0000009603f00000) (1024K)] + 0x000001e08b994a20 JavaThread "RxSchedulerPurge-1" daemon [_thread_blocked, id=1796, stack(0x0000009603f00000,0x0000009604000000) (1024K)] + 0x000001e08b996460 JavaThread "RxCachedWorkerPoolEvictor-1" daemon [_thread_blocked, id=31216, stack(0x0000009604000000,0x0000009604100000) (1024K)] + 0x000001e08b9922c0 JavaThread "process reaper (pid 19908)" daemon [_thread_in_native, id=18600, stack(0x0000009603400000,0x0000009603420000) (128K)] + 0x000001e0890e2270 JavaThread "RxNewThreadScheduler-7" daemon [_thread_blocked, id=6264, stack(0x0000009602200000,0x0000009602300000) (1024K)] + 0x000001e089d3e7e0 JavaThread "Worker-51" [_thread_blocked, id=54756, stack(0x0000009600b00000,0x0000009600c00000) (1024K)] + 0x000001e089d3fb90 JavaThread "Worker-52" [_thread_blocked, id=54712, stack(0x0000009600700000,0x0000009600800000) (1024K)] +Total: 41 + +Other Threads: + 0x000001e03eda39b0 VMThread "VM Thread" [id=18576, stack(0x000000967ee00000,0x000000967ef00000) (1024K)] + 0x000001e03ecbca00 WatcherThread "VM Periodic Task Thread" [id=6380, stack(0x000000967ed00000,0x000000967ee00000) (1024K)] + 0x000001e026442740 WorkerThread "GC Thread#0" [id=33832, stack(0x000000967ec00000,0x000000967ed00000) (1024K)] + 0x000001e0866e0010 WorkerThread "GC Thread#1" [id=9748, stack(0x000000967fa00000,0x000000967fb00000) (1024K)] + 0x000001e0863f3c70 WorkerThread "GC Thread#2" [id=3352, stack(0x000000967fb00000,0x000000967fc00000) (1024K)] + 0x000001e08664aa30 WorkerThread "GC Thread#3" [id=16640, stack(0x000000967fc00000,0x000000967fd00000) (1024K)] + 0x000001e086646fb0 WorkerThread "GC Thread#4" [id=15128, stack(0x000000967fd00000,0x000000967fe00000) (1024K)] + 0x000001e086647350 WorkerThread "GC Thread#5" [id=3212, stack(0x000000967fe00000,0x000000967ff00000) (1024K)] + 0x000001e0866476f0 WorkerThread "GC Thread#6" [id=16504, stack(0x000000967ff00000,0x0000009680000000) (1024K)] + 0x000001e0860541d0 WorkerThread "GC Thread#7" [id=7704, stack(0x0000009600200000,0x0000009600300000) (1024K)] +Total: 10 + +Threads with active compile tasks: +Total: 0 + +VM state: not at safepoint (normal execution) + +VM Mutex/Monitor currently owned by a thread: None + +Heap address: 0x0000000080000000, size: 2048 MB, Compressed Oops mode: 32-bit + +CDS archive(s) mapped at: [0x000001e03f000000-0x000001e03fba0000-0x000001e03fba0000), size 12189696, SharedBaseAddress: 0x000001e03f000000, ArchiveRelocationMode: 1. +Compressed class space mapped at: 0x000001e040000000-0x000001e080000000, reserved size: 1073741824 +Narrow klass base: 0x000001e03f000000, Narrow klass shift: 0, Narrow klass range: 0x100000000 + +GC Precious Log: + CardTable entry size: 512 + CPUs: 8 total, 8 available + Memory: 7502M + Large Page Support: Disabled + NUMA Support: Disabled + Compressed Oops: Enabled (32-bit) + Alignments: Space 512K, Generation 512K, Heap 2M + Heap Min Capacity: 100M + Heap Initial Capacity: 100M + Heap Max Capacity: 2G + Pre-touch: Disabled + Parallel Workers: 8 + +Heap: + PSYoungGen total 4608K, used 770K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 14% used [0x00000000d5580000,0x00000000d5610868,0x00000000d5980000) + from space 512K, 37% used [0x00000000d5b00000,0x00000000d5b30000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1376200K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3ff22e0,0x00000000d4000000) + Metaspace used 94474K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K + +Card table byte_map: [0x000001e03a0f0000,0x000001e03a500000] _byte_map_base: 0x000001e039cf0000 + +Marking Bits: (ParMarkBitMap*) 0x00007ffd9bd02460 + Begin Bits: [0x000001e03a7b0000, 0x000001e03c7b0000) + End Bits: [0x000001e03c7b0000, 0x000001e03e7b0000) + +Polling page: 0x000001e02aee0000 + +Metaspace: + +Usage: + Non-class: 83.03 MB used. + Class: 9.23 MB used. + Both: 92.26 MB used. + +Virtual space: + Non-class space: 128.00 MB reserved, 83.81 MB ( 65%) committed, 2 nodes. + Class space: 1.00 GB reserved, 9.94 MB ( <1%) committed, 1 nodes. + Both: 1.12 GB reserved, 93.75 MB ( 8%) committed. + +Chunk freelists: + Non-Class: 11.44 MB + Class: 5.93 MB + Both: 17.37 MB + +MaxMetaspaceSize: unlimited +CompressedClassSpaceSize: 1.00 GB +Initial GC threshold: 21.00 MB +Current GC threshold: 155.12 MB +CDS: on + - commit_granule_bytes: 65536. + - commit_granule_words: 8192. + - virtual_space_node_default_size: 8388608. + - enlarge_chunks_in_place: 1. + - use_allocation_guard: 0. + + +Internal statistics: + +num_allocs_failed_limit: 11. +num_arena_births: 2034. +num_arena_deaths: 576. +num_vsnodes_births: 3. +num_vsnodes_deaths: 0. +num_space_committed: 1500. +num_space_uncommitted: 0. +num_chunks_returned_to_freelist: 690. +num_chunks_taken_from_freelist: 6950. +num_chunk_merges: 188. +num_chunk_splits: 3931. +num_chunks_enlarged: 2115. +num_inconsistent_stats: 0. + +CodeHeap 'non-profiled nmethods': size=120000Kb used=23507Kb max_used=24110Kb free=96493Kb + bounds [0x000001e0329d0000, 0x000001e0341a0000, 0x000001e039f00000] +CodeHeap 'profiled nmethods': size=120000Kb used=43778Kb max_used=53348Kb free=76221Kb + bounds [0x000001e02af00000, 0x000001e02e320000, 0x000001e032430000] +CodeHeap 'non-nmethods': size=5760Kb used=1538Kb max_used=1605Kb free=4221Kb + bounds [0x000001e032430000, 0x000001e0326a0000, 0x000001e0329d0000] +CodeCache: size=245760Kb, used=68823Kb, max_used=79063Kb, free=176935Kb + total_blobs=19676, nmethods=18811, adapters=765, full_count=0 +Compilation: enabled, stopped_count=0, restarted_count=0 + +Compilation events (20 events): +Event: 285475.382 Thread 0x000001e0817cb3b0 nmethod 28230 0x000001e02d9ad410 code [0x000001e02d9ae3e0, 0x000001e02d9b80f8] +Event: 285475.407 Thread 0x000001e03edac850 nmethod 28231 0x000001e032e0d810 code [0x000001e032e0d9a0, 0x000001e032e0da70] +Event: 285475.532 Thread 0x000001e0817cb3b0 28237 3 org.eclipse.m2e.core.internal.builder.MavenBuilderImpl::isApplicable (21 bytes) +Event: 285475.534 Thread 0x000001e0817cb3b0 nmethod 28237 0x000001e02c02fd90 code [0x000001e02c02ff40, 0x000001e02c0301d0] +Event: 285475.535 Thread 0x000001e0817cb3b0 28238 3 org.apache.maven.execution.DefaultMavenExecutionRequest::setStartTime (7 bytes) +Event: 285475.538 Thread 0x000001e0817cb3b0 nmethod 28238 0x000001e02b2df010 code [0x000001e02b2df1a0, 0x000001e02b2df2d0] +Event: 285475.538 Thread 0x000001e0817cb3b0 28241 ! 3 org.eclipse.m2e.core.internal.embedder.MavenExecutionContext::executeMojo (405 bytes) +Event: 285475.542 Thread 0x000001e03edac850 28245 4 com.google.inject.TypeLiteral::get (9 bytes) +Event: 285475.555 Thread 0x000001e03edac850 nmethod 28245 0x000001e032e2ea10 code [0x000001e032e2eba0, 0x000001e032e2eca8] +Event: 285475.584 Thread 0x000001e0817cb3b0 nmethod 28241 0x000001e02bc1e690 code [0x000001e02bc1ed20, 0x000001e02bc22648] +Event: 285475.584 Thread 0x000001e0817cb3b0 28239 3 org.eclipse.m2e.core.internal.embedder.MavenExecutionContext$$Lambda/0x000001e040656480::call (10 bytes) +Event: 285475.590 Thread 0x000001e0817cb3b0 nmethod 28239 0x000001e02b5a7910 code [0x000001e02b5a7b40, 0x000001e02b5a8290] +Event: 285686.133 Thread 0x000001e0817cb3b0 28246 3 com.sun.org.apache.xerces.internal.utils.XMLSecurityPropertyManager$Property::values (10 bytes) +Event: 285686.150 Thread 0x000001e0817cb3b0 nmethod 28246 0x000001e02b8df090 code [0x000001e02b8df240, 0x000001e02b8df4e8] +Event: 285686.152 Thread 0x000001e0817cb3b0 28247 3 com.sun.org.apache.xml.internal.serializer.ToStream::startElement (9 bytes) +Event: 285686.155 Thread 0x000001e0817cb3b0 nmethod 28247 0x000001e02b7cc010 code [0x000001e02b7cc1c0, 0x000001e02b7cc388] +Event: 285686.155 Thread 0x000001e0817cb3b0 28248 3 com.sun.org.apache.xml.internal.serializer.ToStream$BoolStack::popAndTop (31 bytes) +Event: 285686.158 Thread 0x000001e0817cb3b0 nmethod 28248 0x000001e02ba38990 code [0x000001e02ba38b40, 0x000001e02ba38cd0] +Event: 285686.158 Thread 0x000001e0817cb3b0 28249 ! 3 com.sun.org.apache.xml.internal.serializer.ToStream::endElement (294 bytes) +Event: 285686.174 Thread 0x000001e0817cb3b0 nmethod 28249 0x000001e02ba31690 code [0x000001e02ba31ac0, 0x000001e02ba33cd0] + +GC Heap History (20 events): +Event: 284810.683 GC heap before +{Heap before GC invocations=4473 (full 6): + PSYoungGen total 4608K, used 4383K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 99% used [0x00000000d5580000,0x00000000d597ffb0,0x00000000d5980000) + from space 512K, 56% used [0x00000000d5b00000,0x00000000d5b48000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1375744K, used 1375624K [0x0000000080000000, 0x00000000d3f80000, 0x00000000d5580000) + object space 1375744K, 99% used [0x0000000080000000,0x00000000d3f622a0,0x00000000d3f80000) + Metaspace used 94401K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 284810.886 GC heap after +{Heap after GC invocations=4473 (full 6): + PSYoungGen total 4608K, used 352K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 68% used [0x00000000d5b80000,0x00000000d5bd8020,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1375744K, used 1375664K [0x0000000080000000, 0x00000000d3f80000, 0x00000000d5580000) + object space 1375744K, 99% used [0x0000000080000000,0x00000000d3f6c2a0,0x00000000d3f80000) + Metaspace used 94401K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 284824.666 GC heap before +{Heap before GC invocations=4474 (full 6): + PSYoungGen total 4608K, used 4448K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 100% used [0x00000000d5580000,0x00000000d5980000,0x00000000d5980000) + from space 512K, 68% used [0x00000000d5b80000,0x00000000d5bd8020,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1375744K, used 1375664K [0x0000000080000000, 0x00000000d3f80000, 0x00000000d5580000) + object space 1375744K, 99% used [0x0000000080000000,0x00000000d3f6c2a0,0x00000000d3f80000) + Metaspace used 94405K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 284824.672 GC heap after +{Heap after GC invocations=4474 (full 6): + PSYoungGen total 4608K, used 352K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 68% used [0x00000000d5b00000,0x00000000d5b58020,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1375776K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3f882c0,0x00000000d4000000) + Metaspace used 94405K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 284839.311 GC heap before +{Heap before GC invocations=4475 (full 6): + PSYoungGen total 4608K, used 4448K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 100% used [0x00000000d5580000,0x00000000d5980000,0x00000000d5980000) + from space 512K, 68% used [0x00000000d5b00000,0x00000000d5b58020,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1375776K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3f882c0,0x00000000d4000000) + Metaspace used 94418K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 284839.319 GC heap after +{Heap after GC invocations=4475 (full 6): + PSYoungGen total 4608K, used 256K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 50% used [0x00000000d5b80000,0x00000000d5bc0000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1375880K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fa22e0,0x00000000d4000000) + Metaspace used 94418K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 284851.641 GC heap before +{Heap before GC invocations=4476 (full 6): + PSYoungGen total 4608K, used 4352K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 100% used [0x00000000d5580000,0x00000000d5980000,0x00000000d5980000) + from space 512K, 50% used [0x00000000d5b80000,0x00000000d5bc0000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1375880K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fa22e0,0x00000000d4000000) + Metaspace used 94419K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 284851.647 GC heap after +{Heap after GC invocations=4476 (full 6): + PSYoungGen total 4608K, used 192K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 37% used [0x00000000d5b00000,0x00000000d5b30000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1375952K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fb42e0,0x00000000d4000000) + Metaspace used 94419K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285110.322 GC heap before +{Heap before GC invocations=4477 (full 6): + PSYoungGen total 4608K, used 4288K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 100% used [0x00000000d5580000,0x00000000d5980000,0x00000000d5980000) + from space 512K, 37% used [0x00000000d5b00000,0x00000000d5b30000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1375952K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fb42e0,0x00000000d4000000) + Metaspace used 94419K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285110.412 GC heap after +{Heap after GC invocations=4477 (full 6): + PSYoungGen total 4608K, used 224K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 43% used [0x00000000d5b80000,0x00000000d5bb8000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1376016K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fc42e0,0x00000000d4000000) + Metaspace used 94419K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285386.970 GC heap before +{Heap before GC invocations=4478 (full 6): + PSYoungGen total 4608K, used 4320K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 100% used [0x00000000d5580000,0x00000000d5980000,0x00000000d5980000) + from space 512K, 43% used [0x00000000d5b80000,0x00000000d5bb8000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1376016K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fc42e0,0x00000000d4000000) + Metaspace used 94420K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285387.209 GC heap after +{Heap after GC invocations=4478 (full 6): + PSYoungGen total 4608K, used 256K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 50% used [0x00000000d5b00000,0x00000000d5b40000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1376056K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fce2e0,0x00000000d4000000) + Metaspace used 94420K, committed 95936K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285395.395 GC heap before +{Heap before GC invocations=4479 (full 6): + PSYoungGen total 4608K, used 4347K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 99% used [0x00000000d5580000,0x00000000d597eea8,0x00000000d5980000) + from space 512K, 50% used [0x00000000d5b00000,0x00000000d5b40000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1376056K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fce2e0,0x00000000d4000000) + Metaspace used 94429K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285395.403 GC heap after +{Heap after GC invocations=4479 (full 6): + PSYoungGen total 4608K, used 352K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 68% used [0x00000000d5b80000,0x00000000d5bd8000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1376104K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fda2e0,0x00000000d4000000) + Metaspace used 94429K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285429.251 GC heap before +{Heap before GC invocations=4480 (full 6): + PSYoungGen total 4608K, used 4448K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 100% used [0x00000000d5580000,0x00000000d5980000,0x00000000d5980000) + from space 512K, 68% used [0x00000000d5b80000,0x00000000d5bd8000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1376104K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fda2e0,0x00000000d4000000) + Metaspace used 94435K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285429.264 GC heap after +{Heap after GC invocations=4480 (full 6): + PSYoungGen total 4608K, used 320K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 62% used [0x00000000d5b00000,0x00000000d5b50000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1376128K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fe02e0,0x00000000d4000000) + Metaspace used 94435K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285475.460 GC heap before +{Heap before GC invocations=4481 (full 6): + PSYoungGen total 4608K, used 4416K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 100% used [0x00000000d5580000,0x00000000d5980000,0x00000000d5980000) + from space 512K, 62% used [0x00000000d5b00000,0x00000000d5b50000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1376128K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fe02e0,0x00000000d4000000) + Metaspace used 94455K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 285475.499 GC heap after +{Heap after GC invocations=4481 (full 6): + PSYoungGen total 4608K, used 320K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 62% used [0x00000000d5b80000,0x00000000d5bd0000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1376160K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fe82e0,0x00000000d4000000) + Metaspace used 94455K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 286660.365 GC heap before +{Heap before GC invocations=4482 (full 6): + PSYoungGen total 4608K, used 4415K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 99% used [0x00000000d5580000,0x00000000d597fff8,0x00000000d5980000) + from space 512K, 62% used [0x00000000d5b80000,0x00000000d5bd0000,0x00000000d5c00000) + to space 512K, 0% used [0x00000000d5b00000,0x00000000d5b00000,0x00000000d5b80000) + ParOldGen total 1376256K, used 1376160K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3fe82e0,0x00000000d4000000) + Metaspace used 94474K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} +Event: 286660.636 GC heap after +{Heap after GC invocations=4482 (full 6): + PSYoungGen total 4608K, used 192K [0x00000000d5580000, 0x00000000d5c00000, 0x0000000100000000) + eden space 4096K, 0% used [0x00000000d5580000,0x00000000d5580000,0x00000000d5980000) + from space 512K, 37% used [0x00000000d5b00000,0x00000000d5b30000,0x00000000d5b80000) + to space 512K, 0% used [0x00000000d5b80000,0x00000000d5b80000,0x00000000d5c00000) + ParOldGen total 1376256K, used 1376200K [0x0000000080000000, 0x00000000d4000000, 0x00000000d5580000) + object space 1376256K, 99% used [0x0000000080000000,0x00000000d3ff22e0,0x00000000d4000000) + Metaspace used 94474K, committed 96000K, reserved 1179648K + class space used 9453K, committed 10176K, reserved 1048576K +} + +Dll operation events (14 events): +Event: 0.374 Loaded shared library c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\java.dll +Event: 0.602 Loaded shared library c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\zip.dll +Event: 0.633 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\instrument.dll +Event: 0.721 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\net.dll +Event: 0.821 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\nio.dll +Event: 0.827 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\zip.dll +Event: 0.857 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\jimage.dll +Event: 1.118 Loaded shared library c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\verify.dll +Event: 12.403 Loaded shared library C:\Users\Ajith\AppData\Roaming\Antigravity\User\globalStorage\redhat.java\1.50.0\config_win\org.eclipse.equinox.launcher\org.eclipse.equinox.launcher.win32.win32.x86_64_1.2.1400.v20250801-0854\eclipse_11916.dll +Event: 26.666 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\management.dll +Event: 26.668 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\management_ext.dll +Event: 28.196 Loaded shared library C:\Users\Ajith\AppData\Local\Temp\jna-63291316\jna59115804151515689.dll +Event: 29.011 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\sunmscapi.dll +Event: 29.220 Loaded shared library C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\extnet.dll + +Deoptimization events (20 events): +Event: 282291.100 Thread 0x000001e08b997ea0 DEOPT PACKING pc=0x000001e033296e68 sp=0x0000009600dfec80 +Event: 282291.100 Thread 0x000001e08b997ea0 DEOPT UNPACKING pc=0x000001e032483aa2 sp=0x0000009600dfec00 mode 2 +Event: 282308.708 Thread 0x000001e08b997ea0 DEOPT PACKING pc=0x000001e02be1fd59 sp=0x0000009600dfeae0 +Event: 282308.739 Thread 0x000001e08b997ea0 DEOPT UNPACKING pc=0x000001e032484242 sp=0x0000009600dfe018 mode 0 +Event: 282309.413 Thread 0x000001e08b997ea0 Uncommon trap: trap_request=0xffffffd6 fr.pc=0x000001e033a7d3a8 relative=0x00000000000016c8 +Event: 282309.413 Thread 0x000001e08b997ea0 Uncommon trap: reason=array_check action=maybe_recompile pc=0x000001e033a7d3a8 method=java.util.TimSort.mergeHi(IIII)V @ 419 c2 +Event: 282309.413 Thread 0x000001e08b997ea0 DEOPT PACKING pc=0x000001e033a7d3a8 sp=0x0000009600dfdc40 +Event: 282309.413 Thread 0x000001e08b997ea0 DEOPT UNPACKING pc=0x000001e032483aa2 sp=0x0000009600dfdc28 mode 2 +Event: 282309.419 Thread 0x000001e08b997ea0 Uncommon trap: trap_request=0xffffffd6 fr.pc=0x000001e033a7d3a8 relative=0x00000000000016c8 +Event: 282309.419 Thread 0x000001e08b997ea0 Uncommon trap: reason=array_check action=maybe_recompile pc=0x000001e033a7d3a8 method=java.util.TimSort.mergeHi(IIII)V @ 419 c2 +Event: 282309.419 Thread 0x000001e08b997ea0 DEOPT PACKING pc=0x000001e033a7d3a8 sp=0x0000009600dfd890 +Event: 282309.419 Thread 0x000001e08b997ea0 DEOPT UNPACKING pc=0x000001e032483aa2 sp=0x0000009600dfd878 mode 2 +Event: 282450.867 Thread 0x000001e08b993670 Uncommon trap: trap_request=0xffffff45 fr.pc=0x000001e033b5e680 relative=0x00000000000012a0 +Event: 282450.870 Thread 0x000001e08b993670 Uncommon trap: reason=unstable_if action=reinterpret pc=0x000001e033b5e680 method=org.eclipse.core.internal.dtree.AbstractDataTreeNode.assembleWith([Lorg/eclipse/core/internal/dtree/AbstractDataTreeNode;[Lorg/eclipse/core/internal/dtree/AbstractDataTreeNo +Event: 282450.872 Thread 0x000001e08b993670 DEOPT PACKING pc=0x000001e033b5e680 sp=0x0000009600bfecf0 +Event: 282450.875 Thread 0x000001e08b993670 DEOPT UNPACKING pc=0x000001e032483aa2 sp=0x0000009600bfecd0 mode 2 +Event: 285395.304 Thread 0x000001e089d3e7e0 Uncommon trap: trap_request=0xfffffff4 fr.pc=0x000001e034188c34 relative=0x0000000000006634 +Event: 285395.306 Thread 0x000001e089d3e7e0 Uncommon trap: reason=null_check action=make_not_entrant pc=0x000001e034188c34 method=org.eclipse.sisu.plexus.CompositeBeanHelper.setProperty(Ljava/lang/Object;Ljava/lang/String;Ljava/lang/Class;Lorg/codehaus/plexus/configuration/PlexusConfiguration;)V @ +Event: 285395.306 Thread 0x000001e089d3e7e0 DEOPT PACKING pc=0x000001e034188c34 sp=0x0000009600bfd0a0 +Event: 285395.308 Thread 0x000001e089d3e7e0 DEOPT UNPACKING pc=0x000001e032483aa2 sp=0x0000009600bfd0b8 mode 2 + +Classes loaded (20 events): +Event: 249.687 Loading class org/xml/sax/SAXNotRecognizedException +Event: 249.688 Loading class org/xml/sax/SAXNotRecognizedException done +Event: 249.688 Loading class org/xml/sax/SAXNotSupportedException +Event: 249.688 Loading class org/xml/sax/SAXNotSupportedException done +Event: 249.691 Loading class com/sun/org/apache/xerces/internal/util/URI +Event: 249.693 Loading class com/sun/org/apache/xerces/internal/util/URI done +Event: 249.696 Loading class com/sun/org/apache/xerces/internal/xni/XNIException +Event: 249.697 Loading class com/sun/org/apache/xerces/internal/xni/XNIException done +Event: 249.697 Loading class com/sun/org/apache/xerces/internal/xni/parser/XMLParseException +Event: 249.698 Loading class com/sun/org/apache/xerces/internal/xni/parser/XMLParseException done +Event: 352.635 Loading class java/util/stream/ReduceOps$5 +Event: 352.635 Loading class java/util/stream/ReduceOps$5 done +Event: 352.635 Loading class java/util/stream/ReduceOps$CountingSink$OfRef +Event: 352.635 Loading class java/util/stream/ReduceOps$CountingSink +Event: 352.635 Loading class java/util/stream/ReduceOps$CountingSink done +Event: 352.635 Loading class java/util/stream/ReduceOps$CountingSink$OfRef done +Event: 352.945 Loading class java/nio/BufferMismatch +Event: 352.946 Loading class java/nio/BufferMismatch done +Event: 13352.186 Loading class java/nio/channels/CompletionHandler +Event: 13352.240 Loading class java/nio/channels/CompletionHandler done + +Classes unloaded (20 events): +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e040017400 'java/lang/invoke/LambdaForm$MH+0x000001e040017400' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e040018800 'java/lang/invoke/LambdaForm$MH+0x000001e040018800' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e040019400 'java/lang/invoke/LambdaForm$MH+0x000001e040019400' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e040080800 'java/lang/invoke/LambdaForm$MH+0x000001e040080800' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e040082400 'java/lang/invoke/LambdaForm$MH+0x000001e040082400' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e0401a7c00 'java/lang/invoke/LambdaForm$MH+0x000001e0401a7c00' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e0408a5800 'java/lang/invoke/LambdaForm$MH+0x000001e0408a5800' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e0408a9000 'java/lang/invoke/LambdaForm$MH+0x000001e0408a9000' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e0408aa400 'java/lang/invoke/LambdaForm$MH+0x000001e0408aa400' +Event: 280059.274 Thread 0x000001e03eda39b0 Unloading class 0x000001e040950800 'java/lang/invoke/LambdaForm$BMH+0x000001e040950800' +Event: 280059.275 Thread 0x000001e03eda39b0 Unloading class 0x000001e0409f0c00 'java/lang/invoke/LambdaForm$MH+0x000001e0409f0c00' +Event: 280059.275 Thread 0x000001e03eda39b0 Unloading class 0x000001e0409e4c00 'java/lang/invoke/LambdaForm$MH+0x000001e0409e4c00' +Event: 280059.275 Thread 0x000001e03eda39b0 Unloading class 0x000001e040600400 'java/lang/invoke/LambdaForm$MH+0x000001e040600400' +Event: 280059.275 Thread 0x000001e03eda39b0 Unloading class 0x000001e0401a7400 'java/lang/invoke/LambdaForm$MH+0x000001e0401a7400' +Event: 280059.275 Thread 0x000001e03eda39b0 Unloading class 0x000001e040175800 'java/lang/invoke/LambdaForm$MH+0x000001e040175800' +Event: 280059.276 Thread 0x000001e03eda39b0 Unloading class 0x000001e04001f800 'java/lang/invoke/LambdaForm$MH+0x000001e04001f800' +Event: 280059.276 Thread 0x000001e03eda39b0 Unloading class 0x000001e04001e800 'java/lang/invoke/LambdaForm$MH+0x000001e04001e800' +Event: 280059.276 Thread 0x000001e03eda39b0 Unloading class 0x000001e04001e400 'java/lang/invoke/LambdaForm$MH+0x000001e04001e400' +Event: 280059.276 Thread 0x000001e03eda39b0 Unloading class 0x000001e04001dc00 'java/lang/invoke/LambdaForm$MH+0x000001e04001dc00' +Event: 280059.276 Thread 0x000001e03eda39b0 Unloading class 0x000001e04001d400 'java/lang/invoke/LambdaForm$MH+0x000001e04001d400' + +Classes redefined (0 events): +No events + +Internal exceptions (20 events): +Event: 282266.835 Thread 0x000001e08682dc20 Exception (0x00000000d57a9918) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 282282.445 Thread 0x000001e08682dc20 Exception (0x00000000d572eb10) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 282282.976 Thread 0x000001e08682dc20 Exception (0x00000000d5595668) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 282450.197 Thread 0x000001e08b993670 Exception (0x00000000d582af08) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 282450.208 Thread 0x000001e08b993670 Exception (0x00000000d582ba10) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 282897.791 Thread 0x000001e08b992950 Exception (0x00000000d59016c0) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 282897.795 Thread 0x000001e08b992950 Exception (0x00000000d5901f88) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 283273.474 Thread 0x000001e089d3f500 Exception (0x00000000d58d2eb8) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 283273.475 Thread 0x000001e089d3f500 Exception (0x00000000d58d3780) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 283731.583 Thread 0x000001e08b993670 Exception (0x00000000d5795c88) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 283731.592 Thread 0x000001e08b993670 Exception (0x00000000d5796550) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 284059.945 Thread 0x000001e089d43010 Exception (0x00000000d56d8570) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 284059.947 Thread 0x000001e089d43010 Exception (0x00000000d56d9088) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 284787.925 Thread 0x000001e089d3f500 Exception (0x00000000d5663300) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 284787.929 Thread 0x000001e089d3f500 Exception (0x00000000d5663bc8) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 285110.263 Thread 0x000001e089d3fb90 Exception (0x00000000d595e3c0) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 285110.266 Thread 0x000001e089d3fb90 Exception (0x00000000d595ec88) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 285395.303 Thread 0x000001e089d3e7e0 Implicit null exception at 0x000001e0341844e8 to 0x000001e034188bf4 +Event: 285686.087 Thread 0x000001e089d3fb90 Exception (0x00000000d5810c20) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] +Event: 285686.088 Thread 0x000001e089d3fb90 Exception (0x00000000d58114e8) +thrown [s\src\hotspot\share\prims\jni.cpp, line 520] + +ZGC Phase Switch (0 events): +No events + +VM Operations (20 events): +Event: 285395.395 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) +Event: 285395.403 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) done +Event: 285429.251 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) +Event: 285429.264 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) done +Event: 285475.459 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) +Event: 285475.499 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) done +Event: 285744.709 Executing VM operation: HandshakeAllThreads (HandshakeForDeflation) +Event: 285744.711 Executing VM operation: HandshakeAllThreads (HandshakeForDeflation) done +Event: 285744.711 Executing VM operation: RendezvousGCThreads +Event: 285744.711 Executing VM operation: RendezvousGCThreads done +Event: 286225.501 Executing VM operation: HandshakeAllThreads (HandshakeForDeflation) +Event: 286225.504 Executing VM operation: HandshakeAllThreads (HandshakeForDeflation) done +Event: 286225.504 Executing VM operation: RendezvousGCThreads +Event: 286225.504 Executing VM operation: RendezvousGCThreads done +Event: 286660.357 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) +Event: 286660.636 Executing VM operation: ParallelGCFailedAllocation (Allocation Failure) done +Event: 287127.499 Executing VM operation: HandshakeAllThreads (HandshakeForDeflation) +Event: 287127.584 Executing VM operation: HandshakeAllThreads (HandshakeForDeflation) done +Event: 287127.584 Executing VM operation: RendezvousGCThreads +Event: 287127.584 Executing VM operation: RendezvousGCThreads done + +Memory protections (0 events): +No events + +Nmethod flushes (20 events): +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dc61290 +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dc7d690 +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dcb1490 +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dcb1a90 +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dd1bf90 +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dd1c390 +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dd23c90 +Event: 280062.770 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02ddff010 +Event: 280062.771 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02de13b90 +Event: 280062.771 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02de14610 +Event: 280062.771 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02de28890 +Event: 280062.772 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02de2a010 +Event: 280062.772 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02df7b410 +Event: 280062.774 Thread 0x000001e03eda39b0 flushing osr nmethod 0x000001e02df7d690 +Event: 280062.774 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02df85990 +Event: 280062.775 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02df90290 +Event: 280062.775 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02df97810 +Event: 280062.775 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02dfae190 +Event: 280062.776 Thread 0x000001e03eda39b0 flushing osr nmethod 0x000001e02dfd2590 +Event: 280062.776 Thread 0x000001e03eda39b0 flushing nmethod 0x000001e02e116c90 + +Events (20 events): +Event: 284489.846 Thread 0x000001e089d43010 Thread added: 0x000001e089d3f500 +Event: 284549.861 Thread 0x000001e08b993670 Thread exited: 0x000001e08b993670 +Event: 284787.841 Thread 0x000001e089d3f500 Thread added: 0x000001e089d3e7e0 +Event: 284787.948 Thread 0x000001e089d3f500 Thread added: 0x000001e089d3fb90 +Event: 284787.959 Thread 0x000001e089d3fb90 Thread exited: 0x000001e089d3fb90 +Event: 284788.032 Thread 0x000001e089d3f500 Thread added: 0x000001e089d3c710 +Event: 284788.033 Thread 0x000001e089d3c710 Thread exited: 0x000001e089d3c710 +Event: 284810.236 Thread 0x000001e089d43010 Thread exited: 0x000001e089d43010 +Event: 284811.953 Thread 0x000001e089d3f500 Thread added: 0x000001e089d3fb90 +Event: 284911.623 Thread 0x000001e089d3f500 Thread exited: 0x000001e089d3f500 +Event: 285110.277 Thread 0x000001e089d3fb90 Thread added: 0x000001e089d3f500 +Event: 285110.281 Thread 0x000001e089d3f500 Thread exited: 0x000001e089d3f500 +Event: 285110.438 Thread 0x000001e089d3fb90 Thread added: 0x000001e089d43010 +Event: 285110.438 Thread 0x000001e089d43010 Thread exited: 0x000001e089d43010 +Event: 285110.561 Thread 0x000001e089d3fb90 Thread added: 0x000001e089d40220 +Event: 285170.574 Thread 0x000001e089d40220 Thread exited: 0x000001e089d40220 +Event: 285686.097 Thread 0x000001e089d3fb90 Thread added: 0x000001e089d3f500 +Event: 285686.101 Thread 0x000001e089d3f500 Thread exited: 0x000001e089d3f500 +Event: 285686.153 Thread 0x000001e089d3fb90 Thread added: 0x000001e089d40220 +Event: 285686.153 Thread 0x000001e089d40220 Thread exited: 0x000001e089d40220 + + +Dynamic libraries: +0x00007ff7b6270000 - 0x00007ff7b627e000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\java.exe +0x00007ffe2f0d0000 - 0x00007ffe2f2e8000 C:\windows\SYSTEM32\ntdll.dll +0x00007ffe2e0f0000 - 0x00007ffe2e1b4000 C:\windows\System32\KERNEL32.DLL +0x00007ffe2c460000 - 0x00007ffe2c833000 C:\windows\System32\KERNELBASE.dll +0x00007ffe2cc60000 - 0x00007ffe2cd71000 C:\windows\System32\ucrtbase.dll +0x00007ffe18110000 - 0x00007ffe18128000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\jli.dll +0x00007ffe2d210000 - 0x00007ffe2d3c2000 C:\windows\System32\USER32.dll +0x00007ffe2c8c0000 - 0x00007ffe2c8e6000 C:\windows\System32\win32u.dll +0x00007ffe2ee00000 - 0x00007ffe2ee29000 C:\windows\System32\GDI32.dll +0x00007ffe2c220000 - 0x00007ffe2c33b000 C:\windows\System32\gdi32full.dll +0x00007ffe2c3c0000 - 0x00007ffe2c45a000 C:\windows\System32\msvcp_win.dll +0x00007ffe25770000 - 0x00007ffe2578e000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\VCRUNTIME140.dll +0x00007ffe12620000 - 0x00007ffe128bc000 C:\windows\WinSxS\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.22621.6060_none_2712eda17382d24b\COMCTL32.dll +0x00007ffe2efe0000 - 0x00007ffe2f087000 C:\windows\System32\msvcrt.dll +0x00007ffe2e0a0000 - 0x00007ffe2e0d1000 C:\windows\System32\IMM32.DLL +0x00007ffe258a0000 - 0x00007ffe258ac000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\vcruntime140_1.dll +0x00007ffe0bbc0000 - 0x00007ffe0bc4d000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\msvcp140.dll +0x00007ffd9b040000 - 0x00007ffd9bde0000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\server\jvm.dll +0x00007ffe2ec00000 - 0x00007ffe2ecb1000 C:\windows\System32\ADVAPI32.dll +0x00007ffe2e7b0000 - 0x00007ffe2e858000 C:\windows\System32\sechost.dll +0x00007ffe2c1f0000 - 0x00007ffe2c218000 C:\windows\System32\bcrypt.dll +0x00007ffe2ecc0000 - 0x00007ffe2edd8000 C:\windows\System32\RPCRT4.dll +0x00007ffe2eea0000 - 0x00007ffe2ef11000 C:\windows\System32\WS2_32.dll +0x00007ffe2bf10000 - 0x00007ffe2bf5d000 C:\windows\SYSTEM32\POWRPROF.dll +0x00007ffe27b70000 - 0x00007ffe27ba4000 C:\windows\SYSTEM32\WINMM.dll +0x00007ffe22db0000 - 0x00007ffe22dba000 C:\windows\SYSTEM32\VERSION.dll +0x00007ffe2bef0000 - 0x00007ffe2bf03000 C:\windows\SYSTEM32\UMPDC.dll +0x00007ffe2b1d0000 - 0x00007ffe2b1e8000 C:\windows\SYSTEM32\kernel.appcore.dll +0x00007ffe17f80000 - 0x00007ffe17f8a000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\jimage.dll +0x00007ffe242e0000 - 0x00007ffe24513000 C:\windows\SYSTEM32\DBGHELP.DLL +0x00007ffe2e860000 - 0x00007ffe2ebf1000 C:\windows\System32\combase.dll +0x00007ffe2d3d0000 - 0x00007ffe2d4a8000 C:\windows\System32\OLEAUT32.dll +0x00007ffe13910000 - 0x00007ffe13942000 C:\windows\SYSTEM32\dbgcore.DLL +0x00007ffe2c340000 - 0x00007ffe2c3bb000 C:\windows\System32\bcryptPrimitives.dll +0x00007ffe180f0000 - 0x00007ffe180ff000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\instrument.dll +0x00007ffe17fb0000 - 0x00007ffe17fd0000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\java.dll +0x00007ffe2d4b0000 - 0x00007ffe2dd4c000 C:\windows\System32\SHELL32.dll +0x00007ffe2c8f0000 - 0x00007ffe2ca2f000 C:\windows\System32\wintypes.dll +0x00007ffe2a0b0000 - 0x00007ffe2a9ca000 C:\windows\SYSTEM32\windows.storage.dll +0x00007ffe2dd50000 - 0x00007ffe2de54000 C:\windows\System32\SHCORE.dll +0x00007ffe2ee30000 - 0x00007ffe2ee99000 C:\windows\System32\shlwapi.dll +0x00007ffe2c120000 - 0x00007ffe2c145000 C:\windows\SYSTEM32\profapi.dll +0x00007ffe121d0000 - 0x00007ffe121e8000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\zip.dll +0x00007ffe180e0000 - 0x00007ffe180f0000 C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\net.dll +0x00007ffe28ef0000 - 0x00007ffe2901c000 C:\windows\SYSTEM32\WINHTTP.dll +0x00007ffe2b6b0000 - 0x00007ffe2b719000 C:\windows\system32\mswsock.dll +0x00007ffe0d950000 - 0x00007ffe0d966000 C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\nio.dll +0x00007ffe16990000 - 0x00007ffe169a0000 c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\verify.dll +0x00007ffe0d470000 - 0x00007ffe0d4b4000 C:\Users\Ajith\AppData\Roaming\Antigravity\User\globalStorage\redhat.java\1.50.0\config_win\org.eclipse.equinox.launcher\org.eclipse.equinox.launcher.win32.win32.x86_64_1.2.1400.v20250801-0854\eclipse_11916.dll +0x00007ffe2df00000 - 0x00007ffe2e0a0000 C:\windows\System32\ole32.dll +0x00007ffe25870000 - 0x00007ffe2587a000 C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\management.dll +0x00007ffe25860000 - 0x00007ffe2586c000 C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\management_ext.dll +0x00007ffe2de60000 - 0x00007ffe2de68000 C:\windows\System32\PSAPI.DLL +0x00007ffe2b900000 - 0x00007ffe2b91b000 C:\windows\SYSTEM32\CRYPTSP.dll +0x00007ffe2b130000 - 0x00007ffe2b167000 C:\windows\system32\rsaenh.dll +0x00007ffe2b7a0000 - 0x00007ffe2b7c8000 C:\windows\SYSTEM32\USERENV.dll +0x00007ffe2b920000 - 0x00007ffe2b92c000 C:\windows\SYSTEM32\CRYPTBASE.dll +0x00007ffe2ac20000 - 0x00007ffe2ac4d000 C:\windows\SYSTEM32\IPHLPAPI.DLL +0x00007ffe2efd0000 - 0x00007ffe2efd9000 C:\windows\System32\NSI.dll +0x00007ffe0b870000 - 0x00007ffe0b8b9000 C:\Users\Ajith\AppData\Local\Temp\jna-63291316\jna59115804151515689.dll +0x00007ffe27fa0000 - 0x00007ffe27fb9000 C:\windows\SYSTEM32\dhcpcsvc6.DLL +0x00007ffe27f80000 - 0x00007ffe27f9f000 C:\windows\SYSTEM32\dhcpcsvc.DLL +0x00007ffe17fa0000 - 0x00007ffe17fae000 C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\sunmscapi.dll +0x00007ffe2ca30000 - 0x00007ffe2cb98000 C:\windows\System32\CRYPT32.dll +0x00007ffe2bb30000 - 0x00007ffe2bb5e000 C:\windows\SYSTEM32\ncrypt.dll +0x00007ffe2baf0000 - 0x00007ffe2bb27000 C:\windows\SYSTEM32\NTASN1.dll +0x00007ffe2ac50000 - 0x00007ffe2ad48000 C:\windows\SYSTEM32\DNSAPI.dll +0x00007ffe27da0000 - 0x00007ffe27daa000 C:\Windows\System32\rasadhlp.dll +0x00007ffe27a60000 - 0x00007ffe27ae4000 C:\windows\System32\fwpuclnt.dll +0x00007ffe17f90000 - 0x00007ffe17f99000 C:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\extnet.dll +0x00007ffe2b2e0000 - 0x00007ffe2b314000 C:\windows\SYSTEM32\ntmarta.dll + +JVMTI agents: +c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\lombok\lombok-1.18.39-4050.jar path:c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\instrument.dll, loaded, initialized, instrumentlib options:none + +dbghelp: loaded successfully - version: 4.0.5 - missing functions: none +symbol engine: initialized successfully - sym options: 0x614 - pdb path: .;c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin;C:\windows\SYSTEM32;C:\windows\WinSxS\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.22621.6060_none_2712eda17382d24b;c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\jre\21.0.9-win32-x86_64\bin\server;C:\Users\Ajith\AppData\Roaming\Antigravity\User\globalStorage\redhat.java\1.50.0\config_win\org.eclipse.equinox.launcher\org.eclipse.equinox.launcher.win32.win32.x86_64_1.2.1400.v20250801-0854;C:\Users\Ajith\AppData\Local\Temp\jna-63291316 + +VM Arguments: +jvm_args: --add-modules=ALL-SYSTEM --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/sun.nio.fs=ALL-UNNAMED -Declipse.application=org.eclipse.jdt.ls.core.id1 -Dosgi.bundles.defaultStartLevel=4 -Declipse.product=org.eclipse.jdt.ls.core.product -Djava.import.generatesMetadataFilesAtProjectRoot=false -DDetectVMInstallationsJob.disabled=true -Dfile.encoding=utf8 -XX:+UseParallelGC -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -Dsun.zip.disableMemoryMapping=true -Xmx2G -Xms100m -Xlog:disable -javaagent:c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\lombok\lombok-1.18.39-4050.jar -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=c:\Users\Ajith\AppData\Roaming\Antigravity\User\workspaceStorage\a973566b49b2f02afff9ce8c986b3b69\redhat.java -Daether.dependencyCollector.impl=bf +java_command: c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\server\plugins\org.eclipse.equinox.launcher_1.7.100.v20251111-0406.jar -configuration c:\Users\Ajith\AppData\Roaming\Antigravity\User\globalStorage\redhat.java\1.50.0\config_win -data c:\Users\Ajith\AppData\Roaming\Antigravity\User\workspaceStorage\a973566b49b2f02afff9ce8c986b3b69\redhat.java\jdt_ws --pipe=\\.\pipe\lsp-89eacfa0f44d6960932ad0e50fc86c6c-sock +java_class_path (initial): c:\Users\Ajith\.antigravity\extensions\redhat.java-1.50.0-win32-x64\server\plugins\org.eclipse.equinox.launcher_1.7.100.v20251111-0406.jar +Launcher Type: SUN_STANDARD + +[Global flags] + uintx AdaptiveSizePolicyWeight = 90 {product} {command line} + intx CICompilerCount = 4 {product} {ergonomic} + uintx GCTimeRatio = 4 {product} {command line} + bool HeapDumpOnOutOfMemoryError = true {manageable} {command line} + ccstr HeapDumpPath = c:\Users\Ajith\AppData\Roaming\Antigravity\User\workspaceStorage\a973566b49b2f02afff9ce8c986b3b69\redhat.java {manageable} {command line} + size_t InitialHeapSize = 104857600 {product} {command line} + size_t MaxHeapSize = 2147483648 {product} {command line} + size_t MaxNewSize = 715653120 {product} {ergonomic} + size_t MinHeapDeltaBytes = 524288 {product} {ergonomic} + size_t MinHeapSize = 104857600 {product} {command line} + size_t NewSize = 34603008 {product} {ergonomic} + uintx NonNMethodCodeHeapSize = 5839372 {pd product} {ergonomic} + uintx NonProfiledCodeHeapSize = 122909434 {pd product} {ergonomic} + size_t OldSize = 70254592 {product} {ergonomic} + uintx ProfiledCodeHeapSize = 122909434 {pd product} {ergonomic} + uintx ReservedCodeCacheSize = 251658240 {pd product} {ergonomic} + bool SegmentedCodeCache = true {product} {ergonomic} + size_t SoftMaxHeapSize = 2147483648 {manageable} {ergonomic} + bool UseCompressedOops = true {product lp64_product} {ergonomic} + bool UseLargePagesIndividualAllocation = false {pd product} {ergonomic} + bool UseParallelGC = true {product} {command line} + +Logging: +Log output configuration: + #0: stdout all=off uptime,level,tags foldmultilines=false + #1: stderr all=off uptime,level,tags foldmultilines=false + +Release file: +JAVA_VERSION="21.0.9" +MODULES="java.base java.compiler java.datatransfer java.xml java.prefs java.desktop java.instrument java.logging java.management java.security.sasl java.naming java.rmi java.management.rmi java.net.http java.scripting java.security.jgss java.transaction.xa java.sql java.sql.rowset java.xml.crypto java.se java.smartcardio jdk.accessibility jdk.internal.jvmstat jdk.attach jdk.charsets jdk.internal.opt jdk.zipfs jdk.compiler jdk.crypto.ec jdk.crypto.cryptoki jdk.crypto.mscapi jdk.dynalink jdk.internal.ed jdk.editpad jdk.hotspot.agent jdk.httpserver jdk.internal.le jdk.internal.vm.ci jdk.internal.vm.compiler jdk.internal.vm.compiler.management jdk.jartool jdk.javadoc jdk.jcmd jdk.management jdk.management.agent jdk.jconsole jdk.jdeps jdk.jdwp.agent jdk.jdi jdk.jfr jdk.jshell jdk.jsobject jdk.jstatd jdk.localedata jdk.management.jfr jdk.naming.dns jdk.naming.rmi jdk.net jdk.nio.mapmode jdk.random jdk.sctp jdk.security.auth jdk.security.jgss jdk.unsupported jdk.unsupported.desktop jdk.xml.dom" + +Environment Variables: +PATH=C:\Program Files\Common Files\Oracle\Java\javapath;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:\windows\System32\WindowsPowerShell\v1.0\;C:\windows\System32\OpenSSH\;C:\Program Files\Docker\Docker\resources\bin;C:\Program Files\Java\jdk-17\bin;C:\Program Files\nodejs\;C:\Program Files (x86)\Microsoft SQL Server\160\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\160\Tools\Binn\;C:\Program Files\Microsoft SQL Server\160\Tools\Binn\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files\Microsoft SQL Server\160\DTS\Binn\;C:\Program Files\Apache\Maven\apache-maven-3.9.11\bin;C:\Users\Ajith\AppData\Local\Programs\Python\Python313\Scripts\;C:\Users\Ajith\AppData\Local\Programs\Python\Python313\;C:\Users\Ajith\AppData\Local\Programs\Python\Python312\Scripts\;C:\Users\Ajith\AppData\Local\Programs\Python\Python312\;C:\Users\Ajith\AppData\Local\Programs\Python\Launcher\;C:\Users\Ajith\AppData\Local\Microsoft\WindowsApps;C:\Users\Ajith\AppData\Local\Programs\Git\cmd;C:\Users\Ajith\Desktop;C:\Users\Ajith\Desktop\demo\terraform;C:\Users\Ajith\AppData\Roaming\npm;C:\Users\Ajith\AppData\Local\GitHubDesktop\bin;C:\Users\Ajith\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\Ajith\AppData\Local\Programs\Antigravity\bin +USERNAME=Ajith +OS=Windows_NT +PROCESSOR_IDENTIFIER=AMD64 Family 23 Model 104 Stepping 1, AuthenticAMD +TMP=C:\Users\Ajith\AppData\Local\Temp +TEMP=C:\Users\Ajith\AppData\Local\Temp + + + + +Periodic native trim disabled + +--------------- S Y S T E M --------------- + +OS: + Windows 11 , 64 bit Build 22621 (10.0.22621.5415) +OS uptime: 19 days 1:06 hours +Hyper-V role detected + +CPU: total 8 (initial active 8) (8 cores per cpu, 2 threads per core) family 23 model 104 stepping 1 microcode 0x0, cx8, cmov, fxsr, ht, mmx, 3dnowpref, sse, sse2, sse3, ssse3, sse4a, sse4.1, sse4.2, popcnt, lzcnt, tsc, tscinvbit, avx, avx2, aes, clmul, bmi1, bmi2, adx, sha, fma, vzeroupper, clflush, clflushopt, hv, rdtscp, rdpid, f16c +Processor Information for the first 8 processors : + Max Mhz: 2600, Current Mhz: 2600, Mhz Limit: 2600 + +Memory: 4k page, system-wide physical 7502M (338M free) +TotalPageFile size 30030M (AvailPageFile size 586M) +current process WorkingSet (physical memory assigned to process): 10M, peak: 947M +current process commit charge ("private bytes"): 1741M, peak: 1778M + +vm_info: OpenJDK 64-Bit Server VM (21.0.9+10-LTS) for windows-amd64 JRE (21.0.9+10-LTS), built on 2025-10-21T00:00:00Z by "admin" with unknown MS VC++:1942 + +END. diff --git a/src/main/java/com/gcc/commissionerreview/controller/FoodSchemeController.java b/src/main/java/com/gcc/commissionerreview/controller/FoodSchemeController.java new file mode 100644 index 0000000..0c5563a --- /dev/null +++ b/src/main/java/com/gcc/commissionerreview/controller/FoodSchemeController.java @@ -0,0 +1,198 @@ +package com.gcc.commissionerreview.controller; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.http.HttpStatus; +import org.springframework.http.ResponseEntity; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestParam; +import org.springframework.web.bind.annotation.RestController; + +import com.gcc.commissionerreview.service.FoodSchemeService; + +@RestController +@RequestMapping("/commissionerreview/api") +public class FoodSchemeController { + + @Autowired + private FoodSchemeService foodSchemeService; + + // ak + @GetMapping("/feedback-summary") + public ResponseEntity getFeedbackSummary(@RequestParam String date) { + try { + List> data = foodSchemeService.getFeedbackSummary(date); + + Map response = new HashMap<>(); + response.put("status", "success"); + response.put("date", date); + response.put("data", data); + + return ResponseEntity.ok(response); + + } catch (Exception e) { + Map error = new HashMap<>(); + error.put("status", "error"); + error.put("message", e.getMessage()); + + return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); + } + } + + // ak + @GetMapping("/zone-details") + public ResponseEntity getZoneDetails( + @RequestParam int qid, + @RequestParam String column, + @RequestParam String date) { + + try { + List> data = foodSchemeService.getZoneDetails(qid, column, date); + + Map response = new HashMap<>(); + response.put("status", "success"); + response.put("date", date); + response.put("data", data); + + return ResponseEntity.ok(response); + + } catch (Exception e) { + Map error = new HashMap<>(); + error.put("status", "error"); + error.put("message", e.getMessage()); + + return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); + } + } + + @GetMapping("/ward-details") + public ResponseEntity getWardDetails( + @RequestParam int qid, + @RequestParam String column, + @RequestParam String date, + @RequestParam int zoneId) { + + return ResponseEntity.ok(Map.of( + "status", "success", + "date", date, + "data", foodSchemeService.getWardDetails(qid, column, date, zoneId))); + } + + @GetMapping("/driver-report") + public ResponseEntity getDriverReport(@RequestParam String date, @RequestParam(required = false) Integer zone) { + try { + List> data = foodSchemeService.getDriverReport(date, zone); + + Map response = new HashMap<>(); + response.put("status", "success"); + response.put("date", date); + response.put("data", data); + + return ResponseEntity.ok(response); + + } catch (Exception e) { + Map error = new HashMap<>(); + error.put("status", "error"); + error.put("message", e.getMessage()); + + return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); + } + } + + @GetMapping("/zones") + public ResponseEntity getZones() { + List> data = foodSchemeService.getZones(); + return ResponseEntity.ok(Map.of("data", data)); + } + + /// yogi + @GetMapping("/abstract") + public ResponseEntity getAbstractReport(@RequestParam String date) { + try { + List> report = foodSchemeService.getAbstractReport(date); + // System.out.println("report : " + report); + + Map response = new HashMap<>(); + response.put("status", "success"); + response.put("date", date); + response.put("data", report); + + return ResponseEntity.ok(response); + + } catch (Exception e) { + Map error = new HashMap<>(); + error.put("status", "error"); + error.put("message", e.getMessage()); + return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); + } + } + + @GetMapping("/zoneandshiftbasedreport") + public ResponseEntity getZoneWiseShiftBasedReport(@RequestParam String date, @RequestParam Integer shiftId) { + try { + List> report = foodSchemeService.getZoneWiseShiftBasedReport(date, shiftId); + // System.out.println("report : " + report); + + Map response = new HashMap<>(); + response.put("status", "success"); + response.put("date", date); + response.put("data", report); + + return ResponseEntity.ok(response); + + } catch (Exception e) { + Map error = new HashMap<>(); + error.put("status", "error"); + error.put("message", e.getMessage()); + return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); + } + } + + @GetMapping("/wardwiseShiftReport") + public ResponseEntity getWardWiseShiftReport( + @RequestParam String date, + @RequestParam Integer shiftId, + @RequestParam Integer zone) { + + try { + List> data = foodSchemeService.getWardWiseShiftReport(shiftId, zone, date); + + Map response = new HashMap<>(); + response.put("status", "success"); + response.put("zone", zone); + response.put("data", data); + + return ResponseEntity.ok(response); + + } catch (Exception e) { + Map error = new HashMap<>(); + error.put("status", "error"); + error.put("message", e.getMessage()); + return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); + } + } + + @GetMapping("/wardlocationreport") + public ResponseEntity getWardLocationReport(@RequestParam String date) { + try { + List> report = foodSchemeService.getWardLocationWiseReport(date); + + Map response = new HashMap<>(); + response.put("status", "success"); + response.put("date", date); + response.put("data", report); + + return ResponseEntity.ok(response); + } catch (Exception e) { + Map error = new HashMap<>(); + error.put("status", "error"); + error.put("message", e.getMessage()); + return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); + } + } + +} diff --git a/src/main/java/com/gcc/commissionerreview/controller/MainController.java b/src/main/java/com/gcc/commissionerreview/controller/MainController.java index 2c61d17..7421694 100644 --- a/src/main/java/com/gcc/commissionerreview/controller/MainController.java +++ b/src/main/java/com/gcc/commissionerreview/controller/MainController.java @@ -9,7 +9,7 @@ import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; @Controller -@RequestMapping(value = {"/commissionerreview"}) +@RequestMapping(value = { "/commissionerreview" }) public class MainController { @@ -137,49 +137,47 @@ public class MainController { public String viewparkspage(Model model) { return "modules/parks"; } - - + //////////////////////////////////// - - + @GetMapping("/enforcement") public String viewenforcementpage(Model model) { return "modules/enforcement/Zonewise"; } - + @GetMapping("/sofacollection") public String sofaZoneReport(Model model) { return "modules/sofa_bed/zonewise1"; } - + @GetMapping("/petmisreport") public String petReport(Model model) { - return "modules/pet/petlicense"; + return "modules/pet/petlicense"; } - + @GetMapping("/sofacollectiondetails") public String sofaBedZoneReport(Model model) { return "modules/sofa_bed/collectiondetails"; } - + @GetMapping("/viewpendingdetails") public String viewpendingdetails(Model model) { return "modules/sofa_bed/pendingdetails"; } + @GetMapping("/foodSchemeReport") public String foodSchemereport(Model model) { return "modules/food_scheme/foodschemereport"; } - + @GetMapping("/feedbackreport") public String feedbackreport(Model model) { return "modules/food_scheme/feedbackreport"; } - - @GetMapping("/driverreport") + + @GetMapping("/driverreport") public String driverreport(Model model) { return "modules/food_scheme/driverreport"; } - } diff --git a/src/main/java/com/gcc/commissionerreview/controller/POSController.java b/src/main/java/com/gcc/commissionerreview/controller/POSController.java new file mode 100644 index 0000000..5806b70 --- /dev/null +++ b/src/main/java/com/gcc/commissionerreview/controller/POSController.java @@ -0,0 +1,43 @@ +package com.gcc.commissionerreview.controller; + +import java.time.LocalDate; +import java.time.LocalDateTime; +import java.time.format.DateTimeFormatter; +import java.util.List; +import java.util.Map; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.Model; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; + +import com.gcc.commissionerreview.service.POSService; + +@Controller +@RequestMapping("/commissionerreview/api/pos") +public class POSController { + + @Autowired + POSService posService; + + @GetMapping("/vehicleDetails") + public String zoneTransactionReport(Model model) { + + LocalDateTime ld= LocalDateTime.now(); + LocalDate curDate = ld.toLocalDate(); + + DateTimeFormatter formatter = DateTimeFormatter.ofPattern("dd-MM-yyyy HH:mm"); + String formattedDateTime = ld.format(formatter); + + System.out.println("Current Date: " + ld); + + List> reportList = posService.getZoneTransactionReport(curDate); + + model.addAttribute("vehicleDetails", reportList); + model.addAttribute("zoneMap", posService.getZoneMap()); + model.addAttribute("curDateTime", formattedDateTime); + return "modules/POS/vehicledetails"; + } + +} diff --git a/src/main/java/com/gcc/commissionerreview/service/FoodSchemeService.java b/src/main/java/com/gcc/commissionerreview/service/FoodSchemeService.java new file mode 100644 index 0000000..72d7300 --- /dev/null +++ b/src/main/java/com/gcc/commissionerreview/service/FoodSchemeService.java @@ -0,0 +1,1864 @@ +package com.gcc.commissionerreview.service; + +import java.util.List; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; + +import javax.imageio.ImageIO; +import javax.sql.DataSource; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Qualifier; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.core.env.Environment; +import org.springframework.jdbc.core.JdbcTemplate; +import org.springframework.stereotype.Service; +import java.net.URL; +import java.awt.image.BufferedImage; +import java.io.ByteArrayOutputStream; +import javax.imageio.ImageIO; + +import java.util.Arrays; +import java.util.Base64; +import java.util.concurrent.ConcurrentHashMap; +import java.util.Map; + +import com.gcc.commissionerreview.configuration.AppConfig; + +@Service +public class FoodSchemeService { + + @Autowired + private JdbcTemplate jdbcTemplate; + @Autowired + private Environment environment; + @Autowired + private AppConfig appConfig; + + @Autowired + @Value("${fileBaseUrl}") + + private String fileBaseUrl; + + // ak for pdf image render + // private final Map imageCache = new ConcurrentHashMap<>(); + + @Autowired + public void setFeedbackDataSource(@Qualifier("mysqlFoodDistributionDataSource") DataSource dataSource) { + this.jdbcTemplate = new JdbcTemplate(dataSource); + } + + public FoodSchemeService(Environment environment) { + + this.environment = environment; + + this.fileBaseUrl = environment.getProperty("fileBaseUrl"); + } + /* + * private String convertUrlToBase64(String url) { + * try { + * if (imageCache.containsKey(url)) { + * return imageCache.get(url); + * } + * + * URL imageUrl = new URL(url); + * BufferedImage image = ImageIO.read(imageUrl); + * + * ByteArrayOutputStream baos = new ByteArrayOutputStream(); + * ImageIO.write(image, "jpeg", baos); + * + * String base64 = "data:image/jpeg;base64," + + * Base64.getEncoder().encodeToString(baos.toByteArray()); + * + * imageCache.put(url, base64); + * return base64; + * + * } catch (Exception e) { + * e.printStackTrace(); + * return null; + * } + * } + */ + + public List> getFeedbackSummary(String date) { + + String sql = "SELECT " + + " fq.qid, " + + " fq.question, " + + "fq.qid, " + + + " SUM(CASE WHEN fq.qid = 1 AND fd.q1 = '1' THEN 1 ELSE 0 END) AS on_time_distribution, " + + " SUM(CASE WHEN fq.qid = 1 AND fd.q1 = '2' THEN 1 ELSE 0 END) AS delayeded, " + + + " SUM(CASE WHEN fq.qid = 2 AND fd.q2 = '3' THEN 1 ELSE 0 END) AS good, " + + " SUM(CASE WHEN fq.qid = 2 AND fd.q2 = '4' THEN 1 ELSE 0 END) AS average, " + + + " SUM(CASE WHEN fq.qid = 3 AND fd.q3 = '5' THEN 1 ELSE 0 END) AS sufficient_food_quantity, " + + " SUM(CASE WHEN fq.qid = 3 AND fd.q3 = '6' THEN 1 ELSE 0 END) AS less_quantity " + + + "FROM feedback_questions fq " + // ← space added + "LEFT JOIN feedback_data fd " + // ← space added + " ON fd.isactive = 1 " + // ← space added + " AND fd.isdelete = 0 " + // ← space added + " AND DATE(fd.feedback_date) = ? " + // ← space added + + "WHERE fq.isactive = 1 " + + "AND fq.isdelete = 0 " + + + "GROUP BY fq.qid, fq.question " + + "ORDER BY fq.orderby"; + + return jdbcTemplate.queryForList(sql, date); + + } + + // ak + public List> getZoneDetails(int qid, String column, String date) { + + String sql = "SELECT lm.zone, fq.qid, fq.question, " + + "SUM(CASE " + + " WHEN ? = 'on_time_distribution' AND fd.q1 = '1' THEN 1 " + + " WHEN ? = 'delayeded' AND fd.q1 = '2' THEN 1 " + + + " WHEN ? = 'good' AND fd.q2 = '3' THEN 1 " + + " WHEN ? = 'average' AND fd.q2 = '4' THEN 1 " + + + " WHEN ? = 'sufficient_food_quantity' AND fd.q3 = '5' THEN 1 " + + " WHEN ? = 'less_quantity' AND fd.q3 = '6' THEN 1 " + + " ELSE 0 END) AS count_value " + + + "FROM feedback_data fd " + + "INNER JOIN location_mapping lm ON fd.feedback_by = lm.siloginid " + + "INNER JOIN feedback_questions fq ON fq.qid = ? " + + + "WHERE fd.isactive = 1 " + + "AND fd.isdelete = 0 " + + "AND DATE(fd.feedback_date) = ? " + + + "GROUP BY lm.zone, fq.qid, fq.question " + + "ORDER BY lm.zone"; + + return jdbcTemplate.queryForList( + sql, + column, column, column, column, column, column, // 6 column comparisons + qid, // qid + date // date + ); + } + + /* + * public List> getZoneDetails(int qid, String column, + * String date) { + * + * String sql = "SELECT lm.zone, fq.qid, fq.question, " + + * "SUM(CASE " + + * " WHEN ? = 'on_time_distribution' AND fd.q1 = '1' THEN 1 " + + * " WHEN ? = 'delayeded' AND fd.q1 = '2' THEN 1 " + + * + * " WHEN ? = 'good' AND fd.q2 = '3' THEN 1 " + + * " WHEN ? = 'average' AND fd.q2 = '4' THEN 1 " + + * + * " WHEN ? = 'sufficient_food_quantity' AND fd.q3 = '5' THEN 1 " + + * " WHEN ? = 'less_quantity' AND fd.q3 = '6' THEN 1 " + + * " ELSE 0 END) AS count_value " + + * + * "FROM location_mapping lm " + + * "LEFT JOIN feedback_data fd ON fd.feedback_by = lm.siloginid " + + * " AND fd.isactive = 1 " + + * " AND fd.isdelete = 0 " + + * " AND DATE(fd.feedback_date) = ? " + + * + * "LEFT JOIN feedback_questions fq ON fq.qid = ? " + + * + * "GROUP BY lm.zone, fq.qid, fq.question " + + * "ORDER BY lm.zone"; + * + * return jdbcTemplate.queryForList(sql, + * column, column, column, column, column, column, // bind 6 times + * date, // date + * qid // qid + * ); + * } + */ + + public List> getDriverReport(String date, Integer zone) { + // System.out.println("File Base URL: " + fileBaseUrl);. + String zoneCondition = ""; + if (zone != null) { + zoneCondition = " AND lm.zone = " + zone + " "; + } + // System.out.println("zoneCondition: " + zone); + + String sql = "SELECT lm.location AS LocationDescription, " + + "dl.username AS DriverName, " + + "lm.zone AS Zone, " + + "lm.ward AS Ward, " + + "SUBSTRING(dss_start.driver_live_mobile, 4) AS DriverMobile, " + + "CONCAT('" + fileBaseUrl + "/gccofficialapp/files', dss_start.image) AS StartImage, " + + // "CONCAT(dss_start.latitude, ', ', dss_start.longitude) AS StartPoint, " + + "dss_start.address AS StartAddress, " + + + // "DATE_FORMAT(dss_start.datetime, '%Y-%m-%d %H:%i') AS StartTime, " + + "DATE_FORMAT(dss_start.datetime, '%h:%i %p') AS StartTime," + + // "CONCAT(dss_stop.latitude, ', ', dss_stop.longitude) AS EndPoint, " + + "dss_stop.address AS EndAddress, " + + "CONCAT('" + fileBaseUrl + "/gccofficialapp/files', dss_stop.image) AS EndImage, " + + // "DATE_FORMAT(dss_stop.datetime, '%Y-%m-%d %H:%i') AS EndTime " + + "DATE_FORMAT(dss_stop.datetime, '%h:%i %p') AS EndTime " + + + "FROM location_mapping lm " + + "INNER JOIN driver_login dl ON dl.loginid = lm.driverid " + + + "LEFT JOIN driver_start_stop dss_start " + + "ON dss_start.loginid = lm.driverid " + + "AND dss_start.action = 'Start' " + + + "LEFT JOIN driver_start_stop dss_stop " + + "ON dss_stop.loginid = lm.driverid " + + "AND dss_stop.action = 'Stop' " + + "AND dss_stop.startid = dss_start.locationid " + + + "WHERE DATE(dss_start.datetime) = ?" + zoneCondition + + "order by dss_start.datetime"; + + return jdbcTemplate.queryForList(sql, date); + } + + public List> getZones() { + String sql = "SELECT DISTINCT zone FROM location_mapping "; + return jdbcTemplate.queryForList(sql); + } + + // public List> getAbstractReport(String date) { + + // String sql = """ + // SELECT * FROM ( + + // SELECT + + // sm.name AS shift_name, + // sm.Code as shift_code, + // sm.shiftid as shiftid, + // IFNULL(SUM(gru.total_food_requested), 0) AS food_requested, + // IFNULL(SUM(gru.total_food_received), 0) AS food_delivered, + // IFNULL(SUM(dr.nulm + dr.private + dr.permanent), 0) AS overall_count, + // IFNULL(SUM(dr.nulm + dr.private + dr.permanent), 0) AS present_count, + // IFNULL(SUM(gru.today_absentees_nulm + gru.today_absentees_private + + // gru.today_absentees_permanent), 0) AS unplanned_count, + // IFNULL(SUM(dr.absentees_nulm + dr.absentees_private + + // dr.absentees_permanent), 0) AS absent_count, + // IFNULL(SUM(gru.total_box_shortfall), 0) AS food_shortfall + // FROM shift_master sm + // LEFT JOIN daily_request dr + // ON sm.shiftid = dr.shiftid AND dr.required_date = ? + // LEFT JOIN gcc_received_update gru + // ON gru.requestid = dr.requestid + // GROUP BY sm.shiftid, sm.name + + // UNION ALL + + // SELECT + // 'Total' AS shift_name, + // 'TOTAL' AS shift_code, + // 'TOTAL' as shift_id, + // IFNULL(SUM(gru.total_food_requested), 0), + // IFNULL(SUM(gru.total_food_received), 0), + // IFNULL(SUM(dr.nulm + dr.private + dr.permanent), 0), + // IFNULL(SUM(dr.nulm + dr.private + dr.permanent), 0), + // IFNULL(SUM(gru.today_absentees_nulm + gru.today_absentees_private + + // gru.today_absentees_permanent), 0), + // IFNULL(SUM(dr.absentees_nulm + dr.absentees_private + + // dr.absentees_permanent), 0), + // IFNULL(SUM(gru.total_box_shortfall), 0) + // FROM shift_master sm + // LEFT JOIN daily_request dr + // ON sm.shiftid = dr.shiftid AND dr.required_date = ? + // LEFT JOIN gcc_received_update gru + // ON gru.requestid = dr.requestid + // ) AS final_result + // """; + + // return jdbcTemplate.queryForList(sql, date, date); + // } + + // new abstract report old + // public List> getAbstractReport(String date) { + + // String sql = """ + // SELECT * FROM ( + + // /* ================= SHIFT-WISE SUMMARY ================= */ + // SELECT + // sm.name AS shift_name, + // sm.code AS shift_code, + // sm.shiftid AS shiftid, + + // /* ---------------- TOTAL COMPLEMENT ---------------- */ + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) AS + // total_complement, + + // /* ---------------- WEEKLY OFF ---------------- */ + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) AS weekly_off, + + // /* ---------------- PLANNED LEAVE ---------------- */ + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) AS planned_leave, + + // /* ---------------- PRESENT COUNT ---------------- */ + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ) AS present_count, + + // /* ---------------- FOOD REQUESTED ---------------- */ + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ) AS food_requested, + + // /* ---------------- FOOD DELIVERED ---------------- */ + // IFNULL(SUM(gru.total_food_received), 0) AS food_delivered, + + // /* ---------------- FOOD SHORTFALL ---------------- */ + // ( + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ) + // - + // IFNULL(SUM(gru.total_food_received), 0) + // ) AS food_shortfall + + // FROM shift_master sm + // LEFT JOIN daily_request dr + // ON sm.shiftid = dr.shiftid AND dr.required_date = ? + // LEFT JOIN gcc_received_update gru + // ON gru.requestid = dr.requestid + // WHERE sm.isactive = 1 AND sm.isdelete = 0 + // GROUP BY sm.shiftid, sm.name + + // UNION ALL + + // /* ================= TOTAL SUMMARY ================= */ + // SELECT + // 'Total' AS shift_name, + // 'TOTAL' AS shift_code, + // 'TOTAL' AS shiftid, + + // /* TOTAL COMPLEMENT */ + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0), + + // /* WEEKLY OFF */ + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0), + + // /* PLANNED LEAVE */ + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0), + + // /* PRESENT COUNT */ + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ), + + // /* FOOD REQUESTED */ + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ), + + // /* FOOD DELIVERED */ + // IFNULL(SUM(gru.total_food_received), 0), + + // /* FOOD SHORTFALL */ + // ( + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ) + // - + // IFNULL(SUM(gru.total_food_received), 0) + // ) + + // FROM shift_master sm + // LEFT JOIN daily_request dr + // ON sm.shiftid = dr.shiftid AND dr.required_date = ? + // LEFT JOIN gcc_received_update gru + // ON gru.requestid = dr.requestid + // WHERE sm.isactive = 1 AND sm.isdelete = 0 + // ) final_table + // """; + + // return jdbcTemplate.queryForList(sql, date, date); + // } + + // with using isactive and isdelete + public List> getAbstractReport(String date) { + + String sql = """ + SELECT * FROM ( + + /* ================= SHIFT-WISE SUMMARY ================= */ + SELECT + sm.name AS shift_name, + sm.code AS shift_code, + sm.shiftid AS shiftid, + + /* TOTAL COMPLEMENT */ + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) AS total_complement, + + /* WEEKLY OFF */ + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) AS weekly_off, + + /* PLANNED LEAVE */ + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) AS planned_leave, + + /* PRESENT COUNT */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ) AS present_count, + + /* FOOD REQUESTED = PRESENT COUNT */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ) AS food_requested, + + /* FOOD DELIVERED */ + IFNULL(SUM(gru.total_food_received), 0) AS food_delivered, + + /* FOOD SHORTFALL */ + ( + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ) + - + IFNULL(SUM(gru.total_food_received), 0) + ) AS food_shortfall + + FROM shift_master sm + LEFT JOIN daily_request dr + ON sm.shiftid = dr.shiftid + AND dr.required_date = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + LEFT JOIN gcc_received_update gru + ON gru.requestid = dr.requestid + AND gru.isactive = 1 + AND gru.isdelete = 0 + WHERE sm.isactive = 1 AND sm.isdelete = 0 + GROUP BY sm.shiftid, sm.name + + UNION ALL + + /* ================= TOTAL SUMMARY ================= */ + SELECT + 'Total' AS shift_name, + 'TOTAL' AS shift_code, + 'TOTAL' AS shiftid, + + /* TOTAL COMPLEMENT */ + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0), + + /* WEEKLY OFF */ + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0), + + /* PLANNED LEAVE */ + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0), + + /* PRESENT COUNT */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ), + + /* FOOD REQUESTED */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ), + + /* FOOD DELIVERED */ + IFNULL(SUM(gru.total_food_received), 0), + + /* FOOD SHORTFALL */ + ( + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ) + - + IFNULL(SUM(gru.total_food_received), 0) + ) + + FROM shift_master sm + LEFT JOIN daily_request dr + ON sm.shiftid = dr.shiftid + AND dr.required_date = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + LEFT JOIN gcc_received_update gru + ON gru.requestid = dr.requestid + AND gru.isactive = 1 + AND gru.isdelete = 0 + WHERE sm.isactive = 1 AND sm.isdelete = 0 + ) final_table + """; + + return jdbcTemplate.queryForList(sql, date, date); + } + + public List> getWardDetails(int qid, String column, String date, int zone) { + + String imageColumn = ""; + String whereCondition = ""; // <-- will be used in WHERE + String sumCondition = ""; // <-- used inside SUM() + + switch (column) { + case "on_time_distribution": + imageColumn = "fd.q1_img"; + whereCondition = "fd.q1 = '1'"; + sumCondition = "fd.q1 = '1'"; + break; + + case "delayeded": + imageColumn = "fd.q1_img"; + whereCondition = "fd.q1 = '2'"; + sumCondition = "fd.q1 = '2'"; + break; + + case "good": + imageColumn = "fd.q2_img"; + whereCondition = "fd.q2 = '3'"; + sumCondition = "fd.q2 = '3'"; + break; + + case "average": + imageColumn = "fd.q2_img"; + whereCondition = "fd.q2 = '4'"; + sumCondition = "fd.q2 = '4'"; + break; + + case "sufficient_food_quantity": + imageColumn = "fd.q3_img"; + whereCondition = "fd.q3 = '5'"; + sumCondition = "fd.q3 = '5'"; + break; + + case "less_quantity": + imageColumn = "fd.q3_img"; + whereCondition = "fd.q3 = '6'"; + sumCondition = "fd.q3 = '6'"; + break; + } + + String sql = "SELECT lm.ward,lm.location, fq.question, " + + "SUM(CASE WHEN " + sumCondition + " THEN 1 ELSE 0 END) AS count_value, " + + "CONCAT('" + fileBaseUrl + "/gccofficialapp/files'," + imageColumn + ") AS feedbackImage " + + "FROM feedback_data fd " + + "INNER JOIN location_mapping lm ON fd.feedback_by = lm.siloginid " + + "INNER JOIN feedback_questions fq ON fq.qid = ? " + + "WHERE lm.zone = ? " + + "AND DATE(fd.feedback_date) = ? " + + "AND fd.isactive = 1 AND fd.isdelete = 0 " + + "AND " + whereCondition + " " + // <-- EXACT MATCH ADDED + "GROUP BY lm.ward,lm.location,fq.question, " + imageColumn + " " + + "ORDER BY lm.ward"; + + return jdbcTemplate.queryForList(sql, qid, zone, date); + } + + // with using isactive and isdelete + // public List> getZoneWiseShiftBasedReport(String date, int + // shiftId) { + + // String sql = """ + // SELECT * + // FROM ( + + // /* ================= ZONE-WISE SUMMARY ================= */ + // SELECT + // z.zone AS zone, + + // /* -------- TOTAL COMPLEMENT -------- */ + // ( + // SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), + // 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) AS total_complement, + + // /* -------- WEEKLY OFF -------- */ + // ( + // SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + // dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) AS weekly_off, + + // /* -------- PLANNED LEAVE -------- */ + // ( + // SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + // dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) AS planned_leave, + + // /* -------- PRESENT COUNT -------- */ + // ( + // ( + // SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), + // 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // - + // ( + // SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + // dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // - + // ( + // SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + // dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // ) AS present_count, + + // /* -------- FOOD REQUESTED -------- */ + // ( + // ( + // SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), + // 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // - + // ( + // SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + // dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // - + // ( + // SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + // dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // ) AS food_requested, + + // /* -------- FOOD DELIVERED -------- */ + // ( + // SELECT IFNULL(SUM(gru.total_food_received), 0) + // FROM gcc_received_update gru + // WHERE gru.shiftid = ? + // AND gru.requestid IN ( + // SELECT dr.requestid + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // ) AS food_delivered, + + // /* -------- FOOD SHORTFALL (UPDATED) -------- */ + // ( + // ( + // ( + // SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), + // 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // - + // ( + // SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + // dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // - + // ( + // SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + // dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // ) + // - + // ( + // SELECT IFNULL(SUM(gru.total_food_received), 0) + // FROM gcc_received_update gru + // WHERE gru.shiftid = ? + // AND gru.requestid IN ( + // SELECT dr.requestid + // FROM daily_request dr + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + // AND dr.request_by IN ( + // SELECT lm.siloginid FROM location_mapping lm WHERE lm.zone = z.zone + // ) + // ) + // ) + // ) AS food_shortfall + + // FROM ( + // SELECT DISTINCT zone + // FROM location_mapping + // WHERE zone IS NOT NULL + // ORDER BY CAST(zone AS UNSIGNED) + // ) z + + // UNION ALL + + // /* ================= GRAND TOTAL ================= */ + // SELECT + // 'TOTAL' AS zone, + + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0), + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0), + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0), + + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ), + + // /* food_requested total = present_count total */ + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ), + + // /* delivered */ + // IFNULL(SUM(gru.total_food_received), 0), + + // /* -------- TOTAL FOOD SHORTFALL -------- */ + // ( + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + // - + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + + // dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + // - + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + + // dr.absentees_others + dr.absentees_nmr), 0) + // ) + // - + // IFNULL(SUM(gru.total_food_received), 0) + // ) + + // FROM daily_request dr + // LEFT JOIN gcc_received_update gru + // ON gru.requestid = dr.requestid + // WHERE dr.required_date = ? + // AND dr.shiftid = ? + + // ) final_output + + // ORDER BY + // CASE WHEN zone = 'TOTAL' THEN 1 ELSE 0 END, + // CAST(zone AS UNSIGNED); + // """; + + // return jdbcTemplate.queryForList(sql, + // /* zone-wise params */ + // date, shiftId, + // date, shiftId, + // date, shiftId, + // date, shiftId, date, shiftId, date, shiftId, + // date, shiftId, date, shiftId, date, shiftId, + // shiftId, date, shiftId, + + // /* shortfall zone params */ + // date, shiftId, date, shiftId, date, shiftId, + // shiftId, date, shiftId, + + // /* total row */ + // date, shiftId); + // } + + // with using isactive isdelete + public List> getZoneWiseShiftBasedReport(String date, int shiftId) { + + String sql = """ + SELECT * + FROM ( + + /* ================= ZONE-WISE SUMMARY ================= */ + SELECT + z.zone AS zone, + + /* -------- TOTAL COMPLEMENT -------- */ + ( + SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) AS total_complement, + + /* -------- WEEKLY OFF -------- */ + ( + SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) AS weekly_off, + + /* -------- PLANNED LEAVE -------- */ + ( + SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) AS planned_leave, + + /* -------- PRESENT COUNT -------- */ + ( + ( + SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + - + ( + SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + - + ( + SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + ) AS present_count, + + /* -------- FOOD REQUESTED -------- */ + ( + ( + SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + - + ( + SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + - + ( + SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + ) AS food_requested, + + /* -------- FOOD DELIVERED -------- */ + ( + SELECT IFNULL(SUM(gru.total_food_received), 0) + FROM gcc_received_update gru + WHERE gru.shiftid = ? + AND gru.isactive = 1 + AND gru.isdelete = 0 + AND gru.requestid IN ( + SELECT dr.requestid + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + ) AS food_delivered, + + /* -------- FOOD SHORTFALL -------- */ + ( + ( + ( + SELECT IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + - + ( + SELECT IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + - + ( + SELECT IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr), 0) + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + ) + - + ( + SELECT IFNULL(SUM(gru.total_food_received), 0) + FROM gcc_received_update gru + WHERE gru.shiftid = ? + AND gru.isactive = 1 + AND gru.isdelete = 0 + AND gru.requestid IN ( + SELECT dr.requestid + FROM daily_request dr + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + AND dr.request_by IN ( + SELECT lm.siloginid + FROM location_mapping lm + WHERE lm.zone = z.zone + AND lm.isactive = 1 + AND lm.isdelete = 0 + ) + ) + ) + ) AS food_shortfall + + FROM ( + SELECT DISTINCT zone + FROM location_mapping + WHERE zone IS NOT NULL + AND isactive = 1 + AND isdelete = 0 + ORDER BY CAST(zone AS UNSIGNED) + ) z + + UNION ALL + + /* ================= GRAND TOTAL ================= */ + SELECT + 'TOTAL' AS zone, + + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0), + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0), + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0), + + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ), + + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ), + + IFNULL(SUM(gru.total_food_received), 0), + + ( + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + + dr.weeklyoff_others + dr.weeklyoff_nmr), 0) + - + IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + + dr.absentees_others + dr.absentees_nmr), 0) + ) + - + IFNULL(SUM(gru.total_food_received), 0) + ) + + FROM daily_request dr + LEFT JOIN gcc_received_update gru + ON gru.requestid = dr.requestid + AND gru.isactive = 1 + AND gru.isdelete = 0 + WHERE dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + + ) final_output + + ORDER BY + CASE WHEN zone = 'TOTAL' THEN 1 ELSE 0 END, + CAST(zone AS UNSIGNED); + """; + + return jdbcTemplate.queryForList( + sql, + + /* zone-wise params */ + date, shiftId, + date, shiftId, + date, shiftId, + date, shiftId, date, shiftId, date, shiftId, + date, shiftId, date, shiftId, date, shiftId, + shiftId, date, shiftId, + + /* shortfall zone params */ + date, shiftId, date, shiftId, date, shiftId, + shiftId, date, shiftId, + + /* total row */ + date, shiftId); + } + + // without using isactive and isdelete + // public List> getWardWiseShiftReport(Integer shiftId, + // Integer zone, String date) { + + // String sql = """ + // WITH ward_data AS ( + // SELECT + // w.ward, + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) AS + // total_complement, + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + dr.weeklyoff_others + dr.weeklyoff_nmr),0) AS weekly_off, + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.absentees_nulm + // + dr.absentees_others + dr.absentees_nmr),0) AS planned_leave, + + // -- PRESENT COUNT + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + // dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + // dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr),0) + // ) AS present_count, + + // -- FOOD REQUESTED + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + // dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + + // dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr),0) + // ) AS food_requested, + + // IFNULL(SUM(gru.total_food_received),0) AS food_delivered, + + // -- FOOD SHORTFALL (corrected logic) + // CASE + // WHEN IFNULL(SUM(gru.total_food_received),0) >= ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_nulm + + // dr.weeklyoff_private + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_nulm + + // dr.absentees_private + dr.absentees_nmr),0) + // ) + // THEN 0 + // ELSE ( + // ( + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_nulm + + // dr.weeklyoff_private + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_nulm + + // dr.absentees_private + dr.absentees_nmr),0) + // ) + // - IFNULL(SUM(gru.total_food_received),0) + // ) + // END AS food_shortfall + + // FROM (SELECT DISTINCT ward FROM location_mapping WHERE zone = ? AND ward IS + // NOT NULL) w + // LEFT JOIN location_mapping lm ON lm.ward = w.ward AND lm.zone = ? + // LEFT JOIN daily_request dr ON dr.request_by = lm.siloginid + // AND dr.required_date = ? + // AND dr.shiftid = ? + // LEFT JOIN gcc_received_update gru ON gru.requestid = dr.requestid + + // GROUP BY w.ward + // ) + + // SELECT * FROM ward_data + + // UNION ALL + + // SELECT + // 'TOTAL' AS ward, + // SUM(total_complement), + // SUM(weekly_off), + // SUM(planned_leave), + // SUM(present_count), + // SUM(food_requested), + // SUM(food_delivered), + // SUM(food_shortfall) + // FROM ward_data + + // ORDER BY CASE WHEN ward = 'TOTAL' THEN 1 ELSE 0 END, ward; + // """; + + // Object[] params = new Object[] { + // zone, // w.zone + // zone, // lm.zone + // date, // dr.required_date + // shiftId // dr.shiftid + // }; + + // return jdbcTemplate.queryForList(sql, params); + // } + + // with using isactive isdelete + public List> getWardWiseShiftReport(Integer shiftId, Integer zone, String date) { + + String sql = """ + WITH ward_data AS ( + SELECT + w.ward, + + /* TOTAL COMPLEMENT */ + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) AS total_complement, + + /* WEEKLY OFF */ + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) AS weekly_off, + + /* PLANNED LEAVE */ + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) AS planned_leave, + + /* PRESENT COUNT */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) AS present_count, + + /* FOOD REQUESTED */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) AS food_requested, + + /* FOOD DELIVERED */ + IFNULL(SUM(gru.total_food_received), 0) AS food_delivered, + + /* FOOD SHORTFALL */ + CASE + WHEN IFNULL(SUM(gru.total_food_received), 0) >= + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) + THEN 0 + ELSE + ( + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) + - + IFNULL(SUM(gru.total_food_received), 0) + ) + END AS food_shortfall + + FROM ( + SELECT DISTINCT ward + FROM location_mapping + WHERE zone = ? + AND ward IS NOT NULL + AND isactive = 1 + AND isdelete = 0 + ) w + + LEFT JOIN location_mapping lm + ON lm.ward = w.ward + AND lm.zone = ? + AND lm.isactive = 1 + AND lm.isdelete = 0 + + LEFT JOIN daily_request dr + ON dr.request_by = lm.siloginid + AND dr.required_date = ? + AND dr.shiftid = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + + LEFT JOIN gcc_received_update gru + ON gru.requestid = dr.requestid + AND gru.isactive = 1 + AND gru.isdelete = 0 + + GROUP BY w.ward + ) + + SELECT * FROM ward_data + + UNION ALL + + SELECT + 'TOTAL' AS ward, + SUM(total_complement), + SUM(weekly_off), + SUM(planned_leave), + SUM(present_count), + SUM(food_requested), + SUM(food_delivered), + SUM(food_shortfall) + FROM ward_data + + ORDER BY + CASE WHEN ward = 'TOTAL' THEN 1 ELSE 0 END, + ward; + """; + + Object[] params = new Object[] { + zone, // ward subquery zone + zone, // lm.zone + date, // dr.required_date + shiftId // dr.shiftid + }; + + return jdbcTemplate.queryForList(sql, params); + } + + // without using isactive and isdelete + // public List> getWardLocationWiseReport(String date) { + + // String sql = """ + // SELECT * FROM ( + // -- ================= LOCATION WISE ================= + // SELECT + // lm.driverid, + // lm.zone, + // lm.ward, + // lm.location, + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) AS + // total_complement, + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + dr.weeklyoff_others + dr.weeklyoff_nmr),0) AS weekly_off, + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) AS planned_leave, + // (IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.nulm + + // dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) + // ) AS present_count, + // (IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.nulm + + // dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) + // ) AS food_requested, + // IFNULL(SUM(gru.total_food_received),0) AS food_delivered, + // -- ===== FOOD SHORTFALL LOGIC ===== + // (IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.nulm + + // dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) + // ) - IFNULL(SUM(gru.total_food_received),0) AS food_shortfall + // FROM location_mapping lm + // LEFT JOIN daily_request dr + // ON dr.request_by = lm.siloginid AND dr.required_date = ? + // LEFT JOIN gcc_received_update gru + // ON gru.received_by = lm.siloginid AND gru.requestid = dr.requestid + // WHERE lm.ward IS NOT NULL AND lm.location IS NOT NULL + // GROUP BY lm.driverid, lm.zone, lm.ward, lm.location + + // UNION ALL + + // -- ================= TOTAL ROW ================= + // SELECT + // 999999 AS driverid, + // 'TOTAL' AS zone, + // 'TOTAL' AS ward, + // 'TOTAL' AS location, + // IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) AS + // total_complement, + // IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.weeklyoff_nulm + // + dr.weeklyoff_others + dr.weeklyoff_nmr),0) AS weekly_off, + // IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) AS planned_leave, + // (IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + + // dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) + // ) AS present_count, + // (IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.nulm + + // dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) + // ) AS food_requested, + // IFNULL(SUM(gru.total_food_received),0) AS food_delivered, + // -- ===== FOOD SHORTFALL TOTAL ===== + // (IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others),0) + // - IFNULL(SUM(dr.weeklyoff_permanent + dr.weeklyoff_private + dr.nulm + + // dr.weeklyoff_others + dr.weeklyoff_nmr),0) + // - IFNULL(SUM(dr.absentees_permanent + dr.absentees_private + dr.nulm + + // dr.absentees_others + dr.absentees_nmr),0) + // ) - IFNULL(SUM(gru.total_food_received),0) AS food_shortfall + // FROM daily_request dr + // LEFT JOIN gcc_received_update gru ON gru.requestid = dr.requestid + // WHERE dr.required_date = ? + // ) final_output + // ORDER BY driverid ASC + // """; + + // Object[] params = new Object[] { date, date }; // first for location JOIN, + // second for TOTAL row + // return jdbcTemplate.queryForList(sql, params); + // } + + // with using isactive isdelete + public List> getWardLocationWiseReport(String date) { + + String sql = """ + SELECT * FROM ( + /* ================= LOCATION WISE ================= */ + SELECT + lm.driverid, + lm.zone, + lm.ward, + lm.location, + + /* TOTAL COMPLEMENT */ + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) AS total_complement, + + /* WEEKLY OFF */ + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) AS weekly_off, + + /* PLANNED LEAVE */ + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) AS planned_leave, + + /* PRESENT COUNT */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) AS present_count, + + /* FOOD REQUESTED */ + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) AS food_requested, + + /* FOOD DELIVERED */ + IFNULL(SUM(gru.total_food_received), 0) AS food_delivered, + + /* FOOD SHORTFALL */ + ( + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) + - + IFNULL(SUM(gru.total_food_received), 0) + ) AS food_shortfall + + FROM location_mapping lm + LEFT JOIN daily_request dr + ON dr.request_by = lm.siloginid + AND dr.required_date = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + + LEFT JOIN gcc_received_update gru + ON gru.requestid = dr.requestid + AND gru.received_by = lm.siloginid + AND gru.isactive = 1 + AND gru.isdelete = 0 + + WHERE lm.ward IS NOT NULL + AND lm.location IS NOT NULL + AND lm.isactive = 1 + AND lm.isdelete = 0 + + GROUP BY + lm.driverid, + lm.zone, + lm.ward, + lm.location + + UNION ALL + + /* ================= TOTAL ROW ================= */ + SELECT + 999999 AS driverid, + 'TOTAL' AS zone, + 'TOTAL' AS ward, + 'TOTAL' AS location, + + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0), + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0), + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0), + + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ), + + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ), + + IFNULL(SUM(gru.total_food_received), 0), + + ( + ( + IFNULL(SUM(dr.permanent + dr.nulm + dr.private + dr.nmr + dr.others), 0) + - + IFNULL(SUM( + dr.weeklyoff_permanent + dr.weeklyoff_private + + dr.weeklyoff_nulm + dr.weeklyoff_others + dr.weeklyoff_nmr + ), 0) + - + IFNULL(SUM( + dr.absentees_permanent + dr.absentees_private + + dr.absentees_nulm + dr.absentees_others + dr.absentees_nmr + ), 0) + ) + - + IFNULL(SUM(gru.total_food_received), 0) + ) + + FROM daily_request dr + LEFT JOIN gcc_received_update gru + ON gru.requestid = dr.requestid + AND gru.isactive = 1 + AND gru.isdelete = 0 + WHERE dr.required_date = ? + AND dr.isactive = 1 + AND dr.isdelete = 0 + + ) final_output + ORDER BY driverid ASC + """; + + Object[] params = new Object[] { + date, // location-wise join + date // total row + }; + + return jdbcTemplate.queryForList(sql, params); + } + +} + +/* + * String sql = "SELECT lm.location AS LocationDescription, "+ + * "dl.username AS DriverName, "+ + * " CONCAT('" + * +fileBaseUrl+"/gccofficialapp/files',dss_start.image) as upload_image_url, "+ + * " CONCAT(dss_start.latitude, ', ', dss_start.longitude) AS StartPoint, "+ + * "Date(dss_start.datetime) AS StartTime, "+ + * + * " CONCAT(dss_stop.latitude, ', ', dss_stop.longitude) AS EndPoint, "+ + * Date(dss_stop.datetime) AS EndTime + * + * FROM location_mapping lm + * INNER JOIN driver_login dl + * ON dl.loginid = lm.driverid + * + * LEFT JOIN driver_start_stop dss_start + * ON dss_start.loginid = lm.driverid + * AND dss_start.action = 'Start' + * + * + * LEFT JOIN driver_start_stop dss_stop + * ON dss_stop.loginid = lm.driverid + * AND dss_stop.action = 'Stop' + * AND dss_stop.startid = dss_start.locationid + * WHERE DATE(dss_start.datetime) = ?"; + * change for full query + */ \ No newline at end of file diff --git a/src/main/java/com/gcc/commissionerreview/service/POSService.java b/src/main/java/com/gcc/commissionerreview/service/POSService.java new file mode 100644 index 0000000..37dd7e9 --- /dev/null +++ b/src/main/java/com/gcc/commissionerreview/service/POSService.java @@ -0,0 +1,84 @@ +package com.gcc.commissionerreview.service; + +import java.time.LocalDate; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import javax.sql.DataSource; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Qualifier; +import org.springframework.boot.autoconfigure.batch.BatchProperties.Jdbc; +import org.springframework.jdbc.core.JdbcTemplate; +import org.springframework.stereotype.Service; + +@Service +public class POSService { + + @Autowired + JdbcTemplate jdbcTemplate; + + @Autowired + public void setDataSource(@Qualifier("mysqlPOSDataSource") DataSource dataSource) { + this.jdbcTemplate = new JdbcTemplate(dataSource); + } + + public List> getZoneTransactionReport(LocalDate date) { + + String sql = " SELECT CAST(d.ZONE_HQ AS UNSIGNED) AS zone, " + + " CONCAT(IFNULL(d.LOC_FLAG,'ALL'),'-',IFNULL(d.ACTUAL_LOC,'ALL')) AS unit, " + + " COUNT(CASE WHEN DATE(a.txnDate) BETWEEN '2024-10-02' AND ? THEN a.txnId END) AS total_transactions, " + + " SUM(CASE WHEN DATE(a.txnDate) BETWEEN '2024-10-02' AND ? THEN a.transactionAmount END) AS total_transaction_amount " + + " FROM bank_transactions a " + + " JOIN penalty_challan b ON b.orderid = a.txnId " + + " JOIN penalty_category c ON c.id = b.category_id " + + " JOIN user_zone d ON d.ID = b.challan_by " + + " WHERE c.name <> 'Testing' " + + " AND d.USER_NAME LIKE 'ENF%' " + + " AND d.LOC_FLAG <> 'H' " + + " AND d.ZONE_HQ <> 0 " + + " AND DATE(a.txnDate) BETWEEN '2024-10-02' AND ? " + + " GROUP BY CAST(d.ZONE_HQ AS UNSIGNED), d.LOC_FLAG, d.ACTUAL_LOC " + + + " UNION ALL " + + + " SELECT 0 AS zone, 'TOTAL' AS unit, " + + " COUNT(CASE WHEN DATE(a.txnDate) BETWEEN '2024-10-02' AND ? THEN a.txnId END), " + + " SUM(CASE WHEN DATE(a.txnDate) BETWEEN '2024-10-02' AND ? THEN a.transactionAmount END) " + + " FROM bank_transactions a " + + " JOIN penalty_challan b ON b.orderid = a.txnId " + + " JOIN penalty_category c ON c.id = b.category_id " + + " JOIN user_zone d ON d.ID = b.challan_by " + + " WHERE c.name <> 'Testing' " + + " AND d.USER_NAME LIKE 'ENF%' " + + " AND d.LOC_FLAG <> 'H' " + + " AND d.ZONE_HQ <> 0 " + + " AND DATE(a.txnDate) BETWEEN '2024-10-02' AND ? " + + " ORDER BY CASE WHEN zone = 0 THEN 1 ELSE 0 END,zone, unit "; + + return jdbcTemplate.queryForList(sql, date, date, date, date, date, date); + + } + + public Map getZoneMap() { + Map map = new HashMap<>(); + map.put(1, "01 - Tiruvottiyur"); + map.put(2, "02 - Manali"); + map.put(3, "03 - Madhavaram"); + map.put(4, "04 - Tondiarpet"); + map.put(5, "05 - Royapuram"); + map.put(6, "06 - Tiru Vi Ka Nagar"); + map.put(7, "07 - Ambattur"); + map.put(8, "08 - Anna Nagar"); + map.put(9, "09 - Teynampet"); + map.put(10, "10 - Kodambakkam"); + map.put(11, "11 - Valasaravakkam"); + map.put(12, "12 - Alandur"); + map.put(13, "13 - Adyar"); + map.put(14, "14 - Perungudi"); + map.put(15, "15 - Sholinganallur"); + return map; + } + +} \ No newline at end of file diff --git a/src/main/resources/templates/modules/POS/vehicledetails.html b/src/main/resources/templates/modules/POS/vehicledetails.html new file mode 100644 index 0000000..9dcf8af --- /dev/null +++ b/src/main/resources/templates/modules/POS/vehicledetails.html @@ -0,0 +1,123 @@ + + + + + + Enforcement Vehicles Details + + + + +

+ GCC - Enforcement Team Penalty Collection Daily Report + +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
S.NoZoneUnit NoTransactionsAmount (β‚Ή)
+ + TOTAL + + + +
+ + + + \ No newline at end of file diff --git a/src/main/resources/templates/modules/food_scheme/driverreport.html b/src/main/resources/templates/modules/food_scheme/driverreport.html new file mode 100644 index 0000000..e0459eb --- /dev/null +++ b/src/main/resources/templates/modules/food_scheme/driverreport.html @@ -0,0 +1,430 @@ + + + + + Food Scheme Operations Dashboard + + + + + + + + + + + + + + +
+

Food Scheme Report

+
+ + + +
+
+ +
+
Driver Logistics Report
+ + +
+ + +
+ + +
+ + +
+ + +
+ + +
+ + +
+ +
+ + + +
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/resources/templates/modules/food_scheme/feedbackreport.html b/src/main/resources/templates/modules/food_scheme/feedbackreport.html new file mode 100644 index 0000000..c52618c --- /dev/null +++ b/src/main/resources/templates/modules/food_scheme/feedbackreport.html @@ -0,0 +1,706 @@ + + + + + Feedback Summary Report + + + + + + + + + +
+

Food Scheme – Feedback Summary

+
+ +
+
+ +
+
Feedback Summary
+ +
+ + +
+
+ +
+ +
+
Feedback - Food Distribution Time
+ + + + + + + + + +
CategoryCount
+
+ +
+
Feedback - Food Taste
+ + + + + + + + +
CategoryCount
+
+ +
+
Feedback - Food Quantity
+ + + + + + + + +
CategoryCount
+
+ +
+ + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/resources/templates/modules/food_scheme/foodschemereport.html b/src/main/resources/templates/modules/food_scheme/foodschemereport.html new file mode 100644 index 0000000..b2925b2 --- /dev/null +++ b/src/main/resources/templates/modules/food_scheme/foodschemereport.html @@ -0,0 +1,1520 @@ + + + + + + + + Food Distribution Operations Dashboard + + + + + + + + + + + + + + +
+

Food Distribution Report

+
+ + + +
+
+
Shift Wise Overview
+ +
+ + + + + + + +
+ + +
+ + + + + + + + + + + + + + + + + +
ShiftTotal ComplementWeekly OffPlanned LeavePresent CountFood RequestedFood DeliveredFood Shortfall
+
+
+ + + +
+
+
Shift A - Daily Food Menu
+ + + + + + + + + + + + + + + + + + + + + + + + + +
MondayTuesdayWednesdayThursdayFridaySaturdaySunday
Sambar Rice (650g) & Porial (100g)Lemon Rice (500g) & Potato/yam/Raw banana fry (100g)Veg Biryani (500g) & Brinjal Onion (75g)Tomato Rice (500g) & Potato/yam/Raw banana fry (100g)Coriander/Mint Rice (500g) & Potato/yam/Raw banana fry (100g)Tamarind Rice (500g) & Potato/yam/Raw banana fry (100g)Veg Biryani (500g) & Brinjal Onion (75g)
+ +
+
+ + + + + + + + + +
+
+ + + + +
+
+
+
Zone wise Overallview
+ +
+ + +
+ + + + + + + + + + + + + + +
zoneTotal Complementweekly OffPlanned LeavePresent CountFood RequestedFood DeliveredFood Shortfall
+
+
+ + + +
+
+
+
Overall Location wise Overview
+
Select Zone:
+ + +
+ + + + + + + +
+
+ + + + + + + + + + + + + + + + +
ZoneWardLocationsTotal Complementweekly OffPlanned LeavePresent CountFood RequestedFood DeliveredFood Shortfall
+
+
+
+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file