Skip to content

self-hosted insights/backend/databas page you are looking for was not found #3452

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
a10201 opened this issue Nov 30, 2024 · 17 comments · Fixed by getsentry/sentry#84538
Closed

Comments

@a10201
Copy link

a10201 commented Nov 30, 2024

Environment

SaaS (https://sentry.io/)

Steps to Reproduce

  1. I user self-hosted to build sentry env and version=Sentry 24.12.0.dev0
  2. i click insights->backend->Most Time-Consuming Queries->view all
  3. Page Not Found
    The page you are looking for was not found.

You may wish to try the following:

If you entered the address manually, double check the path. Did you forget a trailing slash?
If you followed a link here, try hitting back and reloading the page. It's possible the resource was moved out from under you.
If all else fails, contact us with more details
Not sure what to do? Return to the dashboard

Sentry 24.12.0.dev0
73a925e

Expected Result

not error page

Actual Result

Image

Product Area

Unknown

Link

No response

DSN

No response

Version

No response

@getsantry
Copy link

getsantry bot commented Nov 30, 2024

Assigning to @getsentry/support for routing ⏲️

@InterstellarStella InterstellarStella transferred this issue from getsentry/sentry Dec 2, 2024
@getsantry getsantry bot moved this from Waiting for: Support to Waiting for: Product Owner in GitHub Issues with 👀 3 Dec 2, 2024
@fastfend
Copy link

fastfend commented Dec 2, 2024

Same thing here for 24.11.1, I assume it's releated to change to tabbed UI and some missing feature flag

@fastfend
Copy link

fastfend commented Dec 2, 2024

Yup, it looks like this MR is not included in 24.11.1 release.
Adding organizations:insights-domain-view flag resolves the issue

@aldy505
Copy link
Collaborator

aldy505 commented Dec 9, 2024

@a10201 Hello, have you tried adding the feature flag above? ☝

@lxShaDoWxl
Copy link

flag organizations:insights-domain-view not full work

@getsantry getsantry bot moved this from Waiting for: Community to Waiting for: Product Owner in GitHub Issues with 👀 3 Dec 17, 2024
@aldy505
Copy link
Collaborator

aldy505 commented Jan 11, 2025

@lxShaDoWxl @a10201 a few things to make sure of:

You've set COMPOSE_PROFILES on both of your .env and .env.custom file:

COMPOSE_PROFILES=feature-complete

You've set these feature flags on your sentry/sentry.conf.py file:

"organizations:deprecate-fid-from-performance-score",
"organizations:indexed-spans-extraction",
"organizations:insights-entry-points",
"organizations:insights-initial-modules",
"organizations:insights-addon-modules",
"organizations:mobile-ttid-ttfd-contribution",
"organizations:performance-calculate-score-relay",
"organizations:standalone-span-ingestion",
"organizations:starfish-browser-resource-module-image-view",
"organizations:starfish-browser-resource-module-ui",
"organizations:starfish-browser-webvitals",
"organizations:starfish-browser-webvitals-pageoverview-v2",
"organizations:starfish-browser-webvitals-replace-fid-with-inp",
"organizations:starfish-browser-webvitals-use-backend-scores",
"organizations:starfish-mobile-appstart",
"projects:span-metrics-extraction",
"projects:span-metrics-extraction-addons",

If that's still not the case (meaning you've confirmed that everything is set), please let us know. But if that's the case (meaning you found out that they're not set yet), please re-run the ./install.sh script.

@fastfend
Copy link

Btw this was fixed in 24.12

@getsantry getsantry bot moved this from Waiting for: Community to Waiting for: Product Owner in GitHub Issues with 👀 3 Jan 11, 2025
@getsantry getsantry bot moved this to Waiting for: Community in GitHub Issues with 👀 3 Jan 12, 2025
@lxShaDoWxl
Copy link

lxShaDoWxl commented Jan 14, 2025

version 24.12.1
error in page
Insights -> Backend -> Overview -> Transaction Summary
item link in events
Page Not Found
link page
/organizations/incraft/insights/backend/laravel:aedfea93408a4dbbb1d4f59b259d8721/?project=9

sentry.conf.py

