pub struct IntermediateMutation {Show 15 fields
pub name: String,
pub return_type: String,
pub returns_list: bool,
pub nullable: bool,
pub arguments: Vec<IntermediateArgument>,
pub description: Option<String>,
pub sql_source: Option<String>,
pub operation: Option<String>,
pub deprecated: Option<IntermediateDeprecation>,
pub inject: IndexMap<String, String>,
pub invalidates_fact_tables: Vec<String>,
pub invalidates_views: Vec<String>,
pub changelog: bool,
pub input_style: InputStyle,
pub changelog_pre_image: bool,
}Expand description
Mutation definition in intermediate format
Fields§
§name: StringMutation name (e.g., “createUser”)
return_type: StringReturn type name (e.g., “User”)
returns_list: boolReturns a list?
nullable: boolResult is nullable?
arguments: Vec<IntermediateArgument>Mutation arguments
description: Option<String>Mutation description (from docstring)
sql_source: Option<String>SQL source (function name)
operation: Option<String>Operation type (CREATE, UPDATE, DELETE, CUSTOM)
deprecated: Option<IntermediateDeprecation>Deprecation info (from @deprecated directive)
inject: IndexMap<String, String>Server-injected parameters: SQL parameter name → source expression (e.g. "jwt:org_id").
Not exposed as GraphQL arguments.
invalidates_fact_tables: Vec<String>Fact tables whose version counter should be bumped after this mutation succeeds.
Used for correct invalidation of analytic/aggregate cache entries.
invalidates_views: Vec<String>View names whose cached query results should be invalidated after this mutation succeeds.
changelog: boolWhether this mutation writes a Change-Spine change-log row (default true).
Set false (via the authoring SDK’s @fraiseql.mutation(changelog=False))
to opt a single mutation out of the in-transaction change-log outbox while
the rest of the schema keeps logging. Defaults to true so a schema
authored before this field existed keeps logging.
input_style: InputStyleHow the GraphQL input argument is passed to the SQL function:
"flatten" (positional columns, the default) or "jsonb" (the whole
input as one jsonb arg). See InputStyle.
Orthogonal to operation: set
"jsonb" (via the authoring SDK’s
@fraiseql.mutation(input_style="jsonb")) so a backend using the
single-jsonb-wrapper convention can register the real DML verb and
still receive the whole input as one argument. Defaults to "flatten",
byte-identical to a schema authored before this field existed.
changelog_pre_image: boolWhether a successful, state-changing run of this mutation also records the
changed entity’s pre-image (before-state) into the Change-Spine
object_data_before column, sourced from an optional entity_before on the
mutation’s app.mutation_response.
Set true (via the authoring SDK’s
@fraiseql.mutation(changelog_pre_image=True) or TOML
changelog_pre_image = true) to opt an audit-sensitive mutation into an
inline Debezium-style {before, after}. Defaults to false,
byte-identical to a schema authored before this field existed.
Trait Implementations§
Source§impl Clone for IntermediateMutation
impl Clone for IntermediateMutation
Source§fn clone(&self) -> IntermediateMutation
fn clone(&self) -> IntermediateMutation
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for IntermediateMutation
impl Debug for IntermediateMutation
Source§impl Default for IntermediateMutation
impl Default for IntermediateMutation
Source§impl<'de> Deserialize<'de> for IntermediateMutation
impl<'de> Deserialize<'de> for IntermediateMutation
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for IntermediateMutation
Source§impl PartialEq for IntermediateMutation
impl PartialEq for IntermediateMutation
Source§fn eq(&self, other: &IntermediateMutation) -> bool
fn eq(&self, other: &IntermediateMutation) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for IntermediateMutation
impl Serialize for IntermediateMutation
impl StructuralPartialEq for IntermediateMutation
Auto Trait Implementations§
impl Freeze for IntermediateMutation
impl RefUnwindSafe for IntermediateMutation
impl Send for IntermediateMutation
impl Sync for IntermediateMutation
impl Unpin for IntermediateMutation
impl UnsafeUnpin for IntermediateMutation
impl UnwindSafe for IntermediateMutation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more