Resolves #2322 Track supervisor id, decision and comment in anonymous profile - #2399
Open
codetuscan wants to merge 2 commits into
Open
codetuscan wants to merge 2 commits into
codetuscan wants to merge 2 commits into
Conversation
…ymous profile Adds supervisorId, supervisorDecision and supervisorComment to the anonymous profile so reports can be grouped by supervisor. supervisorId is already present in the packet operationsData and is read alongside officerId; it is now labelled on its own instead of only being part of assisted[]. The decision and comment are not in the packet at all - the supervisor takes the decision on the registration client and it reaches registration_list on sync. AnonymousProfileTagGenerator therefore reads them from there by workflowInstanceId, the same unique key SupervisorApprovalStatusTagGenerator uses, and adds them to the profile JSON it tags. A missing registration_list record leaves both fields null and the profile is still tagged. No schema change, no new API and no change to any existing method signature; existing profiles and dashboards are unaffected because the three fields are additive. Co-authored-by: Sarthak Maheshwari <65298686+SartMa@users.noreply.github.com> Signed-off-by: codetuscan <Sunhith.Reddy@iiitb.ac.in>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Team Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
codetuscan
force-pushed
the
feature/2322-supervisor-details-anonymous-profile
branch
from
August 31, 2026 11:52
1780c39 to
b7a80ed
Compare
…r lookup fails The supervisor decision fetch is a best-effort enrichment, so a failure in addSupervisorDecision must cost only the supervisorDecision and supervisorComment fields - not the profile tag itself. Wrap the call so the profile JSON built from the packet is still tagged, mirroring how a failed biometrics fetch only drops the biometrics. A missing registration_list record is the normal case at classification time (the supervisor decision has not synced yet), so drop that log from warn to debug. Co-authored-by: Sarthak Maheshwari <65298686+SartMa@users.noreply.github.com> Signed-off-by: codetuscan <Sunhith.Reddy@iiitb.ac.in>
codetuscan
force-pushed
the
feature/2322-supervisor-details-anonymous-profile
branch
from
September 7, 2026 13:24
0b62de3 to
93061d5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue
Resolves #2322
What this adds
supervisorId,supervisorDecisionandsupervisorCommenton the anonymous profile, so supervisor-wise approved/rejected packet reports can be produced through the existing Elasticsearch/Kibana pipeline.Where each field comes from
operationsDataand already read next toofficerIdinAnonymousProfileServiceImpl. It was only going intoassisted[]; it is now also set on its own field so reports can group by it.registration_liston sync (supervisor_status,supervisor_comment).AnonymousProfileTagGeneratornow reads them from there while it builds the profile tag, looking up byworkflowInstanceId- the same unique keySupervisorApprovalStatusTagGeneratorin the same package already uses.Behaviour notes
registration_listrecord leaves both fields null and the profile is still tagged - supervisor reporting never costs us the profile itself.AnonymousProfileDTOusing the sameJsonUtilmapper that produced the JSON, so field shape and null handling are unchanged.buildAndSaveAnonymousProfileFromPacketfallback (no tag present, e.g. processed before the classifier stage ran) getsupervisorIdonly. Adding the same lookup there is a small follow-up if wanted - that path hasworkflowInstanceIdon its DTO.Constraints from the issue
No DB schema change, no new API, no Registration Client change, and no change to any existing method signature. The three fields are additive, so existing reports and dashboards keep working and historical profiles need no migration.