Skip to content

Commit

Permalink
Merge pull request #398 from bartoval/rename_paths
Browse files Browse the repository at this point in the history
refactor(General): ♻️ Convert API relative paths in absolute
  • Loading branch information
bartoval authored Apr 18, 2024
2 parents d0eec66 + 4b4a804 commit cafcbb7
Show file tree
Hide file tree
Showing 15 changed files with 150 additions and 150 deletions.
24 changes: 12 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,30 +38,30 @@
"dependencies": {
"@antv/g6": "^4.8.24",
"@nivo/sankey": "^0.85.1",
"@patternfly/patternfly": "^5.2.1",
"@patternfly/react-charts": "^7.2.2",
"@patternfly/react-core": "^5.2.3",
"@patternfly/react-icons": "^5.2.1",
"@patternfly/react-table": "5.2.4",
"@patternfly/patternfly": "^5.3.0",
"@patternfly/react-charts": "^7.3.0",
"@patternfly/react-core": "^5.3.0",
"@patternfly/react-icons": "^5.3.0",
"@patternfly/react-table": "5.3.0",
"@tanstack/react-query": "^5.29.2",
"axios": "^1.6.8",
"date-fns": "^3.6.0",
"framer-motion": "^11.0.28",
"framer-motion": "^11.1.5",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-error-boundary": "^4.0.13",
"react-router-dom": "^6.22.3"
},
"devDependencies": {
"@commitlint/cli": "^19.2.1",
"@commitlint/config-conventional": "^19.1.0",
"@commitlint/cli": "^19.2.2",
"@commitlint/config-conventional": "^19.2.2",
"@testing-library/dom": "^10.0.0",
"@testing-library/jest-dom": "^6.4.2",
"@testing-library/react": "^15.0.1",
"@testing-library/react": "^15.0.2",
"@testing-library/user-event": "^14.5.2",
"@types/jest": "^29.5.12",
"@typescript-eslint/eslint-plugin": "^7.6.0",
"@typescript-eslint/parser": "^7.6.0",
"@typescript-eslint/eslint-plugin": "^7.7.0",
"@typescript-eslint/parser": "^7.7.0",
"circular-dependency-plugin": "^5.2.2",
"commitizen": "^4.3.0",
"copy-webpack-plugin": "^12.0.2",
Expand All @@ -80,7 +80,7 @@
"husky": "^9.0.11",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"mini-css-extract-plugin": "^2.8.1",
"mini-css-extract-plugin": "^2.9.0",
"miragejs": "^0.1.48",
"prettier": "^3.2.5",
"start-server-and-test": "^2.0.3",
Expand Down
2 changes: 1 addition & 1 deletion src/pages/ProcessGroups/ProcessGroups.constants.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ProcessGroupResponse } from '@API/REST.interfaces';
import LinkCell from '@core/components/LinkCell';
import { LinkCellProps } from '@core/components/LinkCell/LinkCell.interfaces';
import { SKColumn } from '@core/components/SkTable/SkTable.interfaces';
import { ProcessGroupResponse } from 'API/REST.interfaces';

import { ProcessGroupsLabels, ProcessGroupsRoutesPaths } from './ProcessGroups.enum';

Expand Down
2 changes: 1 addition & 1 deletion src/pages/ProcessGroups/views/ProcessGroups.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ import { useCallback, useState, startTransition } from 'react';
import { useSuspenseQuery } from '@tanstack/react-query';

import { RESTApi } from '@API/REST.api';
import { RemoteFilterOptions } from '@API/REST.interfaces';
import { BIG_PAGINATION_SIZE, UPDATE_INTERVAL } from '@config/config';
import { getTestsIds } from '@config/testIds';
import SkTable from '@core/components/SkTable';
import MainContainer from '@layout/MainContainer';
import { TopologyRoutesPaths, TopologyViews } from '@pages/Topology/Topology.enum';
import { RemoteFilterOptions } from 'API/REST.interfaces';

import { CustomComponentCells, processGroupsColumns } from '../ProcessGroups.constants';
import { ProcessGroupsLabels, QueriesProcessGroups } from '../ProcessGroups.enum';
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Processes/Processes.constants.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { ProcessPairsResponse, FlowPairsResponse, ProcessResponse } from '@API/REST.interfaces';
import HighlightValueCell from '@core/components/HighlightValueCell';
import { HighlightValueCellProps } from '@core/components/HighlightValueCell/HighightValueCell.interfaces';
import LinkCell from '@core/components/LinkCell';
Expand All @@ -10,7 +11,6 @@ import { ProcessGroupsRoutesPaths } from '@pages/ProcessGroups/ProcessGroups.enu
import { httpFlowPairsColumns, tcpFlowPairsColumns } from '@pages/shared/FlowPairs/FlowPair.constants';
import { FlowPairLabels } from '@pages/shared/FlowPairs/FlowPair.enum';
import { SitesRoutesPaths } from '@pages/Sites/Sites.enum';
import { ProcessPairsResponse, FlowPairsResponse, ProcessResponse } from 'API/REST.interfaces';

import { ProcessesLabels, ProcessesRoutesPaths } from './Processes.enum';

Expand Down
2 changes: 1 addition & 1 deletion src/pages/Processes/components/ProcessPairsFlows.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ import { useSuspenseQuery } from '@tanstack/react-query';

import { RESTApi } from '@API/REST.api';
import { AvailableProtocols, SortDirection, TcpStatus } from '@API/REST.enum';
import { RemoteFilterOptions } from '@API/REST.interfaces';
import { DEFAULT_PAGINATION_SIZE, UPDATE_INTERVAL } from '@config/config';
import EmptyData from '@core/components/EmptyData';
import FlowPairs from '@pages/shared/FlowPairs';
import { TopologyURLQueyParams } from '@pages/Topology/Topology.enum';
import { RemoteFilterOptions } from 'API/REST.interfaces';
import useUpdateQueryStringValueWithoutNavigation from 'hooks/useUpdateQueryStringValueWithoutNavigation';

import { activeTcpColumns, httpColumns, oldTcpColumns } from '../Processes.constants';
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Processes/views/Processes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ import { startTransition, useCallback, useState } from 'react';
import { useSuspenseQuery } from '@tanstack/react-query';

import { RESTApi } from '@API/REST.api';
import { RemoteFilterOptions } from '@API/REST.interfaces';
import { BIG_PAGINATION_SIZE, UPDATE_INTERVAL } from '@config/config';
import { getTestsIds } from '@config/testIds';
import SkSearchFilter from '@core/components/SkSearchFilter';
import SkTable from '@core/components/SkTable';
import MainContainer from '@layout/MainContainer';
import { TopologyRoutesPaths, TopologyViews } from '@pages/Topology/Topology.enum';
import { RemoteFilterOptions } from 'API/REST.interfaces';

import { CustomProcessCells, processesSelectOptions, processesTableColumns } from '../Processes.constants';
import { ProcessesLabels, QueriesProcesses } from '../Processes.enum';
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Services/Services.constants.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { SortDirection, TcpStatus } from '@API/REST.enum';
import { ServiceResponse, ProcessResponse, RemoteFilterOptions } from '@API/REST.interfaces';
import { BIG_PAGINATION_SIZE } from '@config/config';
import LinkCell from '@core/components/LinkCell';
import { LinkCellProps } from '@core/components/LinkCell/LinkCell.interfaces';
Expand All @@ -8,7 +9,6 @@ import { timeAgo } from '@core/utils/timeAgo';
import { ProcessesLabels } from '@pages/Processes/Processes.enum';
import { httpFlowPairsColumns, tcpFlowPairsColumns } from '@pages/shared/FlowPairs/FlowPair.constants';
import { FlowPairLabels } from '@pages/shared/FlowPairs/FlowPair.enum';
import { ServiceResponse, ProcessResponse, RemoteFilterOptions } from 'API/REST.interfaces';

import { ServicesRoutesPaths, ServicesLabels } from './Services.enum';

Expand Down
2 changes: 1 addition & 1 deletion src/pages/Services/components/FlowPairsService.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ import { FC, useCallback, useState, startTransition } from 'react';
import { useSuspenseQuery } from '@tanstack/react-query';

import { RESTApi } from '@API/REST.api';
import { FlowPairsResponse, RemoteFilterOptions } from '@API/REST.interfaces';
import { BIG_PAGINATION_SIZE, UPDATE_INTERVAL } from '@config/config';
import SkSearchFilter from '@core/components/SkSearchFilter';
import { SKColumn } from '@core/components/SkTable/SkTable.interfaces';
import FlowPairs from '@pages/shared/FlowPairs';
import { FlowPairsResponse, RemoteFilterOptions } from 'API/REST.interfaces';

