amazon-web-services

AWS EBS runs into “504 Gateway Time-out”

早过忘川 提交于 2021-02-11 15:14:16
问题 I'm new to using AWS EBS and ECS, so please bear with me if I ask questions that might be obvious for others. To the issue: I've got a single-container Node/Express application that runs on EBS. The local docker container works as expected. On EBS, I can access one endpoint of the API and get the expected output. For the second endpoint, which runs longer (around 10-15 seconds) I get no response and run after 60 seconds into a time out: "504 Gateway Time-out". I wonder how I would approach

SageMaker client create_endpoint() error 'does not have BatchGetImage permission for image: '763104351884…/tensorflow-inference:1.15.2-gpu'

喜欢而已 提交于 2021-02-11 15:12:28
问题 I have a pre-trained Tensorflow model, I'm trying to using SagaMaker client.create_endpoint() to create an endpoint so that I can call the API to get predictions, the doc is here After creating the model by using client.create_model() I have a model stored on SageMaker, and the base image I'm using is 763104351884.dkr.ecr.us-east-1.amazonaws.com/tensorflow-inference:1.15.2-gpu , this is my code: model_name = `xxx`, role = `xxx`, model_base_image = `763104351884.dkr.ecr.us-east-1.amazonaws.com

Calculate Median for each group in AWS Athena table

强颜欢笑 提交于 2021-02-11 15:03:33
问题 Below is the schema for the athena table I wish to calculate median for 'parameter_value' group by standard_lab_parameter_name & units. For this I followed link : https://docs.aws.amazon.com/redshift/latest/dg/r_MEDIAN.html But on running the query select median(parameter_value) from table_name group by standard_lab_parameter_name, units It throws error SYNTAX_ERROR: line 1:8: Function median not registered Any help? Or if some alternative query would be great 回答1: Athena is based on Presto 0

Calculate Median for each group in AWS Athena table

心不动则不痛 提交于 2021-02-11 15:02:30
问题 Below is the schema for the athena table I wish to calculate median for 'parameter_value' group by standard_lab_parameter_name & units. For this I followed link : https://docs.aws.amazon.com/redshift/latest/dg/r_MEDIAN.html But on running the query select median(parameter_value) from table_name group by standard_lab_parameter_name, units It throws error SYNTAX_ERROR: line 1:8: Function median not registered Any help? Or if some alternative query would be great 回答1: Athena is based on Presto 0

Sagemaker processing job with PySpark and Step Functions

南笙酒味 提交于 2021-02-11 15:02:27
问题 this is my problem: I have to run a Sagemaker processing job using custom code written in PySpark. I've used the Sagemaker SDK by running these commands: spark_processor = sagemaker.spark.processing.PySparkProcessor( base_job_name="spark-preprocessor", framework_version="2.4", role=role_arn, instance_count=2, instance_type="ml.m5.xlarge", max_runtime_in_seconds=1800, ) spark_processor.run( submit_app="processing.py", arguments=['s3_input_bucket', bucket_name, 's3_input_file_path', file_path ]

DynamoDB Update operation without using the Key attribute

北城以北 提交于 2021-02-11 14:58:16
问题 The use case: I have a bid table which holds the bid on Loades. One Load can have multiple Bids. The Bid status is new for every bid. Once the bid is accepted by the Admin(The person who put that Load up for bidding) then I need to change the status for that particular bid as "Accepted" and for other bids on the same Load the status should be "rejected". Table Definition: Bid_id(Which is unique for every record) and Load_id(multiple entries) is my primary and sort key respectively. How do I

Is it possible to login to Amazon Cognito via REST API without using the SDK

前提是你 提交于 2021-02-11 14:53:32
问题 I'm looking at AWS Cognito documentaion here Authentication with a User Pool Actually I looked at many links in the documentation without finding clear information about this. In AWS Cognito, I successfully created user pool, app client and integrated signup and login in Android and iOS using the platform provided SDK (amplify). But I want to do that directly from REST client, for testing purposes to generate user tokens. I want to submit the required credentials, username and password and

How to I loop through AWS CLI output?

无人久伴 提交于 2021-02-11 14:44:13
问题 I am trying to pass a list of values from a aws cli query to another command. Even though I have seen plenty of examples in AWS, when I try all the values come together: policy_versions=`aws iam list-policy-versions --query "Versions[].VersionId" --policy-arn $POLICY_ARN --output text` echo "policy_versions=$policy_versions" for ver in $policy_versions; do echo "first version: $ver" done Which then prints out: policy_versions=v3 v2 v1 first version: v3 v2 v1 My value of ver is the entire

AWS EB undefined RDS_HOSTNAME with Database hosts array empty

百般思念 提交于 2021-02-11 14:40:02
问题 Currently in a Laravel project using AWS EB with RDS. When I run php artisan migrate --seed then I get PHP Notice: Undefined index: RDS_HOSTNAME in /var/app/current/config/database.php on line 5 PHP Notice: Undefined index: RDS_USERNAME in /var/app/current/config/database.php on line 6 PHP Notice: Undefined index: RDS_PASSWORD in /var/app/current/config/database.php on line 7 PHP Notice: Undefined index: RDS_DB_NAME in /var/app/current/config/database.php on line 8 and Database hosts array is

AWS EB undefined RDS_HOSTNAME with Database hosts array empty

懵懂的女人 提交于 2021-02-11 14:35:34
问题 Currently in a Laravel project using AWS EB with RDS. When I run php artisan migrate --seed then I get PHP Notice: Undefined index: RDS_HOSTNAME in /var/app/current/config/database.php on line 5 PHP Notice: Undefined index: RDS_USERNAME in /var/app/current/config/database.php on line 6 PHP Notice: Undefined index: RDS_PASSWORD in /var/app/current/config/database.php on line 7 PHP Notice: Undefined index: RDS_DB_NAME in /var/app/current/config/database.php on line 8 and Database hosts array is