Skip to content

[Python E2E Sample App] Update healthcheck API naming #8

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

Merged
merged 1 commit into from
Mar 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
## Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
## SPDX-License-Identifier: Apache-2.0
from django.http import HttpResponse, JsonResponse
import boto3
import logging
import threading
import time

import boto3
import requests
import schedule
import time
import threading
from django.http import HttpResponse, JsonResponse
from opentelemetry import trace
from opentelemetry.trace.span import format_trace_id

Expand Down Expand Up @@ -75,7 +76,7 @@ def http_call(request):
def downstream_service(request):
ip = request.GET.get('ip', '')
ip = ip.replace("/", "")
url = f"http://{ip}:8001/health-check"
url = f"http://{ip}:8001/healthcheck"
try:
response = requests.get(url)
status_code = response.status_code
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
from remote_service_app import views

urlpatterns = [
path('health-check', views.healthcheck),
path('healthcheck', views.healthcheck),
]