Skip to content

Conversation

@bchampp
Copy link
Member

@bchampp bchampp commented Oct 7, 2025

Issue #, if available:

Description of changes:
Adding a new route to the web layer that allows us to dynamically update the lambda invoke endpoint of the server. This is needed for SAM CLI because ports are assigned dynamically, and we need to update the emulator lambda endpoint to the port that gets exposed for the lambda RIE.

Tested it by running the server locally and validating the API calls work:

➜  aws-durable-execution-sdk-python-testing git:(feat/add-put-lambda-endpoint) curl -X PUT http://localhost:5002/lambda-endpoint \
  -H "Content-Type: application/json" \
  -d '{
    "EndpointUrl": "http://localhost:9000"
  }'
➜  aws-durable-execution-sdk-python-testing git:(feat/add-put-lambda-endpoint) curl -X PUT http://localhost:5002/lambda-endpoint \     
  -H "Content-Type: application/json" \
  -d '{
    "EndpointUrl": "http://localhost:9000",
    "RegionName": "us-west-2"  
  }'                               
{"message":"Lambda endpoint updated successfully"

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@bchampp bchampp merged commit ada9368 into main Oct 7, 2025
8 checks passed
@bchampp bchampp deleted the feat/add-put-lambda-endpoint branch October 7, 2025 20:13
)

except (AttributeError, TypeError) as e:
return HTTPResponse.create_json(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

        except Exception as e:  # noqa: BLE001
            return self._handle_framework_exception(e)

region_name = body.get("RegionName", "us-east-1")

if not endpoint_url:
return HTTPResponse.create_json(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use

return self._handle_aws_exception( InvalidParameterValueException("EndpointUrl is required"))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants