-
Notifications
You must be signed in to change notification settings - Fork 268
Add AgentTrafficLog functionality for bulk writing and storage #3670
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: feature/mini-runtime-container-release
Are you sure you want to change the base?
Add AgentTrafficLog functionality for bulk writing and storage #3670
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤖 AI Security analysis: "Scanner found no security issues in this change, but absence of findings does not guarantee safety. Seven files were modified—manual review or additional testing is recommended for complex logic, secrets, or dependency updates."
| Risk Level | AI Score |
|---|---|
| 🟢 NO RISK | 5.0/100 |
Top 0 security issues / 0 total (Critical: 0, High: 0, Medium: 0, Low: 0)
| Title | Location | Recommendation |
|---|---|---|
| — | — | No issues to display |
| return Action.SUCCESS.toUpperCase(); | ||
| } | ||
|
|
||
| public String bulkWriteAgentTrafficLogs() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for changes in DbAction for mini-runtime. These actions are for cyborg.
Rather we need to complete the impl in DbActor (which extends DataActor)
| if (params.getRequestParams() != null) { | ||
| log.setApiCollectionId(params.getRequestParams().getApiCollectionId()); | ||
| } | ||
| log.setAccountId(params.getAccountId()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sync with cyborg here as well
| } | ||
|
|
||
| BasicDBObject obj = new BasicDBObject(); | ||
| obj.put("agentTrafficLogs", agentTrafficLogs); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a safety check, we can define some upper limit of payload size, if it exceeds ingest traffic logs in smaller batches.
|
|
||
| public abstract void storeConversationResults(List<AgentConversationResult> conversationResults); | ||
|
|
||
| public abstract void bulkWriteAgentTrafficLogs(List<Object> writesForAgentTrafficLogs); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
writesForAgentTrafficLogs -> agentTrafficLogs (multiple places)
| } | ||
|
|
||
| @Override | ||
| public void bulkWriteAgentTrafficLogs(List<Object> writesForAgentTrafficLogs) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Impl in DBActor as well
rakshak-akto
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bind base prompt to agent endpoint, rest LGTM
…afficLogs method, enhance indexing and collection management, and improve DTO structure for better clarity and performance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤖 AI Security analysis: "Multiple files changed; automated analysis found no security issues. Changes can still introduce undetected logic vulnerabilities, misconfigurations, or dependency risks if scanners miss new code paths or libraries."
| Risk Level | AI Score |
|---|---|
| 🟢 NO RISK | 0.0/100 |
Top 0 security issues / 0 total (Critical: 0, High: 0, Medium: 0, Low: 0)
| Title | Location | Recommendation |
|---|---|---|
| — | — | No issues to display |
No description provided.