pub struct SparqlResponse {
pub status: u16,
pub content_type: Option<String>,
pub body: Vec<u8>,
}Expand description
One relayed SPARQL response: the triplestore’s own status, media type and bytes.
Deliberately not a parsed model — dsp-cli/ADR-0016. The body is whatever the store serialized, in whatever format it negotiated, and dsp-cli does not interpret it.
Fields§
§status: u16The triplestore’s HTTP status, relayed by DSP-API.
content_type: Option<String>The triplestore’s Content-Type, if it sent one. Never written to stdout —
it feeds the -v disclosure and the classifier’s body-parse decision.
body: Vec<u8>The response body, byte-exact.
Trait Implementations§
Source§impl Clone for SparqlResponse
impl Clone for SparqlResponse
Source§impl Debug for SparqlResponse
Hand-written: a derived Debug on a struct holding up to 64 MiB of
store-authored bytes would mean the first tracing::debug!(?resp) or the
codebase’s standard assert!(…, "{result:?}") test idiom dumps
unsanitised store output into stderr or CI logs. Prints the body length
instead of its bytes, and caps content_type defensively.
impl Debug for SparqlResponse
Hand-written: a derived Debug on a struct holding up to 64 MiB of
store-authored bytes would mean the first tracing::debug!(?resp) or the
codebase’s standard assert!(…, "{result:?}") test idiom dumps
unsanitised store output into stderr or CI logs. Prints the body length
instead of its bytes, and caps content_type defensively.