Skip to content
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

EKS DaemonSet Guide: Unknown Error when running workshop v2.1.1 #263

Closed
Eric-HY-Huang opened this issue Mar 12, 2024 · 1 comment
Closed
Assignees
Labels
bug Something isn't working

Comments

@Eric-HY-Huang
Copy link

Describe the bug

I was running the workshop "Centralized Logging with OpenSearch Workshop".
When I Click the DaemonSet Guide tab at Section "Ingest Logs from EKS - Ingest EKS Spring Boot Logs", Step 3 "Deploy Fluent Bit agents to EKS". It throws out Unknown Error.
CW Logs below:
[ERROR] 2024-03-11T11:48:18.981Z e88455ce-00b8-4702-9589-e98b7ffcd01e Expecting value: line 1 column 1 (char 0)
Traceback (most recent call last):
File "/opt/python/commonlib/decorator.py", line 19, in wrapper
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/var/task/lambda_function.py", line 28, in lambda_handler
return router.resolve(event)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/python/commonlib/decorator.py", line 101, in resolve
return self.fieldsfield_name
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/task/lambda_function.py", line 57, in get_k8s_deployment_content_with_daemon_set
return ingestion_svc.get_k8s_deployment_content_with_daemon_set(source_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/task/svc/service.py", line 221, in get_k8s_deployment_content_with_daemon_set
return eks_source_handler.get_deployment_content(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/task/svc/k8s.py", line 129, in get_deployment_content
return k8s_flb.generate_deployment_content()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/task/flb/flb_builder.py", line 375, in generate_deployment_content
params["fluent_bit_image"] = self.get_flb_image().get(
^^^^^^^^^^^^^^^^^^^^
File "/var/task/flb/flb_builder.py", line 428, in get_flb_image
return self.get_s3_object(key=f"{solution_version}/flb_version.txt")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/task/flb/flb_builder.py", line 435, in get_s3_object
return json.loads(response.data.decode("utf-8"))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lang/lib/python3.11/json/init.py", line 346, in loads
return _default_decoder.decode(s)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lang/lib/python3.11/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/var/lang/lib/python3.11/json/decoder.py", line 355, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

Expected Behavior

Display DaemonSet Guide.

Current Behavior

Throws out unknown error

Reproduction Steps

Running Centralized Logging with OpenSearch Workshop

Possible Solution

The root cause is the artifact "s3://aws-gcr-solutions-assets.s3.amazonaws.com/{solution_version}/flb_version.txt" missing when solution_version =workshop_v2.1.1.

It could be a bug only apply for workshop. But it could be resolved by adding error handling at lines 433 of "/source/constructs/lambda/api/app_log_ingestion/flb
/flb_builder.py

Additional Information/Context

No response

Solution Version

workshop v2.1.1

AWS Region. e.g., us-east-1

us-east-1

Other information

No response

@Eric-HY-Huang Eric-HY-Huang added the bug Something isn't working label Mar 12, 2024
@owenCCY owenCCY self-assigned this Mar 14, 2024
@owenCCY
Copy link
Contributor

owenCCY commented Mar 14, 2024

Hi, we have fixed this issue, thx for your information. Please try again.
Feel free to reopen this issue ticket if you find this issue still exist, thx.

@owenCCY owenCCY closed this as completed Mar 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants