-
Notifications
You must be signed in to change notification settings - Fork 559
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
Java Spark Produces 404 for the root url #151
Comments
Hi @sergeome, the issue seems to be in the SAM template. When you configure API Gateway with this event structure below API Gateway only accepts requests in sub-resources - ie there needs to be a /something. Events:
GetResource:
Type: Api
Properties:
Path: /{proxy+}
Method: any To make the Events:
GetSubResource:
Type: Api
Properties:
Path: /{proxy+}
Method: any
GetRootResource:
Type: Api
Properties:
Path: /
Method: any |
Hi, @sapessi. Thank you a lot for looking at that problem. I modified I suspect it might be an issue with my environment setup. Can you please confirm that it does work for you in this repo? Thank you.
Again, thank you very much for your help! |
Interesting. Looks like the |
Just deployed. The same results as on local with sam. https://3b8d6xmvy7.execute-api.us-east-1.amazonaws.com/dev/ - Not Found |
Thanks @sergeome, I'll investigate this week. |
Hey @sergeome, any chance you can test with the |
release 1.1.1 is going out to maven central |
Scenario
Very basic "Hello World" app.
Folder Structure
SparkResources
Expected behavior
Actual behavior
Steps to reproduce
[email protected]:sergeome/java-spark-aws-lambda.git
mvn clean package
sam local start-api --template sam.yaml
Full log output
For the first time user navigates to the "/", for the second time user navigates to the "/example"
The text was updated successfully, but these errors were encountered: