-
Notifications
You must be signed in to change notification settings - Fork 11
fix: restore service list as flat list #521
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import { ChangeDetectionStrategy, Component } from '@angular/core'; | ||
import { endpointListDashboard } from './endpoint-list.dashboard'; | ||
|
||
@Component({ | ||
changeDetection: ChangeDetectionStrategy.OnPush, | ||
template: ` | ||
<div class="vertical-flex-layout"> | ||
<ht-page-header></ht-page-header> | ||
<ht-navigable-dashboard navLocation="${endpointListDashboard.location}"></ht-navigable-dashboard> | ||
</div> | ||
` | ||
}) | ||
export class EndpointListComponent {} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Have we have started calling apis as endpoints in the code as well? Would that cause confusion with existing components for API like There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's a bit mixed in code. We should get it all consistent, but figured if we're adding new stuff to make it accurate. Another change that should happen is flattening the structure of pages (removing the |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { NgModule } from '@angular/core'; | ||
import { PageHeaderModule } from '@hypertrace/components'; | ||
import { NavigableDashboardModule } from '@hypertrace/distributed-tracing'; | ||
import { ObservabilityDashboardModule } from '../../../shared/dashboard/observability-dashboard.module'; | ||
import { EndpointListComponent } from './endpoint-list.component'; | ||
import { endpointListDashboard } from './endpoint-list.dashboard'; | ||
|
||
@NgModule({ | ||
imports: [ | ||
ObservabilityDashboardModule, | ||
PageHeaderModule, | ||
NavigableDashboardModule.withDefaultDashboards(endpointListDashboard) | ||
], | ||
declarations: [EndpointListComponent] | ||
}) | ||
export class EndpointListModule {} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
import { CoreTableCellRendererType, TableSortDirection } from '@hypertrace/components'; | ||
import { DashboardDefaultConfiguration, TracingTableCellType } from '@hypertrace/distributed-tracing'; | ||
import { ObservabilityTableCellType } from '../../../shared/components/table/observability-table-cell-type'; | ||
|
||
export const serviceListDashboard: DashboardDefaultConfiguration = { | ||
location: 'SERVICE_LIST', | ||
json: { | ||
type: 'table-widget', | ||
id: 'service-list.table', | ||
searchAttribute: 'name', | ||
columns: [ | ||
{ | ||
type: 'table-widget-column', | ||
title: 'Name', | ||
display: ObservabilityTableCellType.Entity, | ||
width: '30%', | ||
value: { | ||
type: 'entity-specification' | ||
} | ||
}, | ||
{ | ||
type: 'table-widget-column', | ||
title: 'p99 Latency', | ||
display: TracingTableCellType.Metric, | ||
value: { | ||
type: 'metric-aggregation', | ||
metric: 'duration', | ||
aggregation: 'p99' | ||
}, | ||
sort: TableSortDirection.Descending | ||
}, | ||
{ | ||
type: 'table-widget-column', | ||
title: 'Avg Latency', | ||
display: TracingTableCellType.Metric, | ||
value: { | ||
type: 'metric-aggregation', | ||
metric: 'duration', | ||
aggregation: 'avg' | ||
} | ||
}, | ||
{ | ||
type: 'table-widget-column', | ||
title: 'Errors/s', | ||
display: CoreTableCellRendererType.Number, | ||
value: { | ||
type: 'metric-aggregation', | ||
metric: 'errorCount', | ||
aggregation: 'avgrate_sec' | ||
} | ||
}, | ||
{ | ||
type: 'table-widget-column', | ||
title: 'Errors', | ||
display: CoreTableCellRendererType.Number, | ||
value: { | ||
type: 'metric-aggregation', | ||
metric: 'errorCount', | ||
aggregation: 'sum' | ||
} | ||
}, | ||
{ | ||
type: 'table-widget-column', | ||
title: 'Calls/s', | ||
display: CoreTableCellRendererType.Number, | ||
value: { | ||
type: 'metric-aggregation', | ||
metric: 'numCalls', | ||
aggregation: 'avgrate_sec' | ||
} | ||
}, | ||
{ | ||
type: 'table-widget-column', | ||
title: 'Calls', | ||
display: CoreTableCellRendererType.Number, | ||
value: { | ||
type: 'metric-aggregation', | ||
metric: 'numCalls', | ||
aggregation: 'sum' | ||
} | ||
} | ||
], | ||
data: { | ||
type: 'entity-table-data-source', | ||
entity: 'SERVICE' | ||
} | ||
} | ||
}; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import { NgModule } from '@angular/core'; | ||
import { RouterModule } from '@angular/router'; | ||
import { TraceRoute } from '@hypertrace/common'; | ||
import { | ||
ApiDetailBreadcrumbResolver, | ||
ApiDetailService, | ||
EndpointListComponent, | ||
EndpointListModule | ||
} from '@hypertrace/observability'; | ||
|
||
const ROUTE_CONFIG: TraceRoute[] = [ | ||
{ | ||
path: '', | ||
component: EndpointListComponent | ||
}, | ||
{ | ||
path: `endpoint/:${ApiDetailService.API_ID_PARAM_NAME}`, | ||
resolve: { | ||
breadcrumb: ApiDetailBreadcrumbResolver | ||
}, | ||
loadChildren: () => import('../api-detail/api-detail-routing.module').then(module => module.ApiDetailRoutingModule) | ||
} | ||
]; | ||
|
||
@NgModule({ | ||
imports: [RouterModule.forChild(ROUTE_CONFIG), EndpointListModule] | ||
}) | ||
export class EndpointRoutingModule {} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ | |
|
||
export const environment = { | ||
production: false, | ||
graphqlUri: 'http://localhost:2020/graphql' | ||
graphqlUri: 'http://localhost:23431/graphql' | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this a new port? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it should be 2020 only right? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yeah my bad. this is the HT graphql port (23431) but usually devs are running against a full cluster which puts everything behind 2020. |
||
}; | ||
|
||
/* | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this isn't really part of this change, but noticed it in the UX for this page.