-
Notifications
You must be signed in to change notification settings - Fork 108
[DRAFT] Improve db max size and prune handling #3983
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: for-mobile-based-on-2.1.7
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -44,7 +44,7 @@ | |
| public final class TwoPartyPrivateChatMessage extends PrivateChatMessage<TwoPartyPrivateChatMessageReaction> { | ||
| // Metadata needs to be symmetric with TwoPartyPrivateChatMessageReaction. | ||
| // MetaData is transient as it will be used indirectly by low level network classes. Only some low level network classes write the metaData to their protobuf representations. | ||
| private transient final MetaData metaData = new MetaData(TTL_30_DAYS, getClass().getSimpleName(), MAX_MAP_SIZE_100); | ||
| private transient final MetaData metaData = new MetaData(TTL_30_DAYS, getClass().getSimpleName(), MAX_MAP_SIZE_1000); | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chainVerify symmetry with TwoPartyPrivateChatMessageReaction. The comment on line 45 explicitly states that metadata must be symmetric with Run the following script to verify the MetaData configuration in the related class: 🏁 Script executed: #!/bin/bash
# Description: Verify TwoPartyPrivateChatMessageReaction uses MAX_MAP_SIZE_1000 for symmetry
# Search for MetaData initialization in TwoPartyPrivateChatMessageReaction
rg -n -A2 -B2 'class TwoPartyPrivateChatMessageReaction' --type java
rg -n 'new MetaData.*MAX_MAP_SIZE' chat/src/main/java/bisq/chat/reactions/TwoPartyPrivateChatMessageReaction.javaLength of output: 956 Fix asymmetric MetaData configuration between related classes. Verification found that 🤖 Prompt for AI Agents |
||
|
|
||
| public TwoPartyPrivateChatMessage(String messageId, | ||
| ChatChannelDomain chatChannelDomain, | ||
|
|
||
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.
Inconsistent maxMapSize violates symmetry requirement.
The comment on Line 36 states "Metadata needs to be symmetric with TwoPartyPrivateChatMessage," but MAX_MAP_SIZE_10_000 is used here while the DEFAULT_MAX_MAP_SIZE_BY_CLASS_NAME in MetaData.java specifies MAX_MAP_SIZE_1000 for both TwoPartyPrivateChatMessage and TwoPartyPrivateChatMessageReaction. This 10x discrepancy breaks the intended symmetry.
Apply this diff to fix the inconsistency:
📝 Committable suggestion
🤖 Prompt for AI Agents