Comments (7)
@gsavvidis96 Yep, we felt the need for this too in after we POC'd the first version in our team. Now, here's what we are working on, please let us know what you think or if you have other suggestions:
- Dev Mode should print the basic essential info upon start (domain, etc.)
- Dev Mode should be an interactive terminal session, which still allows for input.
- Dev Mode's terminal session input should allow for easy invoking of AWS Lambda and emulation of several types of event payloads, beyond just API requests—all in the CLI.
from serverless.
@gsavvidis96 Yep, we felt the need for this too in after we POC'd the first version in our team. Now, here's what we are working on, please let us know what you think or if you have other suggestions:
- Dev Mode should print the basic essential info upon start (domain, etc.)
- Dev Mode should be an interactive terminal session, which still allows for input.
- Dev Mode's terminal session input should allow for easy invoking of AWS Lambda and emulation of several types of event payloads, beyond just API requests—all in the CLI.
I think it will be perfect that way, can't think of anything more currently.
from serverless.
@senghuotlay Multiple people should not run serverless dev at the same time in the same Stage, or the feature will only work for one of them, since the events can only be proxied to one user's machine at a time. To avoid this, teammates should use personal Stages, rather than work on a shared development Stage together. Or, if sharing the same development Stage, if logic is broken up across multiple Services, teammates can work on a Service individually in the same Stage. We realize this isn't ideal, but it's a limitation of cloud architecture generally. We have something in the works that will solve this problem perfectly, which we aim to unveil in Q3.
If the terminal session is closed and a deployment does not happen to restore the original environment using a regular serverless deploy
, the AWS Lambda functions will still be instrumented with dev mode and will not work, since they will be reaching out to a local machine which is no longer connected. Always remember to run a regular deploy after dev mode.
This is only the first version of the feature and about ~10% of our vision here. We'll be shipping a lot more in this direction shortly. Keep the feedback coming!
from serverless.
it will go against your deployment's endpoint, acting as a barier, therefore i think it's suggested to have a local env deployment against that
from serverless.
Sorry I did not understand what you mean. What I mean is that I run serverless dev
and I just see Connected (Ctrl+C to cancel)
so in order to invoke a function for example in postman I need to know its endpoint. To find that I got to run a second command in another terminal serverless info
and copy and paste the endpoint from there while it could just be
service: XX
stage: XX
region: XX
stack XX
endpoint: GET - https://XXX
functions:
XXX: XX-dev-XX
Connected (Ctrl+C to cancel)
After invoking the serverless dev
command
from serverless.
couple of questions to have @ac360, what will happen when multiple people are running serverless dev at the same time, how will will u be able to intercept which one, and after you've closed your terminal, will it crashes the serer?
from serverless.
We're still working on lots of improvements here, but until then, we've pushed the initial suggestion to show endpoints (and functions) at the beginning of Dev Mode. Run serverless update
to get it.
https://github.com/serverless/serverless/releases/tag/v4.0.33
from serverless.
Related Issues (20)
- Documentation is not updated about the v3 HOT 1
- Encountering "Internal Serverless Error" in commands HOT 3
- Menu Overlap Issue in Documentation HOT 2
- Custom resource deployment hangs forever HOT 4
- Show helpful errors when the build type (e.g. `esbuild`) is missing in the `build` section
- `sls info -v` not showing stack outputs HOT 2
- Cannot parse 'serverless.ts' after upgrading to v4 HOT 4
- Missing Package @serverlessinc/sf-core HOT 1
- V4.1.0: Error fetching release: EACCES: permission denied, open /usr/local/lib/node_modules/serverless/node_modules/.bin/serverless-darwin-amd64-0.0.2 HOT 3
- Serverless 4.x doesn't seem to update or work HOT 7
- sls deploy issue HOT 1
- Make inputTransformers and inputPath available when CfnRule target is event bus HOT 1
- No forceInclude equivalent in the new build.esbuild configuration HOT 7
- Invalid option in build call buildConcurrency HOT 1
- Parsing issue around build.esbuild.exclude and build.esbuild.external HOT 1
- Dev command does not work when custom IAM role set HOT 1
- AWS SSO doesn't seem to work with SERVERLESS_LICENSE_KEY HOT 2
- [windows][v4] serverless invoke local is failing to load handlers HOT 1
- Params top-level property is not loading when defined in a file HOT 1
- Detected unrecognized CLI options: "--d".
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from serverless.