Homeโ€บ๐Ÿ‘พ Boss Levelโ€บModule 141 min read ยท 15/15

Case Studies & War Stories

Reference1 exercise

Production Patterns

Polling Dashboard

const { data } = useDql({
  query: `timeseries avg(dt.host.cpu.usage), from:-30m`,
  options: { refetchInterval: 30000 }
});

Conditional Queries

const { data } = useDql({
  query: `fetch dt.entity.host | filter id == "${selectedHost}"`,
  options: { enabled: !!selectedHost }  // only run when host selected
});

Error Boundary

import { ErrorBoundary } from "react-error-boundary";

<ErrorBoundary fallback={<Text>Something went wrong</Text>}>
  <MyComponent />
</ErrorBoundary>

โš ๏ธ Always wrap DQL-dependent components in ErrorBoundary. A bad query shouldn't crash the whole app.

Layout Skeleton

// Show structure immediately, fill data as it loads
<Flex flexDirection="column" gap={16}>
  <TitleBar>...</TitleBar>
  {isLoading ? <ProgressCircle /> : <DataTable ... />}
</Flex>

Multi-Entity Comparison

const { data } = useDql({
  query: `timeseries avg(dt.host.cpu.usage),
    by:{dt.entity.host},
    filter:{ in(dt.entity.host, "${hosts.join('","')}") },
    from:-2h`
});
๐Ÿง  Quick Check

What's the biggest difference between Extensions 2.0 and Dynatrace Apps?

๐ŸŽ‰ Apps Course Complete!

You've learned to build full Dynatrace applications โ€” from DOOM to production dashboards. Key skills:

  • DQL queries with useDql
  • Strato components (DataTable, charts, layouts)
  • App functions for external APIs
  • Intents for cross-app navigation
  • Production patterns (polling, error handling, state)

๐Ÿ’ก Check the Extensions course to learn how to build the data sources that feed your apps.