{
expect(pushMock).toHaveBeenCalledWith(Pages.databaseAnalysis('instanceId'))
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_DATABASE_ANALYSIS_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_DATABASE_ANALYSIS_CLICKED,
eventData: {
databaseId: 'instanceId',
total: 1,
@@ -151,7 +151,7 @@ describe('LiveTimeRecommendations', () => {
fireEvent.click(queryByTestId('checkbox-show-hidden')!)
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_SHOW_HIDDEN,
+ event: TelemetryEvent.INSIGHTS_TIPS_SHOW_HIDDEN,
eventData: {
databaseId: 'instanceId',
list: RECOMMENDATIONS_DATA_MOCK.recommendations?.map(({ name }) =>
diff --git a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/LiveTimeRecommendations.tsx b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/LiveTimeRecommendations.tsx
index 42514e1196..54dbb78a69 100644
--- a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/LiveTimeRecommendations.tsx
+++ b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/LiveTimeRecommendations.tsx
@@ -69,7 +69,7 @@ const LiveTimeRecommendations = () => {
dispatch(createNewAnalysis(instanceId, delimiter))
history.push(Pages.databaseAnalysis(instanceId))
sendEventTelemetry({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_DATABASE_ANALYSIS_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_DATABASE_ANALYSIS_CLICKED,
eventData: {
databaseId: instanceId,
total: recommendations?.length,
@@ -83,7 +83,7 @@ const LiveTimeRecommendations = () => {
dispatch(setRecommendationsShowHidden(value))
sendEventTelemetry({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_SHOW_HIDDEN,
+ event: TelemetryEvent.INSIGHTS_TIPS_SHOW_HIDDEN,
eventData: {
action: !value ? 'hide' : 'show',
...getTelemetryData(recommendations)
@@ -129,19 +129,19 @@ const LiveTimeRecommendations = () => {
{!!recommendations.length && (
- Our Recommendations
+ Our Tips
- Recommendations will help you improve your database.
+ Tips will help you improve your database.
- New recommendations appear while you work with your database,
+ New tips appear while you work with your database,
including how to improve performance and optimize memory usage.
- Eager for more recommendations? Run Database Analysis to get started.
+ Eager for more tips? Run Database Analysis to get started.
>
)}
>
@@ -220,7 +220,7 @@ const LiveTimeRecommendations = () => {
Database Analysis
- {' to get more recommendations'}
+ {' to get more tips'}
diff --git a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.spec.tsx b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.spec.tsx
index 7979d7781f..7571b2bf61 100644
--- a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.spec.tsx
+++ b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.spec.tsx
@@ -77,7 +77,7 @@ describe('Recommendation', () => {
expect(pushMock).toHaveBeenCalledWith({ search: 'guidePath=' })
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_TUTORIAL_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_TUTORIAL_CLICKED,
eventData: {
databaseId: INSTANCE_ID_MOCK,
name: 'searchJSON',
@@ -110,7 +110,7 @@ describe('Recommendation', () => {
search: 'guidePath=quick-guides/working-with-hash.html'
})
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_TUTORIAL_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_TUTORIAL_CLICKED,
eventData: {
databaseId: INSTANCE_ID_MOCK,
name: 'searchJSON',
@@ -144,7 +144,7 @@ describe('Recommendation', () => {
search: 'guidePath=/redis_stack/working_with_json.md'
})
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_TUTORIAL_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_TUTORIAL_CLICKED,
eventData: {
databaseId: INSTANCE_ID_MOCK,
name: 'searchJSON',
diff --git a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.tsx b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.tsx
index f02cd6e7be..efc966750b 100644
--- a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.tsx
+++ b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/recommendation/Recommendation.tsx
@@ -70,7 +70,7 @@ const Recommendation = ({
const handleRedirect = () => {
sendEventTelemetry({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_TUTORIAL_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_TUTORIAL_CLICKED,
eventData: {
databaseId: instanceId,
name: recommendationsContent[name].telemetryEvent || name,
@@ -89,7 +89,7 @@ const Recommendation = ({
id,
{ hide: !hide },
({ hide, name }) => sendEventTelemetry({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_HIDE,
+ event: TelemetryEvent.INSIGHTS_TIPS_HIDE,
eventData: {
databaseId: instanceId,
action: hide ? 'hide' : 'show',
@@ -114,7 +114,7 @@ const Recommendation = ({
const onSuccessActionDelete = () => {
sendEventTelemetry({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_SNOOZED,
+ event: TelemetryEvent.INSIGHTS_TIPS_SNOOZED,
eventData: {
databaseId: instanceId,
name: recommendationsContent[name]?.telemetryEvent ?? name,
@@ -125,7 +125,7 @@ const Recommendation = ({
const onRecommendationLinkClick = () => {
sendEventTelemetry({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_LINK_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_LINK_CLICKED,
eventData: {
databaseId: instanceId,
name: recommendationsContent[name]?.telemetryEvent ?? name,
@@ -210,8 +210,8 @@ const Recommendation = ({
diff --git a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.spec.tsx b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.spec.tsx
index 463376473f..d736b660be 100644
--- a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.spec.tsx
+++ b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.spec.tsx
@@ -92,7 +92,7 @@ describe('WelcomeScreen', () => {
fireEvent.click(screen.getByTestId('approve-insights-db-analysis-btn'))
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_DATABASE_ANALYSIS_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_DATABASE_ANALYSIS_CLICKED,
eventData: {
databaseId: 'instanceId',
total: 1,
diff --git a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.tsx b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.tsx
index e65b282437..f271052995 100644
--- a/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.tsx
+++ b/redisinsight/ui/src/components/database-side-panels/panels/live-time-recommendations/components/welcome-screen/WelcomeScreen.tsx
@@ -31,7 +31,7 @@ const NoRecommendationsScreen = () => {
dispatch(createNewAnalysis(instanceId, delimiter))
history.push(Pages.databaseAnalysis(instanceId))
sendEventTelemetry({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_DATABASE_ANALYSIS_CLICKED,
+ event: TelemetryEvent.INSIGHTS_TIPS_DATABASE_ANALYSIS_CLICKED,
eventData: {
databaseId: instanceId,
total: recommendations?.length,
@@ -44,15 +44,15 @@ const NoRecommendationsScreen = () => {
return (
Welcome to
-
Recommendations!
+
Tips!
Where we help improve your database.
- New recommendations appear while you work with your database,
+ New tips appear while you work with your database,
including how to improve performance and optimize memory usage.
- Eager for more recommendations? Run Database Analysis to get started.
+ Eager for more tips? Run Database Analysis to get started.
{
provider: 'RE_CLOUD',
source: 'overview',
page: '/browser',
- tab: 'recommendations'
+ tab: 'tips'
},
- })
+ });
- sendEventTelemetry.mockRestore()
+ (sendEventTelemetry as jest.Mock).mockRestore()
})
})
diff --git a/redisinsight/ui/src/components/insights-trigger/InsightsTrigger.tsx b/redisinsight/ui/src/components/insights-trigger/InsightsTrigger.tsx
index 2782f35986..cb913c87f9 100644
--- a/redisinsight/ui/src/components/insights-trigger/InsightsTrigger.tsx
+++ b/redisinsight/ui/src/components/insights-trigger/InsightsTrigger.tsx
@@ -63,8 +63,8 @@ const InsightsTrigger = () => {
{
expect(
render()
).toBeTruthy()
- expect(screen.getByTestId('step-content')).toHaveTextContent('See recommendations to optimize the memory usage, performance')
+ expect(screen.getByTestId('step-content')).toHaveTextContent('See tips to optimize the memory usage, performance')
})
it('should call proper telemetry events', () => {
diff --git a/redisinsight/ui/src/components/onboarding-features/OnboardingFeatures.tsx b/redisinsight/ui/src/components/onboarding-features/OnboardingFeatures.tsx
index 5ee47e55bf..91081462fe 100644
--- a/redisinsight/ui/src/components/onboarding-features/OnboardingFeatures.tsx
+++ b/redisinsight/ui/src/components/onboarding-features/OnboardingFeatures.tsx
@@ -358,10 +358,10 @@ const ONBOARDING_FEATURES = {
content: (
<>
Use Database Analysis to get summary of your database and receive
- recommendations to improve memory usage and performance.
+ tips to improve memory usage and performance.
Run a new report to get an overview of the database and receive
- recommendations to optimize your database usage.
+ tips to optimize your database usage.
>
),
onSkip: () => sendClosedTelemetryEvent(...telemetryArgs),
@@ -389,14 +389,14 @@ const ONBOARDING_FEATURES = {
},
ANALYTICS_RECOMMENDATIONS: {
step: OnboardingSteps.AnalyticsRecommendations,
- title: 'Database Recommendations',
+ title: 'Database Tips',
Inner: () => {
const { id: connectedInstanceId = '' } = useSelector(connectedInstanceSelector)
const history = useHistory()
const telemetryArgs: TelemetryArgs = [connectedInstanceId, OnboardingStepName.DatabaseAnalysisRecommendations]
return {
- content: 'See recommendations to optimize the memory usage, performance and increase the security of your Redis database',
+ content: 'See tips to optimize the memory usage, performance and increase the security of your Redis database',
onSkip: () => sendClosedTelemetryEvent(...telemetryArgs),
onBack: () => sendBackTelemetryEvent(...telemetryArgs),
onNext: () => {
diff --git a/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.spec.tsx b/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.spec.tsx
index 3750ffdd5d..e7a8a26de5 100644
--- a/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.spec.tsx
+++ b/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.spec.tsx
@@ -38,7 +38,7 @@ describe('RecommendationCopyComponent', () => {
})
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.INSIGHTS_RECOMMENDATION_KEY_COPIED,
+ event: TelemetryEvent.INSIGHTS_TIPS_KEY_COPIED,
eventData: {
databaseId: INSTANCE_ID_MOCK,
name: mockTelemetryEvent,
@@ -65,7 +65,7 @@ describe('RecommendationCopyComponent', () => {
})
expect(sendEventTelemetry).toBeCalledWith({
- event: TelemetryEvent.DATABASE_RECOMMENDATIONS_KEY_COPIED,
+ event: TelemetryEvent.DATABASE_TIPS_KEY_COPIED,
eventData: {
databaseId: INSTANCE_ID_MOCK,
name: mockTelemetryEvent,
diff --git a/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.tsx b/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.tsx
index c8d858539e..93e1a3f3d5 100644
--- a/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.tsx
+++ b/redisinsight/ui/src/components/recommendation-copy-component/RecommendationCopyComponent.tsx
@@ -23,8 +23,8 @@ const RecommendationCopyComponent = ({ live = false, keyName, telemetryEvent, pr
const handleCopy = () => {
sendEventTelemetry({
event: live
- ? TelemetryEvent.INSIGHTS_RECOMMENDATION_KEY_COPIED
- : TelemetryEvent.DATABASE_RECOMMENDATIONS_KEY_COPIED,
+ ? TelemetryEvent.INSIGHTS_TIPS_KEY_COPIED
+ : TelemetryEvent.DATABASE_TIPS_KEY_COPIED,
eventData: {
databaseId: instanceId,
name: telemetryEvent,
diff --git a/redisinsight/ui/src/components/recommendation-voting/RecommendationVoting.spec.tsx b/redisinsight/ui/src/components/recommendation-voting/RecommendationVoting.spec.tsx
index 63bf4f313b..292d1c3775 100644
--- a/redisinsight/ui/src/components/recommendation-voting/RecommendationVoting.spec.tsx
+++ b/redisinsight/ui/src/components/recommendation-voting/RecommendationVoting.spec.tsx
@@ -57,7 +57,7 @@ describe('RecommendationVoting', () => {
})
it('should render proper popover and btn should be disabled"', async () => {
- userSettingsConfigSelector.mockImplementation(() => ({
+ (userSettingsConfigSelector as jest.Mock).mockImplementation(() => ({
agreements: {
analytics: false,
},
@@ -69,7 +69,7 @@ describe('RecommendationVoting', () => {
})
await waitForEuiToolTipVisible()
- expect(screen.getByTestId('not useful-vote-tooltip')).toHaveTextContent('Enable Analytics on the Settings page to vote for a recommendation')
+ expect(screen.getByTestId('not useful-vote-tooltip')).toHaveTextContent('Enable Analytics on the Settings page to vote for a tip')
expect(screen.getByTestId('not useful-vote-btn')).toBeDisabled()
})
})
diff --git a/redisinsight/ui/src/components/recommendation-voting/components/vote-option/VoteOption.tsx b/redisinsight/ui/src/components/recommendation-voting/components/vote-option/VoteOption.tsx
index 3d08318336..62e5bcfaed 100644
--- a/redisinsight/ui/src/components/recommendation-voting/components/vote-option/VoteOption.tsx
+++ b/redisinsight/ui/src/components/recommendation-voting/components/vote-option/VoteOption.tsx
@@ -55,8 +55,8 @@ const VoteOption = (props: Props) => {
const onSuccessVoted = ({ vote, name }: { name: string, vote: Nullable }) => {
sendEventTelemetry({
event: live
- ? TelemetryEvent.INSIGHTS_RECOMMENDATION_VOTED
- : TelemetryEvent.DATABASE_ANALYSIS_RECOMMENDATIONS_VOTED,
+ ? TelemetryEvent.INSIGHTS_TIPS_VOTED
+ : TelemetryEvent.DATABASE_ANALYSIS_TIPS_VOTED,
eventData: {
databaseId: instanceId,
name: recommendationsContent[name]?.telemetryEvent ?? name,
@@ -78,7 +78,7 @@ const VoteOption = (props: Props) => {
const getTooltipContent = (voteOption: Vote) => (isAnalyticsEnable
? voteTooltip[voteOption]
- : 'Enable Analytics on the Settings page to vote for a recommendation')
+ : 'Enable Analytics on the Settings page to vote for a tip')
return (
{
className={styles.exploreBtn}
data-testid="explore-msg-btn"
>
- Explore Redis
+ Explore
diff --git a/redisinsight/ui/src/pages/database-analysis/components/data-nav-tabs/DatabaseAnalysisTabs.spec.tsx b/redisinsight/ui/src/pages/database-analysis/components/data-nav-tabs/DatabaseAnalysisTabs.spec.tsx
index 88daddb2f7..4de9040be4 100644
--- a/redisinsight/ui/src/pages/database-analysis/components/data-nav-tabs/DatabaseAnalysisTabs.spec.tsx
+++ b/redisinsight/ui/src/pages/database-analysis/components/data-nav-tabs/DatabaseAnalysisTabs.spec.tsx
@@ -10,6 +10,7 @@ import { sendEventTelemetry, TelemetryEvent } from 'uiSrc/telemetry'
import { MOCK_RECOMMENDATIONS } from 'uiSrc/constants/mocks/mock-recommendations'
import { recommendationsSelector } from 'uiSrc/slices/recommendations/recommendations'
+import { ShortDatabaseAnalysis } from 'apiSrc/modules/database-analysis/models'
import DatabaseAnalysisTabs, { Props } from './DatabaseAnalysisTabs'
const mockRecommendationsSelector = jest.requireActual('uiSrc/slices/recommendations/recommendations')
@@ -31,10 +32,10 @@ jest.mock('uiSrc/slices/recommendations/recommendations', () => ({
const mockedProps = mock