The only tool you need to know what is happening and how to fix it.
Go alertingexception-trackerissue-trackinglogsmetricsmonitoringobservability-platformopen-telemetryotelsession-replaytelemetrytraces
context -> attributes rename
dduxf19db3369aa2
diff --git a/frontend/src/lib/components/issues/event-card.svelte b/frontend/src/lib/components/issues/event-card.svelteindex c5df812b..7026ea3a 100644--- a/frontend/src/lib/components/issues/event-card.svelte+++ b/frontend/src/lib/components/issues/event-card.svelte@@ -1,114 +1,123 @@<script lang="ts">- import { goto } from '$app/navigation';- import { Button } from "$lib/components/ui/button";- import * as Card from "$lib/components/ui/card";- import { ArrowRight } from "lucide-svelte";- import type { ExceptionOccurrence, LinkedTrace } from '$lib/types/exceptions';- import { formatDuration, getStatusColor, formatDateTime } from '$lib/utils/formatters';- import { getTimezone } from '$lib/state/timezone.svelte';- import { ContextGrid } from '$lib/components/ui/context-grid';+ import { goto } from '$app/navigation';+ import { Button } from '$lib/components/ui/button';+ import * as Card from '$lib/components/ui/card';+ import { ArrowRight } from 'lucide-svelte';+ import type { ExceptionOccurrence, LinkedTrace } from '$lib/types/exceptions';+ import { formatDuration, getStatusColor, formatDateTime } from '$lib/utils/formatters';+ import { getTimezone } from '$lib/state/timezone.svelte';+ import { ContextGrid } from '$lib/components/ui/context-grid';import { LabelValue } from '../ui/label-value';- interface Props {- occurrence: ExceptionOccurrence;- linkedTrace: LinkedTrace | null;- title?: string;- description?: string;- timezone?: string;- }+ interface Props {+ occurrence: ExceptionOccurrence;+ linkedTrace: LinkedTrace | null;+ title?: string;+ description?: string;+ timezone?: string;+ }- let {- occurrence,- linkedTrace,- title = "Event",- description = "Details for this specific occurrence",- timezone- }: Props = $props();+ let {+ occurrence,+ linkedTrace,+ title = 'Event',+ description = 'Details for this specific occurrence',+ timezone+ }: Props = $props();- const tz = $derived(timezone ?? getTimezone());+ const tz = $derived(timezone ?? getTimezone());</script><Card.Root>- <Card.Header>- <Card.Title>{title}</Card.Title>- <Card.Description>{description}</Card.Description>- </Card.Header>- <Card.Content class="space-y-6">- <!-- Event Details -->- <div class="grid grid-cols-2 gap-4 md:grid-cols-4">- <div class="space-y-1">- <p class="text-sm text-muted-foreground">Recorded At</p>- <p class="font-mono text-sm">{formatDateTime(occurrence.recordedAt, { timezone: tz })}</p>- </div>- <div class="space-y-1">- <p class="text-sm text-muted-foreground">Server</p>- <p class="font-mono text-sm">{occurrence.serverName || '-'}</p>- </div>- <div class="space-y-1">- <p class="text-sm text-muted-foreground">Version</p>- <p class="font-mono text-sm">{occurrence.appVersion || '-'}</p>- </div>- <div class="space-y-1">- <p class="text-sm text-muted-foreground">Trace</p>- <p class="font-mono text-sm">{occurrence.traceId || '-'}</p>- </div>- </div>+ <Card.Header>+ <Card.Title>{title}</Card.Title>+ <Card.Description>{description}</Card.Description>+ </Card.Header>+ <Card.Content class="space-y-6">+ <!-- Event Details -->+ <div class="grid grid-cols-2 gap-4 md:grid-cols-4">+ <div class="space-y-1">+ <p class="text-sm text-muted-foreground">Recorded At</p>+ <p class="font-mono text-sm">{formatDateTime(occurrence.recordedAt, { timezone: tz })}</p>+ </div>+ <div class="space-y-1">+ <p class="text-sm text-muted-foreground">Server</p>+ <p class="font-mono text-sm">{occurrence.serverName || '-'}</p>+ </div>+ <div class="space-y-1">+ <p class="text-sm text-muted-foreground">Version</p>+ <p class="font-mono text-sm">{occurrence.appVersion || '-'}</p>+ </div>+ <div class="space-y-1">+ <p class="text-sm text-muted-foreground">Trace</p>+ <p class="font-mono text-sm">{occurrence.traceId || '-'}</p>+ </div>+ </div>- <!-- Context -->- {#if occurrence.attributes && Object.keys(occurrence.attributes).length > 0}- <hr class="border-border" />- <div>- <p class="text-sm font-medium mb-3">Context</p>- <ContextGrid attributes={occurrence.attributes} />- </div>- {/if}+ <!-- Context -->+ {#if occurrence.attributes && Object.keys(occurrence.attributes).length > 0}+ <hr class="border-border" />+ <div>+ <p class="mb-3 text-sm font-medium">Attributes</p>+ <ContextGrid attributes={occurrence.attributes} />+ </div>+ {/if}- <!-- Related Trace -->- {#if linkedTrace}- <hr class="border-border" />- <div>- <p class="text-sm font-medium mb-3">- {linkedTrace.traceType === 'task' ? 'Related Task' : 'Related Endpoint'}- </p>- <div class="grid grid-cols-2 gap-4 md:grid-cols-4 mb-4">- <LabelValue- label={linkedTrace.traceType === 'task' ? 'Task' : 'Endpoint'}- value={linkedTrace.endpoint}- mono- />- {#if linkedTrace.traceType !== 'task'}- <LabelValue- label="Status"- value={linkedTrace.statusCode}- mono- large- valueClass={getStatusColor(linkedTrace.statusCode)}- />- {/if}- <LabelValue- label="Duration"- value={formatDuration(linkedTrace.duration)}- mono- large- />- <LabelValue- label="Recorded At"- value={formatDateTime(linkedTrace.recordedAt, { timezone })}- mono- />- </div>- {#if linkedTrace.traceType === 'task'}- <Button variant="outline" size="sm" onclick={() => goto(`/tasks/${encodeURIComponent(linkedTrace.endpoint)}/${linkedTrace.id}?preset=24h`)}>- View Task Details- <ArrowRight class="ml-2 h-4 w-4" />- </Button>- {:else}- <Button variant="outline" size="sm" onclick={() => goto(`/endpoints/${encodeURIComponent(linkedTrace.endpoint)}/${linkedTrace.id}?preset=24h`)}>- View Endpoint Details- <ArrowRight class="ml-2 h-4 w-4" />- </Button>- {/if}- </div>- {/if}- </Card.Content>+ <!-- Related Trace -->+ {#if linkedTrace}+ <hr class="border-border" />+ <div>+ <p class="mb-3 text-sm font-medium">+ {linkedTrace.traceType === 'task' ? 'Related Task' : 'Related Endpoint'}+ </p>+ <div class="mb-4 grid grid-cols-2 gap-4 md:grid-cols-4">+ <LabelValue+ label={linkedTrace.traceType === 'task' ? 'Task' : 'Endpoint'}+ value={linkedTrace.endpoint}+ mono+ />+ {#if linkedTrace.traceType !== 'task'}+ <LabelValue+ label="Status"+ value={linkedTrace.statusCode}+ mono+ large+ valueClass={getStatusColor(linkedTrace.statusCode)}+ />+ {/if}+ <LabelValue label="Duration" value={formatDuration(linkedTrace.duration)} mono large />+ <LabelValue+ label="Recorded At"+ value={formatDateTime(linkedTrace.recordedAt, { timezone })}+ mono+ />+ </div>+ {#if linkedTrace.traceType === 'task'}+ <Button+ variant="outline"+ size="sm"+ onclick={() =>+ goto(+ `/tasks/${encodeURIComponent(linkedTrace.endpoint)}/${linkedTrace.id}?preset=24h`+ )}+ >+ View Task Details+ <ArrowRight class="ml-2 h-4 w-4" />+ </Button>+ {:else}+ <Button+ variant="outline"+ size="sm"+ onclick={() =>+ goto(+ `/endpoints/${encodeURIComponent(linkedTrace.endpoint)}/${linkedTrace.id}?preset=24h`+ )}+ >+ View Endpoint Details+ <ArrowRight class="ml-2 h-4 w-4" />+ </Button>+ {/if}+ </div>+ {/if}+ </Card.Content></Card.Root>diff --git a/frontend/src/routes/endpoints/[endpoint]/[endpointId]/+page.svelte b/frontend/src/routes/endpoints/[endpoint]/[endpointId]/+page.svelteindex 6e3746bd..b5e87850 100644--- a/frontend/src/routes/endpoints/[endpoint]/[endpointId]/+page.svelte+++ b/frontend/src/routes/endpoints/[endpoint]/[endpointId]/+page.svelte@@ -71,9 +71,14 @@<div class="space-y-6"><PageHeader- title={decodeURIComponent(data.endpoint)} subtitle={`Endpoint ID: ${data.endpointId}`}- onBack={createSmartBackHandler({ fallbackPath: resolve('/endpoints/[endpoint]', {endpoint: encodeURIComponent(data.endpoint)}) })} />-+ title={decodeURIComponent(data.endpoint)}+ subtitle={`Endpoint ID: ${data.endpointId}`}+ onBack={createSmartBackHandler({+ fallbackPath: resolve('/endpoints/[endpoint]', {+ endpoint: encodeURIComponent(data.endpoint)+ })+ })}+ />{#if loading}<div class="flex items-center justify-center py-20">@@ -84,7 +89,11 @@status={404}title="Endpoint Not Found"description="The endpoint instance you're looking for doesn't exist or may have expired."- onBack={createSmartBackHandler({ fallbackPath: resolve('/endpoints/[endpoint]', {endpoint: encodeURIComponent(data.endpoint)}) })}+ onBack={createSmartBackHandler({+ fallbackPath: resolve('/endpoints/[endpoint]', {+ endpoint: encodeURIComponent(data.endpoint)+ })+ })}backLabel="Back to Endpoint"onRetry={loadData}identifier={data.endpointId}@@ -94,7 +103,11 @@status={400}title="Failed to Load Endpoint"description={error}- onBack={createSmartBackHandler({ fallbackPath: resolve('/endpoints/[endpoint]', {endpoint: encodeURIComponent(data.endpoint)}) })}+ onBack={createSmartBackHandler({+ fallbackPath: resolve('/endpoints/[endpoint]', {+ endpoint: encodeURIComponent(data.endpoint)+ })+ })}backLabel="Back to Endpoint"onRetry={loadData}/>@@ -107,11 +120,7 @@</Card.Header><Card.Content class="space-y-6"><div class="grid grid-cols-2 gap-4 md:grid-cols-4">- <LabelValue- label="Endpoint"- value={decodeURIComponent(data.endpoint)}- mono- />+ <LabelValue label="Endpoint" value={decodeURIComponent(data.endpoint)} mono /><LabelValuelabel="Status"value={response.endpoint.statusCode}@@ -130,32 +139,16 @@value={formatDateTime(response.endpoint.recordedAt, { timezone })}mono/>- <LabelValue- label="Server"- value={response.endpoint.serverName}- mono- />- <LabelValue- label="Version"- value={response.endpoint.appVersion || '-'}- mono- />- <LabelValue- label="Client IP"- value={response.endpoint.clientIP}- mono- />- <LabelValue- label="Body Size"- value={formatBytes(response.endpoint.bodySize)}- mono- />+ <LabelValue label="Server" value={response.endpoint.serverName} mono />+ <LabelValue label="Version" value={response.endpoint.appVersion || '-'} mono />+ <LabelValue label="Client IP" value={response.endpoint.clientIP} mono />+ <LabelValue label="Body Size" value={formatBytes(response.endpoint.bodySize)} mono /></div>{#if response.endpoint.attributes && Object.keys(response.endpoint.attributes).length > 0}<hr class="border-border" /><div>- <p class="mb-3 text-sm font-medium">Context</p>+ <p class="mb-3 text-sm font-medium">Attributes</p><ContextGrid attributes={response.endpoint.attributes} /></div>{/if}@@ -202,7 +195,8 @@<Card.Title>Messages</Card.Title></div><Card.Description>- {response.messages.length} message{response.messages.length === 1 ? '' : 's'} logged during this request+ {response.messages.length} message{response.messages.length === 1 ? '' : 's'} logged during+ this request</Card.Description></Card.Header><Card.Content class="px-0 pb-0">@@ -231,7 +225,10 @@<Table.Cell class="pr-6">{#if message.attributes && Object.keys(message.attributes).length > 0}<span class="text-xs text-muted-foreground">- {Object.keys(message.attributes).length} key{Object.keys(message.attributes).length === 1 ? '' : 's'}+ {Object.keys(message.attributes).length} key{Object.keys(message.attributes)+ .length === 1+ ? ''+ : 's'}</span>{:else}<span class="text-xs text-muted-foreground">-</span>diff --git a/frontend/src/routes/tasks/[task]/[taskId]/+page.svelte b/frontend/src/routes/tasks/[task]/[taskId]/+page.svelteindex 82d1d143..2936a82d 100644--- a/frontend/src/routes/tasks/[task]/[taskId]/+page.svelte+++ b/frontend/src/routes/tasks/[task]/[taskId]/+page.svelte@@ -86,9 +86,12 @@<div class="space-y-6"><PageHeader- title={decodeURIComponent(data.task)} subtitle={`Task ID: ${data.taskId}`}- onBack={createSmartBackHandler({ fallbackPath: resolve('/tasks/[task]', {task: encodeURIComponent(data.task)}) })} />-+ title={decodeURIComponent(data.task)}+ subtitle={`Task ID: ${data.taskId}`}+ onBack={createSmartBackHandler({+ fallbackPath: resolve('/tasks/[task]', { task: encodeURIComponent(data.task) })+ })}+ />{#if loading}<div class="flex items-center justify-center py-20">@@ -99,7 +102,9 @@status={404}title="Task Not Found"description="The task instance you're looking for doesn't exist or may have expired."- onBack={createSmartBackHandler({ fallbackPath: resolve('/tasks/[task]', {task: encodeURIComponent(data.task)}) })}+ onBack={createSmartBackHandler({+ fallbackPath: resolve('/tasks/[task]', { task: encodeURIComponent(data.task) })+ })}backLabel="Back to Task"onRetry={loadData}identifier={data.taskId}@@ -109,7 +114,9 @@status={400}title="Failed to Load Task"description={error}- onBack={createSmartBackHandler({ fallbackPath: resolve('/tasks/[task]', {task: encodeURIComponent(data.task)}) })}+ onBack={createSmartBackHandler({+ fallbackPath: resolve('/tasks/[task]', { task: encodeURIComponent(data.task) })+ })}backLabel="Back to Task"onRetry={loadData}/>@@ -122,38 +129,21 @@</Card.Header><Card.Content class="space-y-6"><div class="grid grid-cols-2 gap-4 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-5">- <LabelValue- label="Task"- value={decodeURIComponent(data.task)}- mono- />- <LabelValue- label="Duration"- value={formatDuration(response.task.duration)}- mono- large- />+ <LabelValue label="Task" value={decodeURIComponent(data.task)} mono />+ <LabelValue label="Duration" value={formatDuration(response.task.duration)} mono large /><LabelValuelabel="Recorded At"value={formatDateTime(response.task.recordedAt, { timezone })}mono/>- <LabelValue- label="Server"- value={response.task.serverName}- mono- />- <LabelValue- label="Version"- value={response.task.appVersion || '-'}- mono- />+ <LabelValue label="Server" value={response.task.serverName} mono />+ <LabelValue label="Version" value={response.task.appVersion || '-'} mono /></div>{#if response.task.attributes && Object.keys(response.task.attributes).length > 0}<hr class="border-border" /><div>- <p class="mb-3 text-sm font-medium">Context</p>+ <p class="mb-3 text-sm font-medium">Attributes</p><ContextGrid attributes={response.task.attributes} /></div>{/if}@@ -200,7 +190,8 @@<Card.Title>Messages</Card.Title></div><Card.Description>- {response.messages.length} message{response.messages.length === 1 ? '' : 's'} logged during this task+ {response.messages.length} message{response.messages.length === 1 ? '' : 's'} logged during+ this task</Card.Description></Card.Header><Card.Content class="px-0 pb-0">@@ -229,7 +220,10 @@<Table.Cell class="pr-6">{#if message.attributes && Object.keys(message.attributes).length > 0}<span class="text-xs text-muted-foreground">- {Object.keys(message.attributes).length} key{Object.keys(message.attributes).length === 1 ? '' : 's'}+ {Object.keys(message.attributes).length} key{Object.keys(message.attributes)+ .length === 1+ ? ''+ : 's'}</span>{:else}<span class="text-xs text-muted-foreground">-</span>