SENTRY_FEATURES.update(
    {
        feature: True
        for feature in (
            "organizations:discover",
            "organizations:events",
            "organizations:global-views",
            "organizations:incidents",
            "organizations:integrations-issue-basic",
            "organizations:integrations-issue-sync",
            "organizations:invite-members",
            "organizations:metric-alert-builder-aggregate",
            "organizations:sso-basic",
            "organizations:sso-rippling",
            "organizations:sso-saml2",
            "organizations:performance-view",
            "organizations:advanced-search",
            "organizations:session-replay",
            "organizations:issue-platform",
            "organizations:profiling",
            "organizations:monitors",
            "organizations:dashboards-mep",
            "organizations:mep-rollout-flag",
            "organizations:dashboards-rh-widget",
            "organizations:metrics-extraction",
            "organizations:transaction-metrics-extraction",
            "projects:custom-inbound-filters",
            "projects:data-forwarding",
            "projects:discard-groups",
            "projects:plugins",
            "projects:rate-limits",
            "projects:servicehooks",
        )
        # Starfish related flags
        + (
            "organizations:deprecate-fid-from-performance-score",
            "organizations:indexed-spans-extraction",
            "organizations:insights-entry-points",
            "organizations:insights-initial-modules",
            "organizations:insights-addon-modules",
            "organizations:mobile-ttid-ttfd-contribution",
            "organizations:performance-calculate-score-relay",
            "organizations:standalone-span-ingestion",
            "organizations:starfish-browser-resource-module-image-view",
            "organizations:starfish-browser-resource-module-ui",
            "organizations:starfish-browser-webvitals",
            "organizations:starfish-browser-webvitals-pageoverview-v2",
            "organizations:starfish-browser-webvitals-replace-fid-with-inp",
            "organizations:starfish-browser-webvitals-use-backend-scores",
            "organizations:starfish-mobile-appstart",
            "projects:span-metrics-extraction",
            "projects:span-metrics-extraction-addons",
        )
        # User Feedback related flags
        + (
            "organizations:user-feedback-ingest",
            "organizations:user-feedback-replay-clip",
            "organizations:user-feedback-ui",
        )
    }
)

.env

COMPOSE_PROJECT_NAME=sentry-self-hosted
# Set COMPOSE_PROFILES to "feature-complete" to enable all features
# To enable errors monitoring only, set COMPOSE_PROFILES=errors-only
# See https://develop.sentry.dev/self-hosted/experimental/errors-only/
COMPOSE_PROFILES=feature-complete
SENTRY_EVENT_RETENTION_DAYS=90
# You can either use a port number or an IP:PORT combo for SENTRY_BIND
# See https://docs.docker.com/compose/compose-file/#ports for more
SENTRY_BIND=9000
# Set SENTRY_MAIL_HOST to a valid FQDN (host/domain name) to be able to send emails!
# SENTRY_MAIL_HOST=example.com
SENTRY_IMAGE=getsentry/sentry:24.12.1
SNUBA_IMAGE=getsentry/snuba:24.12.1
RELAY_IMAGE=getsentry/relay:24.12.1
SYMBOLICATOR_IMAGE=getsentry/symbolicator:24.12.1
VROOM_IMAGE=getsentry/vroom:24.12.1
HEALTHCHECK_INTERVAL=30s
HEALTHCHECK_TIMEOUT=1m30s
HEALTHCHECK_RETRIES=10
# Caution: Raising max connections of postgres increases CPU and RAM usage
# see https://github.com/getsentry/self-hosted/pull/2740 for more information
POSTGRES_MAX_CONNECTIONS=100
# Set SETUP_JS_SDK_ASSETS to 1 to enable the setup of JS SDK assets
# SETUP_JS_SDK_ASSETS=1

@getsantry getsantry bot moved this from Waiting for: Community to Waiting for: Product Owner in GitHub Issues with 👀 3 Jan 14, 2025
@fastfend
Copy link

Weird gonna compare it against my config. @lxShaDoWxl could you verify changes in your cloned repo against 24.12.1 tag itself?

@lxShaDoWxl
Copy link

config files equal qit

@aldy505
Copy link
Collaborator

aldy505 commented Jan 22, 2025

@lxShaDoWxl can you confirm on your .env (and .env.custom if you have one) that you've set your version to the correct ones?

@lxShaDoWxl
Copy link

.env.custom
COMPOSE_PROJECT_NAME=sentry-self-hosted
# Set COMPOSE_PROFILES to "feature-complete" to enable all features
# To enable errors monitoring only, set COMPOSE_PROFILES=errors-only
# See https://develop.sentry.dev/self-hosted/experimental/errors-only/
COMPOSE_PROFILES=feature-complete
SENTRY_EVENT_RETENTION_DAYS=90
# You can either use a port number or an IP:PORT combo for SENTRY_BIND
# See https://docs.docker.com/compose/compose-file/#ports for more
SENTRY_BIND=9000
# Set SENTRY_MAIL_HOST to a valid FQDN (host/domain name) to be able to send emails!
# SENTRY_MAIL_HOST=example.com
SENTRY_IMAGE=getsentry/sentry:24.12.1
SNUBA_IMAGE=getsentry/snuba:24.12.1
RELAY_IMAGE=getsentry/relay:24.12.1
SYMBOLICATOR_IMAGE=getsentry/symbolicator:24.12.1
VROOM_IMAGE=getsentry/vroom:24.12.1
HEALTHCHECK_INTERVAL=30s
HEALTHCHECK_TIMEOUT=1m30s
HEALTHCHECK_RETRIES=10
# Caution: Raising max connections of postgres increases CPU and RAM usage
# see https://github.com/getsentry/self-hosted/pull/2740 for more information
POSTGRES_MAX_CONNECTIONS=1000
SENTRY_MAX_EXTERNAL_SOURCEMAP_SIZE=20M
# Set SETUP_JS_SDK_ASSETS to 1 to enable the setup of JS SDK assets
# SETUP_JS_SDK_ASSETS=1