import { QueriesServices } from '../Services.enum';

Expand Down
4 changes: 2 additions & 2 deletions src/pages/Services/services/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { PrometheusMetric } from '@API/Prometheus.interfaces';
import { ServiceResponse } from '@API/REST.interfaces';
import { VarColors } from '@config/colors';
import { prometheusSiteNameAndIdSeparator } from '@config/prometheus';
import { DEFAULT_SANKEY_CHART_FLOW_VALUE } from '@core/components/SKSanckeyChart/SkSankey.constants';
import { PrometheusMetric } from 'API/Prometheus.interfaces';
import { ServiceResponse } from 'API/REST.interfaces';

export const ServicesController = {
extendServicesWithActiveAndTotalFlowPairs: (
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Sites/services/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { LinkResponse, SiteResponse } from 'API/REST.interfaces';
import { LinkResponse, SiteResponse } from '@API/REST.interfaces';

import { SiteWithLinks } from '../Sites.interfaces';

Expand Down
2 changes: 1 addition & 1 deletion src/pages/Sites/views/Sites.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import { useSuspenseQuery } from '@tanstack/react-query';

import { RESTApi } from '@API/REST.api';
import { SiteResponse } from '@API/REST.interfaces';
import { BIG_PAGINATION_SIZE, UPDATE_INTERVAL } from '@config/config';
import { getTestsIds } from '@config/testIds';
import LinkCell from '@core/components/LinkCell';
import { LinkCellProps } from '@core/components/LinkCell/LinkCell.interfaces';
import SkTable from '@core/components/SkTable';
import MainContainer from '@layout/MainContainer';
import { TopologyRoutesPaths, TopologyViews } from '@pages/Topology/Topology.enum';
import { SiteResponse } from 'API/REST.interfaces';

import { siteColumns } from '../Sites.constants';
import { SiteLabels, SitesRoutesPaths, QueriesSites } from '../Sites.enum';
Expand Down
16 changes: 8 additions & 8 deletions src/pages/Topology/services/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
import { PrometheusApi } from '@API/Prometheus.api';
import { PrometheusMetric } from '@API/Prometheus.interfaces';
import {
ProcessPairsResponse,
LinkResponse,
ProcessGroupResponse,
ProcessResponse,
SiteResponse,
SitePairsResponse
} from '@API/REST.interfaces';
import componentIcon from '@assets/component.svg';
import kubernetesIcon from '@assets/kubernetes.svg';
import podmanIcon from '@assets/podman.png';
Expand All @@ -18,14 +26,6 @@ import { formatByteRate, formatBytes } from '@core/utils/formatBytes';
import { formatLatency } from '@core/utils/formatLatency';
import { removeDuplicatesFromArrayOfObjects } from '@core/utils/removeDuplicatesFromArrayOfObjects';
import SitesController from '@pages/Sites/services';
import {
ProcessPairsResponse,
LinkResponse,
ProcessGroupResponse,
ProcessResponse,
SiteResponse,
SitePairsResponse
} from 'API/REST.interfaces';

import { TopologyLabels } from '../Topology.enum';
import {
Expand Down
2 changes: 1 addition & 1 deletion src/pages/shared/FlowPairs/FlowPair.constants.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { FlowPairsResponse } from '@API/REST.interfaces';
import DurationCell from '@core/components/DurationCell';
import HighlightValueCell from '@core/components/HighlightValueCell';
import { HighlightValueCellProps } from '@core/components/HighlightValueCell/HighightValueCell.interfaces';
Expand All @@ -9,7 +10,6 @@ import { formatLatency } from '@core/utils/formatLatency';
import { timeAgo } from '@core/utils/timeAgo';
import { ProcessesRoutesPaths } from '@pages/Processes/Processes.enum';
import { SitesRoutesPaths } from '@pages/Sites/Sites.enum';
import { FlowPairsResponse } from 'API/REST.interfaces';

import { FlowPairLabels } from './FlowPair.enum';

Expand Down
2 changes: 1 addition & 1 deletion src/pages/shared/Metrics/services/services.interfaces.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { PrometheusMetric } from '@API/Prometheus.interfaces';
import { skAxisXY } from '@core/components/SkChartArea/SkChartArea.interfaces';
import { PrometheusMetric } from 'API/Prometheus.interfaces';

interface StatusCodeResponse {
label: string;
Expand Down
Loading

0 comments on commit cafcbb7

Please sign in to comment.