mirror of
https://github.com/SigNoz/signoz.git
synced 2026-05-22 18:00:25 +01:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c73f5aad16 | ||
|
|
88620b567e | ||
|
|
27dc996fd8 | ||
|
|
83b25f3e9a | ||
|
|
67e4c4611c |
@@ -3,6 +3,7 @@ package main
|
||||
import (
|
||||
"context"
|
||||
"log/slog"
|
||||
"net/url"
|
||||
|
||||
"github.com/spf13/cobra"
|
||||
|
||||
@@ -118,8 +119,8 @@ func runServer(ctx context.Context, config signoz.Config, logger *slog.Logger) e
|
||||
func(_ sqlstore.SQLStore, _ global.Global, _ zeus.Zeus, _ gateway.Gateway, _ licensing.Licensing, _ serviceaccount.Module, _ cloudintegration.Config) (cloudintegration.Module, error) {
|
||||
return implcloudintegration.NewModule(), nil
|
||||
},
|
||||
func(c cache.Cache, am alertmanager.Alertmanager, ss sqlstore.SQLStore, ts telemetrystore.TelemetryStore, ms telemetrytypes.MetadataStore, p prometheus.Prometheus, og organization.Getter, rsh rulestatehistory.Module, q querier.Querier, qp queryparser.QueryParser) factory.NamedMap[factory.ProviderFactory[ruler.Ruler, ruler.Config]] {
|
||||
return factory.MustNewNamedMap(signozruler.NewFactory(c, am, ss, ts, ms, p, og, rsh, q, qp, nil, nil))
|
||||
func(c cache.Cache, am alertmanager.Alertmanager, ss sqlstore.SQLStore, ts telemetrystore.TelemetryStore, ms telemetrytypes.MetadataStore, p prometheus.Prometheus, og organization.Getter, rsh rulestatehistory.Module, q querier.Querier, qp queryparser.QueryParser, externalURL *url.URL) factory.NamedMap[factory.ProviderFactory[ruler.Ruler, ruler.Config]] {
|
||||
return factory.MustNewNamedMap(signozruler.NewFactory(c, am, ss, ts, ms, p, og, rsh, q, qp, externalURL, nil, nil))
|
||||
},
|
||||
)
|
||||
if err != nil {
|
||||
|
||||
@@ -3,6 +3,7 @@ package main
|
||||
import (
|
||||
"context"
|
||||
"log/slog"
|
||||
"net/url"
|
||||
"time"
|
||||
|
||||
"github.com/spf13/cobra"
|
||||
@@ -181,8 +182,8 @@ func runServer(ctx context.Context, config signoz.Config, logger *slog.Logger) e
|
||||
|
||||
return implcloudintegration.NewModule(pkgcloudintegration.NewStore(sqlStore), global, zeus, gateway, licensing, serviceAccount, cloudProvidersMap, config)
|
||||
},
|
||||
func(c cache.Cache, am alertmanager.Alertmanager, ss sqlstore.SQLStore, ts telemetrystore.TelemetryStore, ms telemetrytypes.MetadataStore, p prometheus.Prometheus, og organization.Getter, rsh rulestatehistory.Module, q querier.Querier, qp queryparser.QueryParser) factory.NamedMap[factory.ProviderFactory[ruler.Ruler, ruler.Config]] {
|
||||
return factory.MustNewNamedMap(signozruler.NewFactory(c, am, ss, ts, ms, p, og, rsh, q, qp, eerules.PrepareTaskFunc, eerules.TestNotification))
|
||||
func(c cache.Cache, am alertmanager.Alertmanager, ss sqlstore.SQLStore, ts telemetrystore.TelemetryStore, ms telemetrytypes.MetadataStore, p prometheus.Prometheus, og organization.Getter, rsh rulestatehistory.Module, q querier.Querier, qp queryparser.QueryParser, externalURL *url.URL) factory.NamedMap[factory.ProviderFactory[ruler.Ruler, ruler.Config]] {
|
||||
return factory.MustNewNamedMap(signozruler.NewFactory(c, am, ss, ts, ms, p, og, rsh, q, qp, externalURL, eerules.PrepareTaskFunc, eerules.TestNotification))
|
||||
},
|
||||
)
|
||||
if err != nil {
|
||||
|
||||
@@ -39,6 +39,7 @@ func PrepareTaskFunc(opts baserules.PrepareTaskOptions) (baserules.Task, error)
|
||||
baserules.WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
baserules.WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
baserules.WithRuleStateHistoryModule(opts.ManagerOpts.RuleStateHistoryModule),
|
||||
baserules.WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
@@ -63,6 +64,7 @@ func PrepareTaskFunc(opts baserules.PrepareTaskOptions) (baserules.Task, error)
|
||||
baserules.WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
baserules.WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
baserules.WithRuleStateHistoryModule(opts.ManagerOpts.RuleStateHistoryModule),
|
||||
baserules.WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
@@ -87,6 +89,7 @@ func PrepareTaskFunc(opts baserules.PrepareTaskOptions) (baserules.Task, error)
|
||||
baserules.WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
baserules.WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
baserules.WithRuleStateHistoryModule(opts.ManagerOpts.RuleStateHistoryModule),
|
||||
baserules.WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
if err != nil {
|
||||
return task, err
|
||||
@@ -146,6 +149,7 @@ func TestNotification(opts baserules.PrepareTestRuleOptions) (int, error) {
|
||||
baserules.WithSQLStore(opts.SQLStore),
|
||||
baserules.WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
baserules.WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
baserules.WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
@@ -167,6 +171,7 @@ func TestNotification(opts baserules.PrepareTestRuleOptions) (int, error) {
|
||||
baserules.WithSQLStore(opts.SQLStore),
|
||||
baserules.WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
baserules.WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
baserules.WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
@@ -186,6 +191,7 @@ func TestNotification(opts baserules.PrepareTestRuleOptions) (int, error) {
|
||||
baserules.WithSQLStore(opts.SQLStore),
|
||||
baserules.WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
baserules.WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
baserules.WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
if err != nil {
|
||||
slog.Error("failed to prepare a new anomaly rule for test", "name", alertname, errors.Attr(err))
|
||||
|
||||
@@ -14,7 +14,9 @@
|
||||
*/
|
||||
|
||||
const BANNED_COMPONENTS = {
|
||||
Typography: 'Use @signozhq/ui Typography instead of antd Typography.',
|
||||
Typography:
|
||||
'Use @signozhq/ui/typography Typography instead of antd Typography.',
|
||||
Switch: 'Use @signozhq/ui/switch Switch instead of antd Switch.',
|
||||
Badge: 'Use @signozhq/ui/badge instead of antd Badge.',
|
||||
};
|
||||
|
||||
|
||||
@@ -4,7 +4,8 @@ import { useSelector } from 'react-redux';
|
||||
import { matchPath, useLocation } from 'react-router-dom';
|
||||
import { useCopyToClipboard } from 'react-use';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Button, Switch } from 'antd';
|
||||
import { Button } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import logEvent from 'api/common/logEvent';
|
||||
import { QueryParams } from 'constants/query';
|
||||
@@ -125,9 +126,8 @@ function ShareURLModal(): JSX.Element {
|
||||
<Info size={14} color={Color.BG_AMBER_600} />
|
||||
)}
|
||||
<Switch
|
||||
checked={enableAbsoluteTime}
|
||||
value={enableAbsoluteTime}
|
||||
disabled={!isValidateRelativeTime}
|
||||
size="small"
|
||||
onChange={(): void => {
|
||||
setEnableAbsoluteTime((prev) => !prev);
|
||||
}}
|
||||
|
||||
@@ -14,7 +14,8 @@ import {
|
||||
ComboboxList,
|
||||
ComboboxTrigger,
|
||||
} from '@signozhq/ui/combobox';
|
||||
import { Skeleton, Switch, Tooltip } from 'antd';
|
||||
import { Skeleton, Tooltip } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import getLocalStorageKey from 'api/browser/localstorage/get';
|
||||
import setLocalStorageKey from 'api/browser/localstorage/set';
|
||||
@@ -281,9 +282,8 @@ export default function QuickFilters(props: IQuickFiltersProps): JSX.Element {
|
||||
<div className="api-quick-filters-header">
|
||||
<Typography.Text>Show IP addresses</Typography.Text>
|
||||
<Switch
|
||||
size="small"
|
||||
style={{ marginLeft: 'auto' }}
|
||||
checked={showIP ?? true}
|
||||
value={showIP ?? true}
|
||||
onChange={(checked): void => {
|
||||
logEvent('API Monitoring: Show IP addresses clicked', {
|
||||
showIP: checked,
|
||||
|
||||
@@ -4,7 +4,8 @@ import type {
|
||||
TableColumnsType as ColumnsType,
|
||||
TableColumnType as ColumnType,
|
||||
} from 'antd';
|
||||
import { Button, Dropdown, Flex, MenuProps, Switch } from 'antd';
|
||||
import { Button, Dropdown, Flex, MenuProps } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import logEvent from 'api/common/logEvent';
|
||||
import LaunchChatSupport from 'components/LaunchChatSupport/LaunchChatSupport';
|
||||
import { useSafeNavigate } from 'hooks/useSafeNavigate';
|
||||
@@ -60,9 +61,7 @@ function DynamicColumnTable({
|
||||
|
||||
const onToggleHandler =
|
||||
(index: number, column: ColumnGroupType<any> | ColumnType<any>) =>
|
||||
(checked: boolean, event: React.MouseEvent<HTMLButtonElement>): void => {
|
||||
event.stopPropagation();
|
||||
|
||||
(checked: boolean): void => {
|
||||
if (shouldSendAlertsLogEvent) {
|
||||
logEvent('Alert: Column toggled', {
|
||||
column: column?.title,
|
||||
@@ -88,10 +87,14 @@ function DynamicColumnTable({
|
||||
const items: MenuProps['items'] =
|
||||
dynamicColumns?.map((column, index) => ({
|
||||
label: (
|
||||
<div className="dynamicColumnsTable-items">
|
||||
<div
|
||||
className="dynamicColumnsTable-items"
|
||||
onClick={(e): void => e.stopPropagation()}
|
||||
role="presentation"
|
||||
>
|
||||
<div>{column.title?.toString()}</div>
|
||||
<Switch
|
||||
checked={columnsData?.findIndex((c) => c.key === column.key) !== -1}
|
||||
value={columnsData?.findIndex((c) => c.key === column.key) !== -1}
|
||||
onChange={onToggleHandler(index, column)}
|
||||
/>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import { useMemo, useState } from 'react';
|
||||
import { QueryFunctionContext, useQueries, useQuery } from 'react-query';
|
||||
import { Spin, Switch, Table, Tooltip } from 'antd';
|
||||
import { Spin, Table, Tooltip } from 'antd';
|
||||
import { Info, Loader } from '@signozhq/icons';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import { getQueryRangeV5 } from 'api/v5/queryRange/getQueryRange';
|
||||
import { MetricRangePayloadV5, ScalarData } from 'api/v5/v5';
|
||||
@@ -170,11 +171,7 @@ function TopErrors({
|
||||
/>
|
||||
</div>
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: '8px' }}>
|
||||
<Switch
|
||||
checked={showStatusCodeErrors}
|
||||
onChange={setShowStatusCodeErrors}
|
||||
size="small"
|
||||
/>
|
||||
<Switch value={showStatusCodeErrors} onChange={setShowStatusCodeErrors} />
|
||||
<span style={{ color: 'white', fontSize: '14px' }}>
|
||||
Status Message Exists
|
||||
</span>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import { Button, Flex, SelectProps, Switch } from 'antd';
|
||||
import { Button, Flex, SelectProps } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import type { BaseOptionType, DefaultOptionType } from 'antd/es/select';
|
||||
import { getInvolvedQueriesInTraceOperator } from 'components/QueryBuilderV2/QueryV2/TraceOperator/utils/utils';
|
||||
@@ -419,8 +420,8 @@ export function RoutingPolicyBanner({
|
||||
</Typography.Text>
|
||||
<div className="routing-policies-info-banner-right">
|
||||
<Switch
|
||||
checked={notificationSettings.routingPolicies}
|
||||
data-testid="routing-policies-switch"
|
||||
value={notificationSettings.routingPolicies}
|
||||
testId="routing-policies-switch"
|
||||
onChange={(value): void => {
|
||||
setNotificationSettings({
|
||||
type: 'SET_ROUTING_POLICIES',
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { useEffect, useState } from 'react';
|
||||
import { Switch, Tooltip } from 'antd';
|
||||
import { Tooltip } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import { Info } from '@signozhq/icons';
|
||||
|
||||
@@ -49,7 +50,7 @@ function AdvancedOptionItem({
|
||||
>
|
||||
{input}
|
||||
</div>
|
||||
<Switch onChange={handleOnToggle} checked={showInput} />
|
||||
<Switch onChange={handleOnToggle} value={showInput} />
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -5,7 +5,8 @@ import { useQuery } from 'react-query';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { orange } from '@ant-design/colors';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Button, Collapse, Input, Select, Switch, Tag } from 'antd';
|
||||
import { Button, Collapse, Input, Select, Tag } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import dashboardVariablesQuery from 'api/dashboard/variables/dashboardVariablesQuery';
|
||||
import cx from 'classnames';
|
||||
@@ -763,7 +764,7 @@ function VariableItem({
|
||||
</Typography>
|
||||
</LabelContainer>
|
||||
<Switch
|
||||
checked={variableMultiSelect}
|
||||
value={variableMultiSelect}
|
||||
onChange={(e): void => {
|
||||
setVariableMultiSelect(e);
|
||||
if (!e) {
|
||||
@@ -780,7 +781,7 @@ function VariableItem({
|
||||
</Typography>
|
||||
</LabelContainer>
|
||||
<Switch
|
||||
checked={variableShowALLOption}
|
||||
value={variableShowALLOption}
|
||||
onChange={(e): void => setVariableShowALLOption(e)}
|
||||
/>
|
||||
</VariableItemRow>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { Dispatch, ReactElement, SetStateAction } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Form, FormInstance, Input, Select, Switch } from 'antd';
|
||||
import { Form, FormInstance, Input, Select } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import type { Store } from 'antd/lib/form/interface';
|
||||
import ROUTES from 'constants/routes';
|
||||
@@ -82,8 +83,8 @@ function FormAlertChannels({
|
||||
name="send_resolved"
|
||||
>
|
||||
<Switch
|
||||
defaultChecked={initialValue?.send_resolved}
|
||||
data-testid="field-send-resolved-checkbox"
|
||||
defaultValue={initialValue?.send_resolved}
|
||||
testId="field-send-resolved-checkbox"
|
||||
onChange={(value): void => {
|
||||
setSelectedConfig((state) => ({
|
||||
...state,
|
||||
|
||||
@@ -2,7 +2,8 @@ import { useCallback, useEffect, useRef, useState } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { useQuery } from 'react-query';
|
||||
import { Plus } from '@signozhq/icons';
|
||||
import { Button, Flex, Form, Select, Switch, Tooltip } from 'antd';
|
||||
import { Button, Flex, Form, Select, Tooltip } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import getAll from 'api/channels/getAll';
|
||||
import logEvent from 'api/common/logEvent';
|
||||
import { ALERTS_DATA_SOURCE_MAP } from 'constants/alerts';
|
||||
@@ -198,10 +199,10 @@ function BasicInfo({
|
||||
placement="right"
|
||||
>
|
||||
<Switch
|
||||
checked={shouldBroadCastToAllChannels}
|
||||
value={shouldBroadCastToAllChannels}
|
||||
onChange={handleBroadcastToAllChannels}
|
||||
disabled={noChannels || !!isLoading}
|
||||
data-testid="alert-broadcast-to-all-channels"
|
||||
testId="alert-broadcast-to-all-channels"
|
||||
/>
|
||||
</Tooltip>
|
||||
</FormItemMedium>
|
||||
|
||||
@@ -15,13 +15,13 @@ import {
|
||||
Modal,
|
||||
Row,
|
||||
Select,
|
||||
Switch,
|
||||
Table,
|
||||
TablePaginationConfig,
|
||||
TableProps as AntDTableProps,
|
||||
Tag,
|
||||
Tooltip,
|
||||
} from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import type { NotificationInstance } from 'antd/es/notification/interface';
|
||||
import type { CollapseProps } from 'antd/lib';
|
||||
@@ -1180,8 +1180,7 @@ function MultiIngestionSettings(): JSX.Element {
|
||||
<div className="limit-enable-disable-toggle">
|
||||
<Form.Item name="enableDailyLimit">
|
||||
<Switch
|
||||
size="small"
|
||||
checked={activeSignal?.config?.day?.enabled}
|
||||
value={activeSignal?.config?.day?.enabled}
|
||||
onChange={(value): void => {
|
||||
setActiveSignal((prev) =>
|
||||
prev
|
||||
@@ -1270,8 +1269,7 @@ function MultiIngestionSettings(): JSX.Element {
|
||||
<div className="limit-enable-disable-toggle">
|
||||
<Form.Item name="enableSecondLimit">
|
||||
<Switch
|
||||
size="small"
|
||||
checked={activeSignal?.config?.second?.enabled}
|
||||
value={activeSignal?.config?.second?.enabled}
|
||||
onChange={(value): void => {
|
||||
setActiveSignal((prev) =>
|
||||
prev
|
||||
|
||||
@@ -21,11 +21,11 @@ import {
|
||||
Modal,
|
||||
Popover,
|
||||
Skeleton,
|
||||
Switch,
|
||||
Table,
|
||||
Tag,
|
||||
Tooltip,
|
||||
} from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import type { TableProps } from 'antd/lib';
|
||||
import getLocalStorageKey from 'api/browser/localstorage/get';
|
||||
@@ -965,8 +965,7 @@ function DashboardsList(): JSX.Element {
|
||||
<div className="connection-line" />
|
||||
<div className="right">
|
||||
<Switch
|
||||
size="small"
|
||||
checked
|
||||
value
|
||||
disabled
|
||||
onChange={(check): void =>
|
||||
setVisibleColumns((prev) => ({
|
||||
@@ -985,9 +984,8 @@ function DashboardsList(): JSX.Element {
|
||||
<div className="connection-line" />
|
||||
<div className="right">
|
||||
<Switch
|
||||
size="small"
|
||||
disabled
|
||||
checked
|
||||
value
|
||||
onChange={(check): void =>
|
||||
setVisibleColumns((prev) => ({
|
||||
...prev,
|
||||
@@ -1005,8 +1003,7 @@ function DashboardsList(): JSX.Element {
|
||||
<div className="connection-line" />
|
||||
<div className="right">
|
||||
<Switch
|
||||
size="small"
|
||||
checked={visibleColumns.updatedAt}
|
||||
value={visibleColumns.updatedAt}
|
||||
onChange={(check): void =>
|
||||
setVisibleColumns((prev) => ({
|
||||
...prev,
|
||||
@@ -1024,8 +1021,7 @@ function DashboardsList(): JSX.Element {
|
||||
<div className="connection-line" />
|
||||
<div className="right">
|
||||
<Switch
|
||||
size="small"
|
||||
checked={visibleColumns.updatedBy}
|
||||
value={visibleColumns.updatedBy}
|
||||
onChange={(check): void =>
|
||||
setVisibleColumns((prev) => ({
|
||||
...prev,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
||||
import { useLocation } from 'react-router-dom';
|
||||
import { Switch } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import LogsFormatOptionsMenu from 'components/LogsFormatOptionsMenu/LogsFormatOptionsMenu';
|
||||
import { MAX_LOGS_LIST_SIZE } from 'constants/liveTail';
|
||||
@@ -228,9 +228,8 @@ function LiveLogsContainer({
|
||||
<div className="live-logs-frequency-chart-view-controller">
|
||||
<Typography>Frequency chart</Typography>
|
||||
<Switch
|
||||
size="small"
|
||||
checked={showLiveLogsFrequencyChart}
|
||||
defaultChecked
|
||||
value={showLiveLogsFrequencyChart}
|
||||
defaultValue
|
||||
onChange={handleToggleFrequencyChart}
|
||||
/>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useMemo, useState } from 'react';
|
||||
import MEditor, { EditorProps, Monaco } from '@monaco-editor/react';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Switch } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import { useIsDarkMode } from 'hooks/useDarkMode';
|
||||
|
||||
@@ -81,7 +81,7 @@ function JSONView({ logData }: JSONViewProps): JSX.Element {
|
||||
<div className="log-switch">
|
||||
<div className="wrap-word-switch">
|
||||
<Typography.Text>Wrap text</Typography.Text>
|
||||
<Switch checked={isWrapWord} onChange={handleWrapWord} size="small" />
|
||||
<Switch value={isWrapWord} onChange={handleWrapWord} />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -2,7 +2,8 @@ import { ReactNode, useState } from 'react';
|
||||
import MEditor, { EditorProps, Monaco } from '@monaco-editor/react';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Button } from '@signozhq/ui/button';
|
||||
import { Collapse, Divider, Input, Switch, Tag } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Collapse, Divider, Input, Tag } from 'antd';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import { AddToQueryHOCProps } from 'components/Logs/AddToQueryHOC';
|
||||
import { ChangeViewFunctionType } from 'container/ExplorerOptions/types';
|
||||
@@ -136,7 +137,7 @@ function Overview({
|
||||
<div className="log-switch">
|
||||
<div className="wrap-word-switch">
|
||||
<Typography.Text>Wrap text</Typography.Text>
|
||||
<Switch checked={isWrapWord} onChange={handleWrapWord} size="small" />
|
||||
<Switch value={isWrapWord} onChange={handleWrapWord} />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Switch } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import DownloadOptionsMenu from 'components/DownloadOptionsMenu/DownloadOptionsMenu';
|
||||
import LogsFormatOptionsMenu from 'components/LogsFormatOptionsMenu/LogsFormatOptionsMenu';
|
||||
@@ -69,9 +69,8 @@ function LogsActionsContainer({
|
||||
<div className="frequency-chart-view-controller">
|
||||
<Typography>Frequency chart</Typography>
|
||||
<Switch
|
||||
size="small"
|
||||
checked={showFrequencyChart}
|
||||
defaultChecked
|
||||
value={showFrequencyChart}
|
||||
defaultValue
|
||||
onChange={handleToggleFrequencyChart}
|
||||
/>
|
||||
</div>
|
||||
|
||||
@@ -5,11 +5,11 @@ import { useParams } from 'react-router-dom';
|
||||
import { Search } from '@signozhq/icons';
|
||||
import {
|
||||
InputRef,
|
||||
Switch,
|
||||
TableColumnsType as ColumnsType,
|
||||
TableColumnType as ColumnType,
|
||||
Tooltip,
|
||||
} from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import { ResizeTable } from 'components/ResizeTable';
|
||||
import TextToolTip from 'components/TextToolTip';
|
||||
@@ -212,11 +212,7 @@ function TopOperationsTable({
|
||||
/>
|
||||
</div>
|
||||
<div className="top-operation__entry-point">
|
||||
<Switch
|
||||
checked={isEntryPoint}
|
||||
onChange={onEntryPointToggle}
|
||||
size="small"
|
||||
/>
|
||||
<Switch value={isEntryPoint} onChange={onEntryPointToggle} />
|
||||
<span className="top-operation__entry-point-label">Entrypoint Spans</span>
|
||||
<TextToolTip
|
||||
text={entryPointSpanInfo.text}
|
||||
|
||||
@@ -2,7 +2,8 @@ import { useCallback, useEffect, useMemo, useState } from 'react';
|
||||
import { useQueryClient } from 'react-query';
|
||||
import { useSearchParams } from 'react-router-dom-v5-compat';
|
||||
import * as Sentry from '@sentry/react';
|
||||
import { Switch, Tooltip } from 'antd';
|
||||
import { Tooltip } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import logEvent from 'api/common/logEvent';
|
||||
import { QueryBuilderV2 } from 'components/QueryBuilderV2/QueryBuilderV2';
|
||||
import WarningPopover from 'components/WarningPopover/WarningPopover';
|
||||
@@ -358,10 +359,9 @@ function Explorer(): JSX.Element {
|
||||
title={oneChartPerQueryDisabledTooltip}
|
||||
>
|
||||
<Switch
|
||||
checked={showOneChartPerQuery}
|
||||
value={showOneChartPerQuery}
|
||||
onChange={handleToggleShowOneChartPerQuery}
|
||||
disabled={disableOneChartPerQuery || splitedQueries.length <= 1}
|
||||
size="small"
|
||||
/>
|
||||
</Tooltip>
|
||||
</div>
|
||||
|
||||
@@ -2,7 +2,8 @@ import { useEffect, useMemo, useRef, useState } from 'react';
|
||||
// eslint-disable-next-line no-restricted-imports
|
||||
import { useSelector } from 'react-redux';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Button, Skeleton, Switch } from 'antd';
|
||||
import { Button, Skeleton } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import logEvent from 'api/common/logEvent';
|
||||
import Uplot from 'components/Uplot';
|
||||
@@ -206,7 +207,7 @@ function GraphView({
|
||||
</Button.Group>
|
||||
<div className="view-toggle-button">
|
||||
<Switch
|
||||
checked={viewType === 'graph'}
|
||||
value={viewType === 'graph'}
|
||||
onChange={(checked): void => {
|
||||
const newViewType = checked ? 'graph' : 'table';
|
||||
setViewType(newViewType);
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useMemo } from 'react';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Switch } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import logEvent from 'api/common/logEvent';
|
||||
import { Delete } from '@signozhq/icons';
|
||||
import { useTimezone } from 'providers/Timezone';
|
||||
@@ -49,10 +49,10 @@ function TimezoneAdaptation(): JSX.Element {
|
||||
<div className="timezone-adaption__header">
|
||||
<h2 className="timezone-adaption__title">Adapt to my timezone</h2>
|
||||
<Switch
|
||||
checked={isAdaptationEnabled}
|
||||
value={isAdaptationEnabled}
|
||||
onChange={handleSwitchChange}
|
||||
style={getSwitchStyles()}
|
||||
data-testid="timezone-adaptation-switch"
|
||||
testId="timezone-adaptation-switch"
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { useEffect, useState } from 'react';
|
||||
import { useMutation } from 'react-query';
|
||||
import { Radio, RadioChangeEvent, Switch, Tag } from 'antd';
|
||||
import { Radio, RadioChangeEvent, Tag } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import setLocalStorageApi from 'api/browser/localstorage/set';
|
||||
import logEvent from 'api/common/logEvent';
|
||||
import updateUserPreference from 'api/v1/user/preferences/name/update';
|
||||
@@ -218,10 +219,10 @@ function MySettings(): JSX.Element {
|
||||
<div className="user-preference-section-content-item-title-action">
|
||||
Keep the primary sidebar always open{' '}
|
||||
<Switch
|
||||
checked={sideNavPinned}
|
||||
value={sideNavPinned}
|
||||
onChange={handleSideNavPinnedChange}
|
||||
loading={isUpdatingUserPreference}
|
||||
data-testid="side-nav-pinned-switch"
|
||||
disabled={isUpdatingUserPreference}
|
||||
testId="side-nav-pinned-switch"
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Dispatch, SetStateAction } from 'react';
|
||||
import { Switch } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import {
|
||||
FillMode,
|
||||
@@ -73,7 +73,7 @@ export default function ChartAppearanceSection({
|
||||
Display individual data points on the chart
|
||||
</Typography.Text>
|
||||
</div>
|
||||
<Switch size="small" checked={showPoints} onChange={setShowPoints} />
|
||||
<Switch value={showPoints} onChange={setShowPoints} />
|
||||
</section>
|
||||
)}
|
||||
{allowSpanGaps && (
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { Dispatch, SetStateAction } from 'react';
|
||||
import { InputNumber, Switch } from 'antd';
|
||||
import { InputNumber } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
|
||||
import SettingsSection from '../../components/SettingsSection/SettingsSection';
|
||||
@@ -61,8 +62,7 @@ export default function HistogramBucketsSection({
|
||||
</span>
|
||||
</Typography.Text>
|
||||
<Switch
|
||||
checked={combineHistogram}
|
||||
size="small"
|
||||
value={combineHistogram}
|
||||
onChange={(checked): void => setCombineHistogram(checked)}
|
||||
/>
|
||||
</section>
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { Dispatch, SetStateAction, useEffect, useState } from 'react';
|
||||
import { Select, Switch } from 'antd';
|
||||
import { Select } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import TimePreference from 'components/TimePreferenceDropDown';
|
||||
import { PANEL_TYPES } from 'constants/queryBuilder';
|
||||
@@ -104,8 +105,7 @@ export default function VisualizationSettingsSection({
|
||||
<section className="stack-chart control-container">
|
||||
<Typography.Text className="section-heading">Stack series</Typography.Text>
|
||||
<Switch
|
||||
checked={stackedBarChart}
|
||||
size="small"
|
||||
value={stackedBarChart}
|
||||
onChange={(checked): void => setStackedBarChart(checked)}
|
||||
/>
|
||||
</section>
|
||||
@@ -120,8 +120,7 @@ export default function VisualizationSettingsSection({
|
||||
</Typography.Text>
|
||||
</div>
|
||||
<Switch
|
||||
checked={isFillSpans}
|
||||
size="small"
|
||||
value={isFillSpans}
|
||||
onChange={(checked): void => setIsFillSpans(checked)}
|
||||
/>
|
||||
</section>
|
||||
|
||||
@@ -341,10 +341,10 @@ describe('Stacking bar in new panel', () => {
|
||||
const section = container.querySelector('.stack-chart');
|
||||
expect(section).toBeInTheDocument();
|
||||
|
||||
// Verify switch is present and enabled (ant-switch-checked)
|
||||
const switchBtn = section?.querySelector('.ant-switch');
|
||||
// Verify switch is present and enabled
|
||||
const switchBtn = section?.querySelector('[role="switch"]');
|
||||
expect(switchBtn).toBeInTheDocument();
|
||||
expect(switchBtn).toHaveClass('ant-switch-checked');
|
||||
expect(switchBtn).toHaveAttribute('data-state', 'checked');
|
||||
|
||||
// Check that stack series is present and checked
|
||||
checkStackSeriesState(container, true);
|
||||
|
||||
@@ -58,6 +58,26 @@ describe('AuthDomain', () => {
|
||||
});
|
||||
});
|
||||
|
||||
it('reflects ssoEnabled state from nested config in each row toggle', async () => {
|
||||
server.use(
|
||||
rest.get(AUTH_DOMAINS_LIST_ENDPOINT, (_, res, ctx) =>
|
||||
res(ctx.status(200), ctx.json(mockDomainsListResponse)),
|
||||
),
|
||||
);
|
||||
|
||||
render(<AuthDomain />);
|
||||
|
||||
// mockDomainsListResponse rows:
|
||||
// [0] signoz.io → config.ssoEnabled: true
|
||||
// [1] example.com → config.ssoEnabled: false
|
||||
// [2] corp.io → config.ssoEnabled: true
|
||||
const switches = await screen.findAllByRole('switch');
|
||||
expect(switches).toHaveLength(3);
|
||||
expect(switches[0]).toBeChecked();
|
||||
expect(switches[1]).not.toBeChecked();
|
||||
expect(switches[2]).toBeChecked();
|
||||
});
|
||||
|
||||
it('renders empty state when no domains exist', async () => {
|
||||
server.use(
|
||||
rest.get(AUTH_DOMAINS_LIST_ENDPOINT, (_, res, ctx) =>
|
||||
|
||||
@@ -121,14 +121,14 @@ function AuthDomain(): JSX.Element {
|
||||
},
|
||||
{
|
||||
title: 'Enforce SSO',
|
||||
dataIndex: 'ssoEnabled',
|
||||
dataIndex: ['config', 'ssoEnabled'],
|
||||
key: 'ssoEnabled',
|
||||
width: 80,
|
||||
render: (
|
||||
value: boolean,
|
||||
record: AuthtypesGettableAuthDomainDTO,
|
||||
): JSX.Element => (
|
||||
<SSOEnforcementToggle isDefaultChecked={value} record={record} />
|
||||
<SSOEnforcementToggle isDefaultChecked={!!value} record={record} />
|
||||
),
|
||||
},
|
||||
{
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { useEffect, useState } from 'react';
|
||||
import { Info } from '@signozhq/icons';
|
||||
import { Flex, Form, Input, Space, Switch, Tooltip } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Flex, Form, Input, Space, Tooltip } from 'antd';
|
||||
import { ProcessorData } from 'types/api/pipeline/def';
|
||||
|
||||
import { PREDEFINED_MAPPING } from '../config';
|
||||
@@ -58,11 +59,7 @@ function JsonFlattening({
|
||||
initialValue={isAdd ? true : selectedProcessorData?.enable_paths}
|
||||
>
|
||||
<Space>
|
||||
<Switch
|
||||
size="small"
|
||||
checked={enablePaths}
|
||||
onChange={handleEnablePathsChange}
|
||||
/>
|
||||
<Switch value={enablePaths} onChange={handleEnablePathsChange} />
|
||||
Enable Paths
|
||||
</Space>
|
||||
</Form.Item>
|
||||
@@ -79,11 +76,7 @@ function JsonFlattening({
|
||||
|
||||
<Form.Item className="json-flattening-form__item">
|
||||
<Space>
|
||||
<Switch
|
||||
size="small"
|
||||
checked={enableMapping}
|
||||
onChange={handleEnableMappingChange}
|
||||
/>
|
||||
<Switch value={enableMapping} onChange={handleEnableMappingChange} />
|
||||
<Flex gap="8px" align="center">
|
||||
Enable Mapping
|
||||
<Tooltip title="The order of filled keys will determine the priority of keys i.e. earlier keys have higher precedence">
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Form, Input, Select, Space, Switch } from 'antd';
|
||||
import { Form, Input, Select, Space } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { ModalFooterTitle } from 'container/PipelinePage/styles';
|
||||
import { ProcessorData } from 'types/api/pipeline/def';
|
||||
|
||||
@@ -92,8 +93,7 @@ function ProcessorFieldInput({
|
||||
>
|
||||
<Space>
|
||||
<Switch
|
||||
size="small"
|
||||
checked={form.getFieldValue('enable_flattening')}
|
||||
value={form.getFieldValue('enable_flattening')}
|
||||
onChange={(checked: boolean): void => {
|
||||
form.setFieldValue('enable_flattening', checked);
|
||||
}}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { GripVertical } from '@signozhq/icons';
|
||||
import { Switch } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
|
||||
import { holdIconStyle } from '../config';
|
||||
import { LastActionColumn } from '../styles';
|
||||
@@ -7,7 +7,7 @@ import { LastActionColumn } from '../styles';
|
||||
function DragAction({ isEnabled, onChange }: DragActionProps): JSX.Element {
|
||||
return (
|
||||
<LastActionColumn>
|
||||
<Switch defaultChecked={isEnabled} onChange={onChange} />
|
||||
<Switch defaultValue={isEnabled} onChange={onChange} />
|
||||
<GripVertical size="lg" style={holdIconStyle} />
|
||||
</LastActionColumn>
|
||||
);
|
||||
|
||||
@@ -191,7 +191,7 @@ describe('PipelinePage container test', () => {
|
||||
await fireEvent.click(expandIcon[0]);
|
||||
|
||||
const switchToggle = document.querySelector(
|
||||
'.ant-table-expanded-row .ant-switch',
|
||||
'.ant-table-expanded-row [role="switch"]',
|
||||
);
|
||||
|
||||
expect(switchToggle).toBeChecked();
|
||||
@@ -244,7 +244,7 @@ describe('PipelinePage container test', () => {
|
||||
const addNewPipelineBtn = getByText('add_new_pipeline');
|
||||
expect(addNewPipelineBtn).toBeInTheDocument();
|
||||
|
||||
const switchToggle = document.querySelectorAll('.ant-switch');
|
||||
const switchToggle = document.querySelectorAll('[role="switch"]');
|
||||
|
||||
expect(switchToggle[0]).not.toBeChecked();
|
||||
await fireEvent.click(switchToggle[0] as HTMLElement);
|
||||
|
||||
@@ -21,26 +21,25 @@ exports[`PipelinePage container test should render DragAction section 1`] = `
|
||||
<div
|
||||
class="c0"
|
||||
>
|
||||
<button
|
||||
aria-checked="true"
|
||||
class="ant-switch css-dev-only-do-not-override-2i2tap ant-switch-checked"
|
||||
role="switch"
|
||||
type="button"
|
||||
<div
|
||||
class="_switch-wrapper_jbsv7_1"
|
||||
>
|
||||
<div
|
||||
class="ant-switch-handle"
|
||||
/>
|
||||
<span
|
||||
class="ant-switch-inner"
|
||||
<button
|
||||
aria-checked="true"
|
||||
class="_switch_jbsv7_1"
|
||||
data-color="robin"
|
||||
data-state="checked"
|
||||
id=":r0:"
|
||||
role="switch"
|
||||
type="button"
|
||||
value="on"
|
||||
>
|
||||
<span
|
||||
class="ant-switch-inner-checked"
|
||||
class="_switch__thumb_jbsv7_59"
|
||||
data-state="checked"
|
||||
/>
|
||||
<span
|
||||
class="ant-switch-inner-unchecked"
|
||||
/>
|
||||
</span>
|
||||
</button>
|
||||
</button>
|
||||
</div>
|
||||
<svg
|
||||
style="font-size: 1rem; cursor: move;"
|
||||
/>
|
||||
|
||||
@@ -1,84 +0,0 @@
|
||||
import getLabelName from 'lib/getLabelName';
|
||||
|
||||
describe('getLabelName', () => {
|
||||
describe('with a legend template', () => {
|
||||
it('substitutes a single variable that exists on the series', () => {
|
||||
const result = getLabelName(
|
||||
{ 'service.name': 'frontend' },
|
||||
'A',
|
||||
'{{service.name}}',
|
||||
);
|
||||
expect(result).toBe('frontend');
|
||||
});
|
||||
|
||||
it('substitutes a template with surrounding literal text', () => {
|
||||
const result = getLabelName(
|
||||
{ 'service.name': 'frontend' },
|
||||
'A',
|
||||
'rate for {{service.name}}',
|
||||
);
|
||||
expect(result).toBe('rate for frontend');
|
||||
});
|
||||
|
||||
it('substitutes multiple variables when all are present', () => {
|
||||
const result = getLabelName(
|
||||
{ 'service.name': 'frontend', 'http.target': 'GET /api' },
|
||||
'A',
|
||||
'{{service.name}} / {{http.target}}',
|
||||
);
|
||||
expect(result).toBe('frontend / GET /api');
|
||||
});
|
||||
|
||||
it('falls back to query name when a referenced variable is missing', () => {
|
||||
const result = getLabelName(
|
||||
{ 'http.target': 'GET /api' },
|
||||
'F1',
|
||||
'{{service.name}}',
|
||||
);
|
||||
expect(result).toBe('F1');
|
||||
});
|
||||
|
||||
it('falls back to query name even if literal text would still render', () => {
|
||||
const result = getLabelName(
|
||||
{ 'http.target': 'GET /api' },
|
||||
'F1',
|
||||
'label = {{label}}',
|
||||
);
|
||||
expect(result).toBe('F1');
|
||||
});
|
||||
|
||||
it('falls back to query name when any of multiple variables is missing', () => {
|
||||
const result = getLabelName(
|
||||
{ 'service.name': 'frontend' },
|
||||
'F1',
|
||||
'{{service.name}} / {{http.target}}',
|
||||
);
|
||||
expect(result).toBe('F1');
|
||||
});
|
||||
|
||||
it('treats a null label value as missing', () => {
|
||||
const result = getLabelName(
|
||||
{ 'service.name': null } as unknown as Record<string, string>,
|
||||
'F1',
|
||||
'{{service.name}}',
|
||||
);
|
||||
expect(result).toBe('F1');
|
||||
});
|
||||
});
|
||||
|
||||
describe('without a legend template', () => {
|
||||
it('returns key="value" pairs for plain labels', () => {
|
||||
const result = getLabelName(
|
||||
{ 'service.name': 'frontend', 'http.target': 'GET /api' },
|
||||
'A',
|
||||
'',
|
||||
);
|
||||
expect(result).toBe('{service.name="frontend",http.target="GET /api"}');
|
||||
});
|
||||
|
||||
it('returns query name when labels are empty', () => {
|
||||
const result = getLabelName({}, 'A', '');
|
||||
expect(result).toBe('A');
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -18,17 +18,6 @@ const getLabelName = (
|
||||
|
||||
const results = variables.map((variable) => metric[variable]);
|
||||
|
||||
// Fall back to query name if any `{{var}}` references a label that
|
||||
// isn't on this series — avoids rendering "undefined" in the legend.
|
||||
const hasMissingVariable = variables.some(
|
||||
(variable, index) =>
|
||||
legends.includes(`{{${variable}}}`) &&
|
||||
(results[index] === undefined || results[index] === null),
|
||||
);
|
||||
if (hasMissingVariable) {
|
||||
return query;
|
||||
}
|
||||
|
||||
let endResult = legends;
|
||||
|
||||
variables.forEach((e, index) => {
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { useCallback, useEffect, useState } from 'react';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Divider, Dropdown, MenuProps, Switch, Tooltip } from 'antd';
|
||||
import { Divider, Dropdown, MenuProps, Tooltip } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { useIsDarkMode } from 'hooks/useDarkMode';
|
||||
import { Copy, Ellipsis, PenLine, Trash2 } from '@signozhq/icons';
|
||||
import {
|
||||
@@ -132,11 +133,7 @@ function AlertActionButtons({
|
||||
<div className="alert-action-buttons">
|
||||
<Tooltip title={isAlertRuleDisabled ? 'Enable alert' : 'Disable alert'}>
|
||||
{isAlertRuleDisabled !== undefined && (
|
||||
<Switch
|
||||
size="small"
|
||||
onChange={toggleAlertRule}
|
||||
checked={!isAlertRuleDisabled}
|
||||
/>
|
||||
<Switch onChange={toggleAlertRule} value={!isAlertRuleDisabled} />
|
||||
)}
|
||||
</Tooltip>
|
||||
<CopyToClipboard textToCopy={window.location.href} />
|
||||
|
||||
@@ -6,9 +6,9 @@ import {
|
||||
Form,
|
||||
MenuProps,
|
||||
Space,
|
||||
Switch,
|
||||
Tooltip,
|
||||
} from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import cx from 'classnames';
|
||||
import { FilterSelect } from 'components/CeleryOverview/CeleryOverviewConfigOptions/CeleryOverviewConfigOptions';
|
||||
import { QueryParams } from 'constants/query';
|
||||
@@ -201,8 +201,7 @@ function FunnelStep({
|
||||
<div className="error">
|
||||
<Switch
|
||||
className="error__switch"
|
||||
size="small"
|
||||
checked={stepData.has_errors}
|
||||
value={stepData.has_errors}
|
||||
disabled={!hasEditPermission}
|
||||
onChange={(): void =>
|
||||
onStepChange(index, { has_errors: !stepData.has_errors })
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useState } from 'react';
|
||||
import MEditor, { EditorProps, Monaco } from '@monaco-editor/react';
|
||||
import { Color } from '@signozhq/design-tokens';
|
||||
import { Switch } from 'antd';
|
||||
import { Switch } from '@signozhq/ui/switch';
|
||||
import { Typography } from '@signozhq/ui/typography';
|
||||
import { useIsDarkMode } from 'hooks/useDarkMode';
|
||||
|
||||
@@ -72,9 +72,8 @@ function JsonView({ data, height = '575px' }: JsonViewProps): JSX.Element {
|
||||
<div className="json-view__wrap-toggle">
|
||||
<Typography.Text>Wrap text</Typography.Text>
|
||||
<Switch
|
||||
checked={isWrapWord}
|
||||
value={isWrapWord}
|
||||
onChange={(checked): void => setIsWrapWord(checked)}
|
||||
size="small"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -7,8 +7,6 @@ import (
|
||||
"strings"
|
||||
"unicode"
|
||||
|
||||
"github.com/SigNoz/signoz/pkg/query-service/constants"
|
||||
|
||||
"encoding/base64"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
@@ -178,27 +176,6 @@ func HydrateFileUris(spec interface{}, fs embed.FS, basedir string) (interface{}
|
||||
if specMap, ok := spec.(map[string]interface{}); ok {
|
||||
result := map[string]interface{}{}
|
||||
for k, v := range specMap {
|
||||
// Check if this is a dashboards slice and if dot metrics are enabled
|
||||
if k == "dashboards" && constants.IsDotMetricsEnabled {
|
||||
if dashboards, ok := v.([]interface{}); ok {
|
||||
for i, dashboard := range dashboards {
|
||||
if dashboardUri, ok := dashboard.(string); ok {
|
||||
if strings.HasPrefix(dashboardUri, "file://") {
|
||||
dashboards[i] = strings.Replace(dashboardUri, ".json", "_dot.json", 1)
|
||||
}
|
||||
} else if dashBoardMap, ok := dashboard.(map[string]interface{}); ok {
|
||||
if dashboardUri, ok := dashBoardMap["definition"].(string); ok {
|
||||
if strings.HasPrefix(dashboardUri, "file://") {
|
||||
dashboardUri = strings.Replace(dashboardUri, ".json", "_dot.json", 1)
|
||||
}
|
||||
dashBoardMap["definition"] = dashboardUri
|
||||
}
|
||||
dashboards[i] = dashBoardMap
|
||||
}
|
||||
}
|
||||
v = dashboards
|
||||
}
|
||||
}
|
||||
hydrated, err := HydrateFileUris(v, fs, basedir)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -367,9 +367,9 @@
|
||||
"id": "31d3f13b-27d5-4291-9fb3-d5d5708a72f3",
|
||||
"modificationUUID": "e4a9edf1-acd0-48b7-8a35-1b4bb668408d",
|
||||
"multiSelect": false,
|
||||
"name": "mysql_instance_endpoint",
|
||||
"name": "mysql.instance.endpoint",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'mysql_instance_endpoint') as mysql_instance_endpoint\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'mysql_uptime'\nGROUP BY mysql_instance_endpoint",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'mysql.instance.endpoint') as `mysql.instance.endpoint`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'mysql.uptime'\nGROUP BY `mysql.instance.endpoint`",
|
||||
"selectedValue": "",
|
||||
"showALLOption": false,
|
||||
"sort": "ASC",
|
||||
@@ -393,7 +393,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_buffer_pool_usage",
|
||||
"metricName": "mysql.buffer_pool.pages",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -404,7 +404,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -529,7 +529,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_buffer_pool_pages",
|
||||
"metricName": "mysql.buffer_pool.pages",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -540,7 +540,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -658,7 +658,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_buffer_pool_data_pages",
|
||||
"metricName": "mysql.buffer_pool.data_pages",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -669,7 +669,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -788,7 +788,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_buffer_pool_page_flushes",
|
||||
"metricName": "mysql.buffer_pool.page_flushes",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -799,7 +799,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [],
|
||||
@@ -915,7 +915,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_table_io_wait_count",
|
||||
"metricName": "mysql.table.io.wait.count",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -926,7 +926,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1045,7 +1045,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_table_io_wait_count",
|
||||
"metricName": "mysql.table.io.wait.count",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1056,7 +1056,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1175,7 +1175,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_table_io_wait_count",
|
||||
"metricName": "mysql.table.io.wait.count",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1186,7 +1186,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1305,7 +1305,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_handlers",
|
||||
"metricName": "mysql.handlers",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1316,7 +1316,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1329,7 +1329,7 @@
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": "sum(mysql_handlers) \u003e 0"
|
||||
"expression": "sum(mysql.handlers) \u003e 0"
|
||||
},
|
||||
"legend": "{{kind}}",
|
||||
"limit": null,
|
||||
@@ -1434,7 +1434,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_locks",
|
||||
"metricName": "mysql.locks",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1445,7 +1445,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1563,7 +1563,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_log_operations",
|
||||
"metricName": "mysql.log_operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1574,7 +1574,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1693,7 +1693,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_connection_count",
|
||||
"metricName": "mysql.connection.count",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1704,7 +1704,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [],
|
||||
@@ -1720,7 +1720,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_connection_errors",
|
||||
"metricName": "mysql.connection.errors",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1731,7 +1731,7 @@
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1745,7 +1745,7 @@
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": "sum(mysql_connection_errors) \u003e 0"
|
||||
"expression": "sum(mysql.connection.errors) \u003e 0"
|
||||
},
|
||||
"legend": "Error count: {{error}}",
|
||||
"limit": null,
|
||||
@@ -1850,7 +1850,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_opened_resources",
|
||||
"metricName": "mysql.opened_resources",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1861,7 +1861,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -1874,7 +1874,7 @@
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": "sum(mysql_opened_resources) \u003e 0"
|
||||
"expression": "sum(mysql.opened_resources) \u003e 0"
|
||||
},
|
||||
"legend": "{{kind}}",
|
||||
"limit": null,
|
||||
@@ -1979,7 +1979,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_operations",
|
||||
"metricName": "mysql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1990,7 +1990,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -2109,7 +2109,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_row_locks",
|
||||
"metricName": "mysql.row_locks",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -2120,7 +2120,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -2238,7 +2238,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_threads",
|
||||
"metricName": "mysql.threads",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -2249,7 +2249,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -2367,7 +2367,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_row_operations",
|
||||
"metricName": "mysql.row_operations",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -2378,7 +2378,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
@@ -2497,7 +2497,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mysql_prepared_statements",
|
||||
"metricName": "mysql.prepared_statements",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -2508,7 +2508,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "mysql_instance_endpoint = $mysql_instance_endpoint"
|
||||
"expression": "mysql.instance.endpoint = $mysql.instance.endpoint"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -287,7 +287,7 @@
|
||||
"multiSelect": true,
|
||||
"name": "table_name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql_table_name') AS table_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql_operations' AND JSONExtractString(labels, 'postgresql_database_name') IN {{.db_name}}\nGROUP BY table_name",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql.table.name') AS table_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql.operations' AND JSONExtractString(labels, 'postgresql.database.name') IN {{.db_name}}\nGROUP BY table_name",
|
||||
"selectedValue": [
|
||||
"public.pgbench_accounts",
|
||||
"public.pgbench_branches",
|
||||
@@ -309,7 +309,7 @@
|
||||
"multiSelect": true,
|
||||
"name": "db_name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql_database_name') AS db_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql_operations'\nGROUP BY db_name",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql.database.name') AS db_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql.operations'\nGROUP BY db_name",
|
||||
"selectedValue": [
|
||||
"pgtestdb"
|
||||
],
|
||||
@@ -335,7 +335,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -346,22 +346,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'ins' AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'ins' AND postgresql.database.name IN $db_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -410,7 +410,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -421,22 +421,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'upd' AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'upd' AND postgresql.database.name IN $db_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -485,7 +485,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -496,22 +496,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'del' AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'del' AND postgresql.database.name IN $db_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -560,7 +560,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -571,22 +571,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'hot_upd' AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'hot_upd' AND postgresql.database.name IN $db_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -635,7 +635,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -646,15 +646,15 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'ins' AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'ins' AND postgresql.database.name IN $db_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -670,7 +670,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -681,15 +681,15 @@
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "(operation = 'upd' AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'upd' AND postgresql.database.name IN $db_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -705,7 +705,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -716,15 +716,15 @@
|
||||
"disabled": false,
|
||||
"expression": "C",
|
||||
"filter": {
|
||||
"expression": "(operation = 'del' AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'del' AND postgresql.database.name IN $db_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -780,7 +780,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_database_locks",
|
||||
"metricName": "postgresql.database.locks",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -852,7 +852,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_deadlocks",
|
||||
"metricName": "postgresql.deadlocks",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -863,22 +863,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "postgresql_database_name IN $db_name"
|
||||
"expression": "postgresql.database.name IN $db_name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -927,7 +927,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_backends",
|
||||
"metricName": "postgresql.backends",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -938,22 +938,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "postgresql_database_name IN $db_name"
|
||||
"expression": "postgresql.database.name IN $db_name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -1002,7 +1002,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_rows",
|
||||
"metricName": "postgresql.rows",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1013,7 +1013,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(state = 'dead' AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(state = 'dead' AND postgresql.database.name IN $db_name AND postgresql.table.name IN $table_name)"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -1068,7 +1068,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_index_scans",
|
||||
"metricName": "postgresql.index.scans",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1079,22 +1079,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(postgresql.database.name IN $db_name AND postgresql.table.name IN $table_name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_index_name--string--tag--false",
|
||||
"id": "postgresql.index.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_index_name",
|
||||
"key": "postgresql.index.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_index_name}}",
|
||||
"legend": "{{postgresql.index.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -1143,7 +1143,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_rows",
|
||||
"metricName": "postgresql.rows",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -1154,16 +1154,16 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(state = 'dead' AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(state = 'dead' AND postgresql.database.name IN $db_name AND postgresql.table.name IN $table_name)"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -1179,7 +1179,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_rows",
|
||||
"metricName": "postgresql.rows",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -1190,16 +1190,16 @@
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "(state = 'live' AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(state = 'live' AND postgresql.database.name IN $db_name AND postgresql.table.name IN $table_name)"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -1215,7 +1215,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_index_scans",
|
||||
"metricName": "postgresql.index.scans",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1226,16 +1226,16 @@
|
||||
"disabled": false,
|
||||
"expression": "C",
|
||||
"filter": {
|
||||
"expression": "(postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(postgresql.database.name IN $db_name AND postgresql.table.name IN $table_name)"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -1251,7 +1251,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_table_size",
|
||||
"metricName": "postgresql.table.size",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -1262,16 +1262,16 @@
|
||||
"disabled": true,
|
||||
"expression": "D",
|
||||
"filter": {
|
||||
"expression": "(postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(postgresql.database.name IN $db_name AND postgresql.table.name IN $table_name)"
|
||||
},
|
||||
"functions": [],
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -80,9 +80,9 @@
|
||||
"id": "a2c21714-a814-4d31-9b56-7367c3208801",
|
||||
"modificationUUID": "448e675a-4531-45b1-b434-a9ee809470d6",
|
||||
"multiSelect": true,
|
||||
"name": "host_name",
|
||||
"name": "host.name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host_name') AS host_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'mongodb_memory_usage'\nGROUP BY host_name",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host.name') AS `host.name`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'mongodb_memory_usage'\nGROUP BY `host.name`",
|
||||
"selectedValue": [
|
||||
"Srikanths-MacBook-Pro.local"
|
||||
],
|
||||
@@ -108,7 +108,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_operation_count",
|
||||
"metricName": "mongodb.operation.count",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -119,7 +119,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
@@ -183,7 +183,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_operation_time",
|
||||
"metricName": "mongodb.operation.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -194,7 +194,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
@@ -258,7 +258,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_cache_operations",
|
||||
"metricName": "mongodb.cache.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -269,7 +269,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
@@ -333,7 +333,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_operation_latency_time",
|
||||
"metricName": "mongodb.operation.latency.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
@@ -344,7 +344,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'read' AND host_name IN $host_name)"
|
||||
"expression": "(operation = 'read' AND host.name IN $host.name)"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -399,7 +399,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_operation_latency_time",
|
||||
"metricName": "mongodb.operation.latency.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
@@ -410,7 +410,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(host_name IN $host_name AND operation = 'write')"
|
||||
"expression": "(host.name IN $host.name AND operation = 'write')"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -465,7 +465,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_operation_latency_time",
|
||||
"metricName": "mongodb.operation.latency.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
@@ -476,7 +476,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(host_name IN $host_name AND operation = 'command')"
|
||||
"expression": "(host.name IN $host.name AND operation = 'command')"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -531,7 +531,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_network_io_receive",
|
||||
"metricName": "mongodb.network.io.receive",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -542,22 +542,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host_name--string--tag--false",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host_name",
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Bytes received :: {{host_name}}",
|
||||
"legend": "Bytes received :: {{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -566,7 +566,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb_network_io_transmit",
|
||||
"metricName": "mongodb.network.io.transmit",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -577,22 +577,22 @@
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host_name--string--tag--false",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host_name",
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Bytes transmitted :: {{host_name}}",
|
||||
"legend": "Bytes transmitted :: {{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "B",
|
||||
|
||||
@@ -1,631 +0,0 @@
|
||||
{
|
||||
"description": "This dashboard provides a high-level overview of your MongoDB. It includes read/write performance, most-used replicas, collection metrics etc...",
|
||||
"id": "mongo-overview",
|
||||
"layout": [
|
||||
{
|
||||
"h": 3,
|
||||
"i": "0c3d2b15-89be-4d62-a821-b26d93332ed3",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 6,
|
||||
"y": 3
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "14504a3c-4a05-4d22-bab3-e22e94f51380",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 6
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "dcfb3829-c3f2-44bb-907d-8dc8a6dc4aab",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 3
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "bfc9e80b-02bf-4122-b3da-3dd943d35012",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 6,
|
||||
"y": 0
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "4c07a7d2-893a-46c2-bcdb-a19b6efeac3a",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 0
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "a5a64eec-1034-4aa6-8cb1-05673c4426c6",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 6,
|
||||
"y": 6
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "503af589-ef4d-4fe3-8934-c8f7eb480d9a",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 9
|
||||
}
|
||||
],
|
||||
"name": "",
|
||||
"tags": [
|
||||
"mongo",
|
||||
"database"
|
||||
],
|
||||
"title": "Mongo overview",
|
||||
"variables": {
|
||||
"a2c21714-a814-4d31-9b56-7367c3208801": {
|
||||
"allSelected": true,
|
||||
"customValue": "",
|
||||
"description": "List of hosts sending mongo metrics",
|
||||
"id": "a2c21714-a814-4d31-9b56-7367c3208801",
|
||||
"modificationUUID": "448e675a-4531-45b1-b434-a9ee809470d6",
|
||||
"multiSelect": true,
|
||||
"name": "host.name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host.name') AS `host.name`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'mongodb_memory_usage'\nGROUP BY `host.name`",
|
||||
"selectedValue": [
|
||||
"Srikanths-MacBook-Pro.local"
|
||||
],
|
||||
"showALLOption": true,
|
||||
"sort": "ASC",
|
||||
"textboxValue": "",
|
||||
"type": "QUERY"
|
||||
}
|
||||
},
|
||||
"version": "v5",
|
||||
"widgets": [
|
||||
{
|
||||
"description": "Total number of operations",
|
||||
"fillSpans": false,
|
||||
"id": "4c07a7d2-893a-46c2-bcdb-a19b6efeac3a",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.operation.count",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "rate"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "operation--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "operation",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{operation}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "7da5d899-8b06-4139-9a89-47baf9551ff8",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Operations count",
|
||||
"yAxisUnit": "none"
|
||||
},
|
||||
{
|
||||
"description": "The total time spent performing operations.",
|
||||
"fillSpans": false,
|
||||
"id": "bfc9e80b-02bf-4122-b3da-3dd943d35012",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.operation.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "rate"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "operation--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "operation",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{operation}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "2ca35957-894a-46ae-a2a6-95d7e400d8e1",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Total operations time",
|
||||
"yAxisUnit": "ms"
|
||||
},
|
||||
{
|
||||
"description": "The number of cache operations",
|
||||
"fillSpans": false,
|
||||
"id": "dcfb3829-c3f2-44bb-907d-8dc8a6dc4aab",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.cache.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "rate"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "type--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "type",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{type}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "bb439198-dcf5-4767-b0d0-ab5785159b8d",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Cache operations",
|
||||
"yAxisUnit": "none"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "14504a3c-4a05-4d22-bab3-e22e94f51380",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.operation.latency.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
"timeAggregation": "max"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'read' AND host.name IN $host.name)"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Latency",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "4a9cafe8-778b-476c-b825-c04e165bf285",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Read latency",
|
||||
"yAxisUnit": "µs"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "a5a64eec-1034-4aa6-8cb1-05673c4426c6",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.operation.latency.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
"timeAggregation": "max"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(host.name IN $host.name AND operation = 'write')"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Latency",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "446827eb-a4f2-4ff3-966b-fb65288c983b",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Write latency",
|
||||
"yAxisUnit": "µs"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "503af589-ef4d-4fe3-8934-c8f7eb480d9a",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.operation.latency.time",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
"timeAggregation": "max"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(host.name IN $host.name AND operation = 'command')"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Latency",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "7b7b977d-0921-4552-8cfe-d82dfde63ef4",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Command latency",
|
||||
"yAxisUnit": "µs"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "0c3d2b15-89be-4d62-a821-b26d93332ed3",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.network.io.receive",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
"timeAggregation": "avg"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Bytes received :: {{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
},
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "mongodb.network.io.transmit",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
"timeAggregation": "avg"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Bytes transmitted :: {{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "B",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "41eea5bc-f9cf-45c2-92fb-ef226d6b540b",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Network IO",
|
||||
"yAxisUnit": "bytes"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -117,9 +117,9 @@
|
||||
"key": "4250ef7b-8f42-4a24-902a-a764d070b92d",
|
||||
"modificationUUID": "4427b655-c8d2-40ce-84ed-7cb058bd3041",
|
||||
"multiSelect": true,
|
||||
"name": "host_name",
|
||||
"name": "host.name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host_name') AS host_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql_operations'\nGROUP BY host_name",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host.name') AS `host.name`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql.operations'\nGROUP BY `host.name`",
|
||||
"selectedValue": [
|
||||
"Srikanths-MacBook-Pro.local"
|
||||
],
|
||||
@@ -135,9 +135,9 @@
|
||||
"id": "8ecaee70-640f-46fd-83d9-a4fd18bc66e6",
|
||||
"modificationUUID": "a51321cd-47a2-470a-8df4-372e5bb36f2c",
|
||||
"multiSelect": true,
|
||||
"name": "table_name",
|
||||
"name": "table.name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql_table_name') AS table_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql_operations' AND JSONExtractString(labels, 'postgresql_database_name') IN {{.db_name}}\nGROUP BY table_name",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql.table.name') AS `table.name`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql.operations' AND JSONExtractString(labels, 'postgresql.database.name') IN {{.db.name}}\nGROUP BY `table.name`",
|
||||
"selectedValue": [
|
||||
"public.activations",
|
||||
"public.licenses",
|
||||
@@ -160,9 +160,9 @@
|
||||
"key": "c66d1581-e5e1-440d-8ff6-ebcf078ab6dd",
|
||||
"modificationUUID": "564a3f43-98f8-4189-b5e4-dcb518d73852",
|
||||
"multiSelect": true,
|
||||
"name": "db_name",
|
||||
"name": "db.name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql_database_name') AS db_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql_operations'\nGROUP BY db_name",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'postgresql.database.name') AS `db.name`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'postgresql.operations'\nGROUP BY `db.name`",
|
||||
"selectedValue": [
|
||||
"postgres"
|
||||
],
|
||||
@@ -188,7 +188,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -199,22 +199,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'ins' AND host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'ins' AND host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -263,7 +263,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -274,22 +274,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'upd' AND host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'upd' AND host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -338,7 +338,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -349,22 +349,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'del' AND host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'del' AND host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -413,7 +413,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -424,22 +424,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'hot_upd' AND host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'hot_upd' AND host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -488,7 +488,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -499,15 +499,15 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(operation = 'ins' AND host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'ins' AND host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -523,7 +523,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -534,15 +534,15 @@
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "(operation = 'upd' AND host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'upd' AND host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -558,7 +558,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_operations",
|
||||
"metricName": "postgresql.operations",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -569,15 +569,15 @@
|
||||
"disabled": false,
|
||||
"expression": "C",
|
||||
"filter": {
|
||||
"expression": "(operation = 'del' AND host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(operation = 'del' AND host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -633,7 +633,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_database_locks",
|
||||
"metricName": "postgresql.database.locks",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -644,7 +644,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
@@ -708,7 +708,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_deadlocks",
|
||||
"metricName": "postgresql.deadlocks",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -719,22 +719,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -783,7 +783,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_backends",
|
||||
"metricName": "postgresql.backends",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -794,22 +794,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(host_name IN $host_name AND postgresql_database_name IN $db_name)"
|
||||
"expression": "(host.name IN $host.name AND postgresql.database.name IN $db.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_database_name--string--tag--false",
|
||||
"id": "postgresql.database.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_database_name",
|
||||
"key": "postgresql.database.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_database_name}}",
|
||||
"legend": "{{postgresql.database.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -858,7 +858,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_rows",
|
||||
"metricName": "postgresql.rows",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -869,7 +869,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(state = 'dead' AND host_name IN $host_name AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(state = 'dead' AND host.name IN $host.name AND postgresql.database.name IN $db.name AND postgresql.table.name IN $table.name)"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -924,7 +924,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_index_scans",
|
||||
"metricName": "postgresql.index.scans",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -935,22 +935,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(host_name IN $host_name AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(host.name IN $host.name AND postgresql.database.name IN $db.name AND postgresql.table.name IN $table.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_index_name--string--tag--false",
|
||||
"id": "postgresql.index.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_index_name",
|
||||
"key": "postgresql.index.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "{{postgresql_index_name}}",
|
||||
"legend": "{{postgresql.index.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -999,7 +999,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_rows",
|
||||
"metricName": "postgresql.rows",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -1010,15 +1010,15 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "(state = 'dead' AND host_name IN $host_name AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(state = 'dead' AND host.name IN $host.name AND postgresql.database.name IN $db.name AND postgresql.table.name IN $table.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -1034,7 +1034,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_rows",
|
||||
"metricName": "postgresql.rows",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -1045,15 +1045,15 @@
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "(state = 'live' AND host_name IN $host_name AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(state = 'live' AND host.name IN $host.name AND postgresql.database.name IN $db.name AND postgresql.table.name IN $table.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -1069,7 +1069,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_index_scans",
|
||||
"metricName": "postgresql.index.scans",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -1080,15 +1080,15 @@
|
||||
"disabled": false,
|
||||
"expression": "C",
|
||||
"filter": {
|
||||
"expression": "(host_name IN $host_name AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(host.name IN $host.name AND postgresql.database.name IN $db.name AND postgresql.table.name IN $table.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
@@ -1104,7 +1104,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "postgresql_table_size",
|
||||
"metricName": "postgresql.table.size",
|
||||
"reduceTo": "avg",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -1115,15 +1115,15 @@
|
||||
"disabled": false,
|
||||
"expression": "D",
|
||||
"filter": {
|
||||
"expression": "(host_name IN $host_name AND postgresql_database_name IN $db_name AND postgresql_table_name IN $table_name)"
|
||||
"expression": "(host.name IN $host.name AND postgresql.database.name IN $db.name AND postgresql.table.name IN $table.name)"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "postgresql_table_name--string--tag--false",
|
||||
"id": "postgresql.table.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "postgresql_table_name",
|
||||
"key": "postgresql.table.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -99,9 +99,9 @@
|
||||
"key": "94f19b3c-ad9f-4b47-a9b2-f312c09fa965",
|
||||
"modificationUUID": "4c5b0c03-9cbc-425b-8d8e-7152e5c39ba8",
|
||||
"multiSelect": true,
|
||||
"name": "host_name",
|
||||
"name": "host.name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host_name') AS host_name\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'redis_cpu_time'\nGROUP BY host_name",
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host.name') AS `host.name`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'redis.cpu.time'\nGROUP BY `host.name`",
|
||||
"selectedValue": [
|
||||
"Srikanths-MacBook-Pro.local"
|
||||
],
|
||||
@@ -127,7 +127,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_keyspace_hits",
|
||||
"metricName": "redis.keyspace.hits",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -138,7 +138,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -193,7 +193,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_clients_blocked",
|
||||
"metricName": "redis.clients.blocked",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -204,7 +204,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -259,7 +259,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_db_keys",
|
||||
"metricName": "redis.db.keys",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -322,7 +322,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_rdb_changes_since_last_save",
|
||||
"metricName": "redis.rdb.changes_since_last_save",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -333,7 +333,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -388,7 +388,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_commands",
|
||||
"metricName": "redis.commands",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -399,7 +399,7 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
@@ -454,7 +454,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_memory_used",
|
||||
"metricName": "redis.memory.used",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -465,22 +465,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host_name--string--tag--false",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host_name",
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Used::{{host_name}}",
|
||||
"legend": "Used::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -489,7 +489,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_maxmemory",
|
||||
"metricName": "redis.maxmemory",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
@@ -500,22 +500,22 @@
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host_name--string--tag--false",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host_name",
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Max::{{host_name}}",
|
||||
"legend": "Max::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "B",
|
||||
@@ -564,7 +564,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_memory_rss",
|
||||
"metricName": "redis.memory.rss",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -575,22 +575,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host_name--string--tag--false",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host_name",
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Rss::{{host_name}}",
|
||||
"legend": "Rss::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -639,7 +639,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_memory_fragmentation_ratio",
|
||||
"metricName": "redis.memory.fragmentation_ratio",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
@@ -650,22 +650,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host_name--string--tag--false",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host_name",
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Rss::{{host_name}}",
|
||||
"legend": "Rss::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
@@ -714,7 +714,7 @@
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis_keys_evicted",
|
||||
"metricName": "redis.keys.evicted",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
@@ -725,22 +725,22 @@
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host_name IN $host_name"
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host_name--string--tag--false",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host_name",
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Rss::{{host_name}}",
|
||||
"legend": "Rss::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
|
||||
@@ -1,779 +0,0 @@
|
||||
{
|
||||
"description": "This dashboard shows the Redis instance overview. It includes latency, hit/miss rate, connections, and memory information.\n",
|
||||
"id": "redis-overview",
|
||||
"layout": [
|
||||
{
|
||||
"h": 3,
|
||||
"i": "d4c164bc-8fc2-4dbc-aadd-8d17479ca649",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 9
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "2fbaef0d-3cdb-4ce3-aa3c-9bbbb41786d9",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 3,
|
||||
"y": 6
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "f5ee1511-0d2b-4404-9ce0-e991837decc2",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 6,
|
||||
"y": 3
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "b19c7058-b806-4ea2-974a-ca555b168991",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 3
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "bf0deeeb-e926-4234-944c-82bacd96af47",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 6,
|
||||
"y": 0
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "a77227c7-16f5-4353-952e-b183c715a61c",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 0
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "9698cee2-b1f3-4c0b-8c9f-3da4f0e05f17",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 6,
|
||||
"y": 9
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "64a5f303-d7db-44ff-9a0e-948e5c653320",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 0,
|
||||
"y": 12
|
||||
},
|
||||
{
|
||||
"h": 3,
|
||||
"i": "3e80a918-69af-4c9a-bc57-a94e1d41b05c",
|
||||
"moved": false,
|
||||
"static": false,
|
||||
"w": 6,
|
||||
"x": 6,
|
||||
"y": 12
|
||||
}
|
||||
],
|
||||
"name": "",
|
||||
"tags": [
|
||||
"redis",
|
||||
"database"
|
||||
],
|
||||
"title": "Redis overview",
|
||||
"variables": {
|
||||
"94f19b3c-ad9f-4b47-a9b2-f312c09fa965": {
|
||||
"allSelected": true,
|
||||
"customValue": "",
|
||||
"description": "List of hosts sending Redis metrics",
|
||||
"id": "94f19b3c-ad9f-4b47-a9b2-f312c09fa965",
|
||||
"key": "94f19b3c-ad9f-4b47-a9b2-f312c09fa965",
|
||||
"modificationUUID": "4c5b0c03-9cbc-425b-8d8e-7152e5c39ba8",
|
||||
"multiSelect": true,
|
||||
"name": "host.name",
|
||||
"order": 0,
|
||||
"queryValue": "SELECT JSONExtractString(labels, 'host.name') AS `host.name`\nFROM signoz_metrics.distributed_time_series_v4_1day\nWHERE metric_name = 'redis.cpu.time'\nGROUP BY `host.name`",
|
||||
"selectedValue": [
|
||||
"Srikanths-MacBook-Pro.local"
|
||||
],
|
||||
"showALLOption": true,
|
||||
"sort": "ASC",
|
||||
"textboxValue": "",
|
||||
"type": "QUERY"
|
||||
}
|
||||
},
|
||||
"version": "v5",
|
||||
"widgets": [
|
||||
{
|
||||
"description": "Rate successful lookup of keys in the main dictionary",
|
||||
"fillSpans": false,
|
||||
"id": "a77227c7-16f5-4353-952e-b183c715a61c",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.keyspace.hits",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "rate"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Hit/s across all hosts",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "42c9c117-bfaf-49f7-b528-aad099392295",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Hits/s",
|
||||
"yAxisUnit": "none"
|
||||
},
|
||||
{
|
||||
"description": "Number of clients pending on a blocking call",
|
||||
"fillSpans": false,
|
||||
"id": "bf0deeeb-e926-4234-944c-82bacd96af47",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.clients.blocked",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "sum"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Blocked clients across all hosts",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "b77a9e11-fb98-4a95-88a8-c3ad25c14369",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Clients blocked",
|
||||
"yAxisUnit": "none"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "b19c7058-b806-4ea2-974a-ca555b168991",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.db.keys",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "sum"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "b77a9e11-fb98-4a95-88a8-c3ad25c14369",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Keyspace Keys",
|
||||
"yAxisUnit": "none"
|
||||
},
|
||||
{
|
||||
"description": "Number of changes since the last dump",
|
||||
"fillSpans": false,
|
||||
"id": "f5ee1511-0d2b-4404-9ce0-e991837decc2",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.rdb.changes_since_last_save",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "sum"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Number of unsaved changes",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "32cedddf-606d-4de1-8c1d-4b7049e6430c",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Unsaved changes",
|
||||
"yAxisUnit": "none"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "2fbaef0d-3cdb-4ce3-aa3c-9bbbb41786d9",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.commands",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "sum"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "ops/s",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "c70de4dd-a68a-42df-a249-6610c296709c",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Command/s",
|
||||
"yAxisUnit": "ops"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "d4c164bc-8fc2-4dbc-aadd-8d17479ca649",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.memory.used",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "sum"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Used::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
},
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.maxmemory",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "max",
|
||||
"temporality": null,
|
||||
"timeAggregation": "max"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "B",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Max::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "B",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "2f47df76-f09e-4152-8623-971f0fe66bfe",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Memory usage",
|
||||
"yAxisUnit": "bytes"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "9698cee2-b1f3-4c0b-8c9f-3da4f0e05f17",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.memory.rss",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "sum"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Rss::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "fddd043c-1385-481c-9f4c-381f261e1dd9",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "RSS Memory",
|
||||
"yAxisUnit": "bytes"
|
||||
},
|
||||
{
|
||||
"description": "",
|
||||
"fillSpans": false,
|
||||
"id": "64a5f303-d7db-44ff-9a0e-948e5c653320",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.memory.fragmentation_ratio",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "avg",
|
||||
"temporality": null,
|
||||
"timeAggregation": "avg"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Rss::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "3e802b07-0249-4d79-a5c7-6580ab535ad0",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Fragmentation ratio",
|
||||
"yAxisUnit": "short"
|
||||
},
|
||||
{
|
||||
"description": "Number of evicted keys due to maxmemory limit",
|
||||
"fillSpans": false,
|
||||
"id": "3e80a918-69af-4c9a-bc57-a94e1d41b05c",
|
||||
"isStacked": false,
|
||||
"nullZeroValues": "zero",
|
||||
"opacity": "1",
|
||||
"panelTypes": "graph",
|
||||
"query": {
|
||||
"builder": {
|
||||
"queryData": [
|
||||
{
|
||||
"aggregations": [
|
||||
{
|
||||
"metricName": "redis.keys.evicted",
|
||||
"reduceTo": "sum",
|
||||
"spaceAggregation": "sum",
|
||||
"temporality": null,
|
||||
"timeAggregation": "rate"
|
||||
}
|
||||
],
|
||||
"dataSource": "metrics",
|
||||
"disabled": false,
|
||||
"expression": "A",
|
||||
"filter": {
|
||||
"expression": "host.name IN $host.name"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
"dataType": "string",
|
||||
"id": "host.name--string--tag--false",
|
||||
"isColumn": false,
|
||||
"isJSON": false,
|
||||
"key": "host.name",
|
||||
"type": "tag"
|
||||
}
|
||||
],
|
||||
"having": {
|
||||
"expression": ""
|
||||
},
|
||||
"legend": "Rss::{{host.name}}",
|
||||
"limit": null,
|
||||
"orderBy": [],
|
||||
"queryName": "A",
|
||||
"stepInterval": 60
|
||||
}
|
||||
],
|
||||
"queryFormulas": []
|
||||
},
|
||||
"clickhouse_sql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"id": "15d1d9d7-eb10-464b-aa7b-33ff211996f7",
|
||||
"promql": [
|
||||
{
|
||||
"disabled": false,
|
||||
"legend": "",
|
||||
"name": "A",
|
||||
"query": ""
|
||||
}
|
||||
],
|
||||
"queryType": "builder"
|
||||
},
|
||||
"softMax": null,
|
||||
"softMin": null,
|
||||
"thresholds": [],
|
||||
"timePreferance": "GLOBAL_TIME",
|
||||
"title": "Eviction rate",
|
||||
"yAxisUnit": "short"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -4,6 +4,8 @@ import (
|
||||
"context"
|
||||
"fmt"
|
||||
"log/slog"
|
||||
"net/url"
|
||||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
@@ -23,7 +25,7 @@ type BaseRule struct {
|
||||
id string
|
||||
name string
|
||||
orgID valuer.UUID
|
||||
source string
|
||||
externalURL *url.URL
|
||||
handledRestart bool
|
||||
|
||||
// Type of the rule
|
||||
@@ -138,6 +140,15 @@ func WithRuleStateHistoryModule(module rulestatehistory.Module) RuleOption {
|
||||
}
|
||||
}
|
||||
|
||||
// WithExternalURL injects the alertmanager external URL
|
||||
// (SIGNOZ_ALERTMANAGER_SIGNOZ_EXTERNAL__URL) which is used as the host for
|
||||
// related logs/traces links and the rule generator URL in alert notifications.
|
||||
func WithExternalURL(externalURL *url.URL) RuleOption {
|
||||
return func(r *BaseRule) {
|
||||
r.externalURL = externalURL
|
||||
}
|
||||
}
|
||||
|
||||
func NewBaseRule(id string, orgID valuer.UUID, p *ruletypes.PostableRule, opts ...RuleOption) (*BaseRule, error) {
|
||||
threshold, err := p.RuleCondition.Thresholds.GetRuleThreshold()
|
||||
if err != nil {
|
||||
@@ -152,7 +163,6 @@ func NewBaseRule(id string, orgID valuer.UUID, p *ruletypes.PostableRule, opts .
|
||||
id: id,
|
||||
orgID: orgID,
|
||||
name: p.AlertName,
|
||||
source: p.Source,
|
||||
typ: p.AlertType,
|
||||
ruleCondition: p.RuleCondition,
|
||||
evalWindow: p.EvalWindow,
|
||||
@@ -241,7 +251,18 @@ func (r *BaseRule) Annotations() ruletypes.Labels { return r.annotations }
|
||||
func (r *BaseRule) PreferredChannels() []string { return r.preferredChannels }
|
||||
|
||||
func (r *BaseRule) GeneratorURL() string {
|
||||
return ruletypes.PrepareRuleGeneratorURL(r.ID(), r.source)
|
||||
return fmt.Sprintf("%s/alerts/edit?ruleId=%s", r.ExternalURLHost(), r.ID())
|
||||
}
|
||||
|
||||
// ExternalURLHost returns the configured alertmanager external URL
|
||||
// (SIGNOZ_ALERTMANAGER_SIGNOZ_EXTERNAL__URL), trimmed of any trailing slash.
|
||||
// It is used as the host portion of rule-related URLs (generator URL and
|
||||
// related logs/traces links) in alert notifications.
|
||||
func (r *BaseRule) ExternalURLHost() string {
|
||||
if r.externalURL == nil {
|
||||
return ""
|
||||
}
|
||||
return strings.TrimRight(r.externalURL.String(), "/")
|
||||
}
|
||||
|
||||
func (r *BaseRule) SelectedQuery(ctx context.Context) string {
|
||||
|
||||
@@ -3,6 +3,7 @@ package rules
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"net/url"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -723,6 +724,68 @@ func TestBaseRule_FilterNewSeries(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestBaseRule_ExternalURLHost(t *testing.T) {
|
||||
mustParse := func(raw string) *url.URL {
|
||||
u, err := url.Parse(raw)
|
||||
require.NoError(t, err)
|
||||
return u
|
||||
}
|
||||
|
||||
tests := []struct {
|
||||
name string
|
||||
externalURL *url.URL
|
||||
want string
|
||||
}{
|
||||
{name: "nil URL returns empty", externalURL: nil, want: ""},
|
||||
{name: "default value returned as-is", externalURL: mustParse("http://localhost:8080"), want: "http://localhost:8080"},
|
||||
{name: "configured https host", externalURL: mustParse("https://signoz.example.com"), want: "https://signoz.example.com"},
|
||||
{name: "configured host with port", externalURL: mustParse("http://signoz.internal:3301"), want: "http://signoz.internal:3301"},
|
||||
{name: "trailing slash is trimmed", externalURL: mustParse("https://signoz.example.com/"), want: "https://signoz.example.com"},
|
||||
}
|
||||
|
||||
for _, tc := range tests {
|
||||
t.Run(tc.name, func(t *testing.T) {
|
||||
r := &BaseRule{externalURL: tc.externalURL}
|
||||
require.Equal(t, tc.want, r.ExternalURLHost())
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
func TestBaseRule_GeneratorURL(t *testing.T) {
|
||||
mustParse := func(raw string) *url.URL {
|
||||
u, err := url.Parse(raw)
|
||||
require.NoError(t, err)
|
||||
return u
|
||||
}
|
||||
|
||||
tests := []struct {
|
||||
name string
|
||||
ruleID string
|
||||
externalURL *url.URL
|
||||
want string
|
||||
}{
|
||||
{
|
||||
name: "configured external URL",
|
||||
ruleID: "abc",
|
||||
externalURL: mustParse("https://signoz.example.com"),
|
||||
want: "https://signoz.example.com/alerts/edit?ruleId=abc",
|
||||
},
|
||||
{
|
||||
name: "default external URL is used as-is",
|
||||
ruleID: "abc",
|
||||
externalURL: mustParse("http://localhost:8080"),
|
||||
want: "http://localhost:8080/alerts/edit?ruleId=abc",
|
||||
},
|
||||
}
|
||||
|
||||
for _, tc := range tests {
|
||||
t.Run(tc.name, func(t *testing.T) {
|
||||
r := &BaseRule{id: tc.ruleID, externalURL: tc.externalURL}
|
||||
require.Equal(t, tc.want, r.GeneratorURL())
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
// labelsKey creates a deterministic string key from a labels map
|
||||
// This is used to group series by their unique label combinations
|
||||
func labelsKey(lbls []*qbtypes.Label) string {
|
||||
|
||||
@@ -5,6 +5,7 @@ import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"log/slog"
|
||||
"net/url"
|
||||
"sort"
|
||||
"strings"
|
||||
"sync"
|
||||
@@ -80,6 +81,11 @@ type ManagerOptions struct {
|
||||
|
||||
EvalDelay valuer.TextDuration
|
||||
|
||||
// ExternalURL is the alertmanager external URL
|
||||
// (SIGNOZ_ALERTMANAGER_SIGNOZ_EXTERNAL__URL). Rules use it as the host for
|
||||
// generator URLs and related logs/traces links in alert notifications.
|
||||
ExternalURL *url.URL
|
||||
|
||||
RuleStateHistoryModule rulestatehistory.Module
|
||||
|
||||
PrepareTaskFunc func(opts PrepareTaskOptions) (Task, error)
|
||||
@@ -155,6 +161,7 @@ func defaultPrepareTaskFunc(opts PrepareTaskOptions) (Task, error) {
|
||||
WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
WithRuleStateHistoryModule(opts.ManagerOpts.RuleStateHistoryModule),
|
||||
WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
if err != nil {
|
||||
return task, err
|
||||
@@ -178,6 +185,7 @@ func defaultPrepareTaskFunc(opts PrepareTaskOptions) (Task, error) {
|
||||
WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
WithRuleStateHistoryModule(opts.ManagerOpts.RuleStateHistoryModule),
|
||||
WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
if err != nil {
|
||||
return task, err
|
||||
|
||||
@@ -54,6 +54,7 @@ func defaultTestNotification(opts PrepareTestRuleOptions) (int, error) {
|
||||
WithSQLStore(opts.SQLStore),
|
||||
WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
@@ -75,6 +76,7 @@ func defaultTestNotification(opts PrepareTestRuleOptions) (int, error) {
|
||||
WithSQLStore(opts.SQLStore),
|
||||
WithQueryParser(opts.ManagerOpts.QueryParser),
|
||||
WithMetadataStore(opts.ManagerOpts.MetadataStore),
|
||||
WithExternalURL(opts.ManagerOpts.ExternalURL),
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
|
||||
@@ -5,7 +5,6 @@ import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"log/slog"
|
||||
"net/url"
|
||||
"reflect"
|
||||
"time"
|
||||
|
||||
@@ -55,17 +54,6 @@ func NewThresholdRule(
|
||||
}, nil
|
||||
}
|
||||
|
||||
func (r *ThresholdRule) hostFromSource() string {
|
||||
parsedURL, err := url.Parse(r.source)
|
||||
if err != nil {
|
||||
return ""
|
||||
}
|
||||
if parsedURL.Port() != "" {
|
||||
return fmt.Sprintf("%s://%s:%s", parsedURL.Scheme, parsedURL.Hostname(), parsedURL.Port())
|
||||
}
|
||||
return fmt.Sprintf("%s://%s", parsedURL.Scheme, parsedURL.Hostname())
|
||||
}
|
||||
|
||||
func (r *ThresholdRule) Type() ruletypes.RuleType {
|
||||
return ruletypes.RuleTypeThreshold
|
||||
}
|
||||
@@ -350,15 +338,15 @@ func (r *ThresholdRule) Eval(ctx context.Context, ts time.Time) (int, error) {
|
||||
switch r.typ {
|
||||
case ruletypes.AlertTypeTraces:
|
||||
link := r.prepareLinksToTraces(ctx, ts, smpl.Metric)
|
||||
if link != "" && r.hostFromSource() != "" {
|
||||
r.logger.InfoContext(ctx, "adding traces link to annotations", slog.String("annotation.link", fmt.Sprintf("%s/traces-explorer?%s", r.hostFromSource(), link)))
|
||||
annotations = append(annotations, ruletypes.Label{Name: "related_traces", Value: fmt.Sprintf("%s/traces-explorer?%s", r.hostFromSource(), link)})
|
||||
if link != "" && r.ExternalURLHost() != "" {
|
||||
r.logger.InfoContext(ctx, "adding traces link to annotations", slog.String("annotation.link", fmt.Sprintf("%s/traces-explorer?%s", r.ExternalURLHost(), link)))
|
||||
annotations = append(annotations, ruletypes.Label{Name: "related_traces", Value: fmt.Sprintf("%s/traces-explorer?%s", r.ExternalURLHost(), link)})
|
||||
}
|
||||
case ruletypes.AlertTypeLogs:
|
||||
link := r.prepareLinksToLogs(ctx, ts, smpl.Metric)
|
||||
if link != "" && r.hostFromSource() != "" {
|
||||
r.logger.InfoContext(ctx, "adding logs link to annotations", slog.String("annotation.link", fmt.Sprintf("%s/logs/logs-explorer?%s", r.hostFromSource(), link)))
|
||||
annotations = append(annotations, ruletypes.Label{Name: "related_logs", Value: fmt.Sprintf("%s/logs/logs-explorer?%s", r.hostFromSource(), link)})
|
||||
if link != "" && r.ExternalURLHost() != "" {
|
||||
r.logger.InfoContext(ctx, "adding logs link to annotations", slog.String("annotation.link", fmt.Sprintf("%s/logs/logs-explorer?%s", r.ExternalURLHost(), link)))
|
||||
annotations = append(annotations, ruletypes.Label{Name: "related_logs", Value: fmt.Sprintf("%s/logs/logs-explorer?%s", r.ExternalURLHost(), link)})
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@ package signozruler
|
||||
|
||||
import (
|
||||
"context"
|
||||
"net/url"
|
||||
|
||||
"github.com/SigNoz/signoz/pkg/alertmanager"
|
||||
"github.com/SigNoz/signoz/pkg/alertmanager/alertmanagerstore/sqlalertmanagerstore"
|
||||
@@ -41,6 +42,7 @@ func NewFactory(
|
||||
ruleStateHistoryModule rulestatehistory.Module,
|
||||
querier querier.Querier,
|
||||
queryParser queryparser.QueryParser,
|
||||
externalURL *url.URL,
|
||||
prepareTaskFunc func(rules.PrepareTaskOptions) (rules.Task, error),
|
||||
prepareTestRuleFunc func(rules.PrepareTestRuleOptions) (int, error),
|
||||
) factory.ProviderFactory[ruler.Ruler, ruler.Config] {
|
||||
@@ -57,6 +59,7 @@ func NewFactory(
|
||||
Logger: providerSettings.Logger,
|
||||
Cache: cache,
|
||||
EvalDelay: valuer.MustParseTextDuration(config.EvalDelay.String()),
|
||||
ExternalURL: externalURL,
|
||||
PrepareTaskFunc: prepareTaskFunc,
|
||||
PrepareTestRuleFunc: prepareTestRuleFunc,
|
||||
Alertmanager: alertmanager,
|
||||
|
||||
@@ -3,6 +3,7 @@ package signoz
|
||||
import (
|
||||
"context"
|
||||
"log/slog"
|
||||
"net/url"
|
||||
|
||||
"github.com/SigNoz/signoz/pkg/alertmanager"
|
||||
"github.com/SigNoz/signoz/pkg/alertmanager/alertmanagerstore/sqlalertmanagerstore"
|
||||
@@ -113,7 +114,7 @@ func New(
|
||||
meterReporterProviderFactories func(context.Context, factory.ProviderSettings, flagger.Flagger, licensing.Licensing, telemetrystore.TelemetryStore, retention.Getter, organization.Getter, zeus.Zeus) (factory.NamedMap[factory.ProviderFactory[meterreporter.Reporter, meterreporter.Config]], string),
|
||||
querierHandlerCallback func(factory.ProviderSettings, querier.Querier, analytics.Analytics) querier.Handler,
|
||||
cloudIntegrationCallback func(sqlstore.SQLStore, global.Global, zeus.Zeus, gateway.Gateway, licensing.Licensing, serviceaccount.Module, cloudintegration.Config) (cloudintegration.Module, error),
|
||||
rulerProviderFactories func(cache.Cache, alertmanager.Alertmanager, sqlstore.SQLStore, telemetrystore.TelemetryStore, telemetrytypes.MetadataStore, prometheus.Prometheus, organization.Getter, rulestatehistory.Module, querier.Querier, queryparser.QueryParser) factory.NamedMap[factory.ProviderFactory[ruler.Ruler, ruler.Config]],
|
||||
rulerProviderFactories func(cache.Cache, alertmanager.Alertmanager, sqlstore.SQLStore, telemetrystore.TelemetryStore, telemetrytypes.MetadataStore, prometheus.Prometheus, organization.Getter, rulestatehistory.Module, querier.Querier, queryparser.QueryParser, *url.URL) factory.NamedMap[factory.ProviderFactory[ruler.Ruler, ruler.Config]],
|
||||
) (*SigNoz, error) {
|
||||
// Initialize instrumentation
|
||||
instrumentation, err := instrumentation.New(ctx, config.Instrumentation, version.Info, "signoz")
|
||||
@@ -467,7 +468,7 @@ func New(
|
||||
modules := NewModules(sqlstore, tokenizer, emailing, providerSettings, orgGetter, alertmanager, analytics, querier, telemetrystore, telemetryMetadataStore, authNs, authz, cache, queryParser, config, dashboard, userGetter, userRoleStore, serviceAccount, cloudIntegrationModule, retentionGetter, flagger, tagModule)
|
||||
|
||||
// Initialize ruler from the variant-specific provider factories
|
||||
rulerInstance, err := factory.NewProviderFromNamedMap(ctx, providerSettings, config.Ruler, rulerProviderFactories(cache, alertmanager, sqlstore, telemetrystore, telemetryMetadataStore, prometheus, orgGetter, modules.RuleStateHistory, querier, queryParser), "signoz")
|
||||
rulerInstance, err := factory.NewProviderFromNamedMap(ctx, providerSettings, config.Ruler, rulerProviderFactories(cache, alertmanager, sqlstore, telemetrystore, telemetryMetadataStore, prometheus, orgGetter, modules.RuleStateHistory, querier, queryParser, config.Alertmanager.Signoz.ExternalURL), "signoz")
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
@@ -2,10 +2,7 @@ package ruletypes
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"net/url"
|
||||
"sort"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
qbtypes "github.com/SigNoz/signoz/pkg/types/querybuildertypes/querybuildertypesv5"
|
||||
@@ -191,35 +188,3 @@ func (rc *RuleCondition) String() string {
|
||||
return string(data)
|
||||
}
|
||||
|
||||
// PrepareRuleGeneratorURL creates an appropriate url for the rule. The URL is
|
||||
// sent in Slack messages as well as to other systems and allows backtracking
|
||||
// to the rule definition from the third party systems.
|
||||
func PrepareRuleGeneratorURL(ruleID string, source string) string {
|
||||
if source == "" {
|
||||
return source
|
||||
}
|
||||
|
||||
// check if source is a valid url
|
||||
parsedSource, err := url.Parse(source)
|
||||
if err != nil {
|
||||
return ""
|
||||
}
|
||||
// since we capture window.location when a new rule is created
|
||||
// we end up with rulesource host:port/alerts/new. in this case
|
||||
// we want to replace new with rule id parameter
|
||||
|
||||
hasNew := strings.LastIndex(source, "new")
|
||||
if hasNew > -1 {
|
||||
ruleURL := fmt.Sprintf("%sedit?ruleId=%s", source[0:hasNew], ruleID)
|
||||
return ruleURL
|
||||
}
|
||||
|
||||
// The source contains the encoded query, start and end time
|
||||
// and other parameters. We don't want to include them in the generator URL
|
||||
// mainly to keep the URL short and lower the alert body contents
|
||||
// The generator URL with /alerts/edit?ruleId= is enough
|
||||
if parsedSource.Port() != "" {
|
||||
return fmt.Sprintf("%s://%s:%s/alerts/edit?ruleId=%s", parsedSource.Scheme, parsedSource.Hostname(), parsedSource.Port(), ruleID)
|
||||
}
|
||||
return fmt.Sprintf("%s://%s/alerts/edit?ruleId=%s", parsedSource.Scheme, parsedSource.Hostname(), ruleID)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user