Package com.ultikits.ultitools.manager
Class ServerPropertiesManager.SetAllResult
java.lang.Object
com.ultikits.ultitools.manager.ServerPropertiesManager.SetAllResult
- Enclosing class:
ServerPropertiesManager
Outcome of one
set_all batch.
isSuccess() means every key the caller asked for is now on disk,
which is the batch analogue of what action: "set" already reports for a
single key. Keys carrying an explicit JSON null are not part of that
promise — a null reads as "leave this one alone", so it is recorded in
getSkipped() for visibility but never fails the batch.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionOne line naming what went wrong, for a log record or an error response.Whitelisted keys whose write failed.Keys whose value was not a JSON primitive.Keys onServerPropertiesManager.SAFE_KEYSbut absent from THIS server's ownserver.properties(D-15).Keys refused because they are not on the whitelist.Keys whose value was an explicit JSON null.Keys written to disk.booleanEvery requested key was written.
-
Field Details
-
updated
-
rejected
-
failed
-
skipped
-
malformed
-
notPresentOnServer
-
-
Constructor Details
-
SetAllResult
public SetAllResult(List<String> updated, List<String> rejected, List<String> failed, List<String> skipped, List<String> malformed, List<String> notPresentOnServer) Public so callers outside this package can build one. Each list is copied before being wrapped —unmodifiableListis a view, so wrapping the caller's list directly would leave this "immutable" object mutable through the original reference.- Parameters:
notPresentOnServer- keys allowlisted but absent from THIS server's ownserver.properties(D-15) — Gate-2 finding: kept distinct fromfailedso the response can say "this server version has no such key" rather than making it indistinguishable from a genuine read/write I/O error, matching what a single-keyaction: "set"already reports viaServerPropertiesManager.describeOutcome(WriteOutcome).
-
-
Method Details
-
getUpdated
Keys written to disk. -
getRejected
Keys refused because they are not on the whitelist. -
getFailed
Whitelisted keys whose write failed. -
getSkipped
Keys whose value was an explicit JSON null. -
getMalformed
Keys whose value was not a JSON primitive. -
getNotPresentOnServer
Keys onServerPropertiesManager.SAFE_KEYSbut absent from THIS server's ownserver.properties(D-15). Distinct fromgetFailed()— writing one of these was never attempted; it is a version mismatch, not an I/O failure. -
isSuccess
public boolean isSuccess()Every requested key was written. -
describeFailure
One line naming what went wrong, for a log record or an error response. Returnsnullwhen nothing went wrong.The categories stay separate because they need different actions: a rejected key means stop asking for it, a failed key means look at the disk, a malformed key means fix the payload, and a not-present-on-server key means this Paper version does not have it. Collapsing them into one label would send the reader looking in the wrong place — which is the failure mode this whole change exists to remove.
-