Steven Schmatz
02/23/2024, 1:05 AMScout
02/23/2024, 1:05 AMgraphql mutation TerminateRun($runId: String!) { terminateRun(runId: $runId){ __typename ... on TerminateRunSuccess{ run { runId } } ... on TerminateRunFailure { message } ... on RunNotFoundError { runId } ... on PythonError { message stack } } }
This example shows the structure of a GraphQL operation using a run ID, but it does not cover fetching assets or their materialization progress. For your specific use case, you would need to construct a query that retrieves asset materialization events for a given run ID. The documentation does not provide a direct query for this, but based on the general structure of GraphQL and the available operations in the Dagster GraphQL schema, a hypothetical query might look something like this: graphql query GetAssetsForRun($runId: String!) { runOrError(runId: $runId) { __typename ... on Run { runId assetMaterializations { assetKey { path } materializationEvent { eventTime stepKey ... on Materialization { label description metadataEntries { ... on EventTextMetadataEntry { text } ... on EventJsonMetadataEntry { jsonString } ... on EventUrlMetadataEntry { url } # Include other metadata entry types as needed } } } } } ... on RunNotFoundError { runId } } }
Please note that the above query is hypothetical and may not match the exact schema provided by Dagster. You would need to refer to the actual GraphQL schema documentation or use a GraphQL playground to explore the schema and construct a valid query based on the available types and fields. If you need to find the exact query that matches your requirements, I recommend exploring the GraphQL schema documentation or using a GraphQL playground associated with your Dagster instance to discover the available queries and their fields.