@getsantry getsantry bot moved this from Waiting for: Community to Waiting for: Product Owner in GitHub Issues with 👀 3 Jan 24, 2025
@xpuska513
Copy link

As of 25.1.0 release, I'm still seeing this issue.
I tried navigating to Performance -> Backend -> Queries, then I selected a random query and tried to open an span associated with said query and that lead me to the 404 not found page. Will try to set the feature flag suggested in dicsussion above and see if it resolves the issue or not.

@aldy505
Copy link
Collaborator

aldy505 commented Jan 31, 2025

@xpuska513 Can you confirm that you've checked this before? #3452 (comment)

@xpuska513
Copy link

@aldy505, yes and as per our discussion in Discord looks like the trace viewer is disabled by default.
I left a response in my issue with the flags you shared with me here: #3559 (comment)

@getsantry getsantry bot moved this to Waiting for: Product Owner in GitHub Issues with 👀 3 Jan 31, 2025
@aldy505
Copy link
Collaborator

aldy505 commented Feb 1, 2025

Hey @gggritso, can you please pass this on to the Insights frontend team? This "View All" button does not correctly redirects to the {BASE_URL}/organizations/org_slug/insights/backend/database, instead it redirects to {BASE_URL}/insights/backend/database. It should check the CUSTOMER_DOMAIN constant first (https://github.com/getsentry/sentry/blob/d210118fce94310ef5858d51efe16ee26c995a48/static/app/constants/index.tsx#L16-L17)

Image

@gggritso
Copy link
Member

gggritso commented Feb 3, 2025

@aldy505 can-do, thanks 👍🏻

DominikB2014 added a commit to getsentry/sentry that referenced this issue Feb 5, 2025
closes getsentry/self-hosted#3452

Fixes a self hosted issue where the `view all` on insight overview
widgets take you a url without a org and org slug in the path.

This is fixed by removing the `bare=true` parameters from the
`moduleUrlBuilder`. When `bare= true` we bypass `normalizeUrl` and don't
add the customer domain. For example if `bare=true`,
`moduleUrlBuilder('db') === /insights/backend/database/`.

I think the expectation here was that `LinkButton` would run
`normalizeUrl` for us, which might handles adding the org and slug to
the path, however, the `normalizeUrl` function works by conditionally
replacing `/organizations/slug` with an empty string IF the user is not
on a customer domain url.

What this means is that anytime `normalizeUrl` is called, we should
always include `/organizations/org-slug`.

Technically we are running `normalizeUrl` twice with this solution, but
there's no serious performance effects of this, and I'd rather run
`moduleUrlBuilder` without the `bare` parameter, that way we never have
to worry about when we need to use it, and we never run into a similar
situation as this.
andrewshie-sentry pushed a commit to getsentry/sentry that referenced this issue Feb 5, 2025
closes getsentry/self-hosted#3452

Fixes a self hosted issue where the `view all` on insight overview
widgets take you a url without a org and org slug in the path.

This is fixed by removing the `bare=true` parameters from the
`moduleUrlBuilder`. When `bare= true` we bypass `normalizeUrl` and don't
add the customer domain. For example if `bare=true`,
`moduleUrlBuilder('db') === /insights/backend/database/`.

I think the expectation here was that `LinkButton` would run
`normalizeUrl` for us, which might handles adding the org and slug to
the path, however, the `normalizeUrl` function works by conditionally
replacing `/organizations/slug` with an empty string IF the user is not
on a customer domain url.

What this means is that anytime `normalizeUrl` is called, we should
always include `/organizations/org-slug`.

Technically we are running `normalizeUrl` twice with this solution, but
there's no serious performance effects of this, and I'd rather run
`moduleUrlBuilder` without the `bare` parameter, that way we never have
to worry about when we need to use it, and we never run into a similar
situation as this.
@github-actions github-actions bot locked and limited conversation to collaborators Feb 21, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
Archived in project
Archived in project
Development

Successfully merging a pull request may close this issue.

6 participants