<p>This refactoring is a continuation from the concurrency fixes in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="575346360" data-permission-text="Title is private" data-url="https://github.com/bisq-network/bisq/issues/4025" data-hovercard-type="pull_request" data-hovercard-url="/bisq-network/bisq/pull/4025/hovercard" href="https://github.com/bisq-network/bisq/pull/4025">#4025</a>, to remove all the remaining superfluous <code>PersistableEnvelope</code> interfaces on classes implementing <code>Proto</code>.</p>
<ul>
<li>
<p>Remove an unused <code>PersistableEnvelope</code> interface from the following five <code>PersistableNetworkPayload</code> implementations:</p>
<blockquote>
<p>AccountAgeWitness, BlindVotePayload, ProposalPayload, SignedWitness, TradeStatistics2</p>
</blockquote>
<p>These already have corresponding <code>*Store</code> envelope classes which correctly implement the interface.</p>
</li>
<li>
<p>Additionally, delete the unused class <code>PersistableHashMap</code>, make <code>(UserThreadMapped)PersistableList</code> abstract and remove some unused functionality from the base class.</p>
</li>
<li>
<p>The last commit in this PR touches the DAO packages, as the consensus-critical classes <code>MeritList</code> and <code>VoteWithProposalTxIdList</code> needlessly implement the <code>PersistableEnvelope</code> interface prior to this change, via the base class <code>PersistableList</code>. I inlined the <code>list</code> field, instead of inheriting it from the base class, and made them standalone classes instead. This shouldn't observably alter behaviour and would hopefully also reduce the chance of future inadvertent changes in behaviour (as <code>PersistableList</code> lies outside the DAO packages).</p>
</li>
</ul>

<hr>

<h4>You can view, comment on, or merge this pull request online at:</h4>
<p>  <a href='https://github.com/bisq-network/bisq/pull/4102'>https://github.com/bisq-network/bisq/pull/4102</a></p>

<h4>Commit Summary</h4>
<ul>
  <li>Tidy payload instances wrongly implementing PersistableEnvelope</li>
  <li>Delete PersistableHashMap & simplify PersistableList</li>
  <li>Make MeritList & VoteWithProposalTxIdList standalone classes</li>
</ul>

<h4>File Changes</h4>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-9077c8951662a6704ef0c3dcdc553830">common/src/main/java/bisq/common/proto/ProtoResolver.java</a>
    (5)
  </li>
  <li>
    <strong>D</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-1f087a1a893dd3a0d574434f7c892625">common/src/main/java/bisq/common/proto/persistable/PersistableHashMap.java</a>
    (50)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-5c45d321af4815b655248cedfb46627c">common/src/main/java/bisq/common/proto/persistable/PersistableList.java</a>
    (27)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-277fdd1626aeb0a82c67fe47ba6d9a11">common/src/main/java/bisq/common/proto/persistable/UserThreadMappedPersistableList.java</a>
    (2)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-ca6058d9f041f31aaa9e29360e2d60a3">core/src/main/java/bisq/core/account/sign/SignedWitness.java</a>
    (3)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-1df8f9c1f364f90db8e0a8ed44e3b4d1">core/src/main/java/bisq/core/account/witness/AccountAgeWitness.java</a>
    (3)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-e997916967df1356e98acfb4e37168a9">core/src/main/java/bisq/core/dao/governance/blindvote/VoteWithProposalTxIdList.java</a>
    (21)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-13dcca19d8c5adb2f667a560f379804f">core/src/main/java/bisq/core/dao/governance/blindvote/storage/BlindVotePayload.java</a>
    (3)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-78c56f5cba2415a7c976f7e72a4443fe">core/src/main/java/bisq/core/dao/governance/proposal/storage/appendonly/ProposalPayload.java</a>
    (3)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-c39c2d7624ecaf9c611b7c2c5c7e8ba9">core/src/main/java/bisq/core/dao/governance/voteresult/VoteResultService.java</a>
    (8)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-4e2c8424a6fe322eca775e251d2a4237">core/src/main/java/bisq/core/dao/state/model/governance/MeritList.java</a>
    (19)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-d595360956ba535f445a9ba0a831656e">core/src/main/java/bisq/core/proto/CoreProtoResolver.java</a>
    (6)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-7797e84941bbe8ab1a6abf8eac281d85">core/src/main/java/bisq/core/proto/persistable/CorePersistenceProtoResolver.java</a>
    (3)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-741949d8e3ee6937ee9812b1c55792e4">core/src/main/java/bisq/core/trade/statistics/TradeStatistics2.java</a>
    (4)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-0b98fc385296e17470f56aaf159744b3">p2p/src/test/java/bisq/network/p2p/TestUtils.java</a>
    (8)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/bisq-network/bisq/pull/4102/files#diff-41caf249b58a6c497f396da0a67168e4">proto/src/main/proto/pb.proto</a>
    (2)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/bisq-network/bisq/pull/4102.patch'>https://github.com/bisq-network/bisq/pull/4102.patch</a></li>
  <li><a href='https://github.com/bisq-network/bisq/pull/4102.diff'>https://github.com/bisq-network/bisq/pull/4102.diff</a></li>
</ul>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/bisq-network/bisq/pull/4102">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AJFFTNXY5TL5UKVCMFI4YZLRKC4OTANCNFSM4LWV6UDA">unsubscribe</a>.<img src="https://github.com/notifications/beacon/AJFFTNVPCA5M7DL3ZAQVZKLRKC4OTA5CNFSM4LWV6UDKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4IZQUWPA.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/bisq-network/bisq/pull/4102",
"url": "https://github.com/bisq-network/bisq/pull/4102",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>