Comments (12)
@bboure Take a look at the kinesis emulator. It is simply an extremely small python shell around the NodeJS kinesalite
package.
from aws-utils.
I am strongly in favor. I'd also like to hear what @cbaron (he is back on Monday). Assuming those plugins allow peer dependencies we could potential include them as devDependencies and add some basic level of "does it start" testing to ensure we don't break the consumers.
from aws-utils.
I think for v1.0, this project should look at integrating with Localstack. Its the de facto AWS emulator project and provides already mature DynamoDB and Lambda emulation.
I think this project is trying to do too much in setting up the whole AWS environment and should just focus on being an AppSync emulator.
Localstack already have their own Serverless plugin
from aws-utils.
Thanks @marklawlor for pointing our localstack. I was not aware it existed.
I'll have a look at it, but it seems like it would make sense to integrate AppSync in it.
from aws-utils.
@bboure -- your proposal sounds great. I appreciate the effort you've put into the project.
@marklawlor, @bboure -- agreed we should make it easier to integrate with localstack, but since we've already put in work to spin up a local dynamodb instance with java, we should let the implementor decide if and where to use, point to dynamo respectively.
from aws-utils.
The biggest challenge to integrating this emulator with localstack would probably be that localstack is written in python, when the emulator is in nodeJs. But a first step would probably be to make possible to have them work together.
I think keeping automatic DynamoDB startup is a good thing for those who want to keep using this emulator as a standalone, but we could definitely consider allowing using an existing instance of DynamoDB, like localstack, instead; or skip it altogether if you are not going to use it at all (eg: if you only use lambda).
That being said, I also think that localstack has a different approach, and probably a different goal than the emulator...
The emulator is clearly made to improve your development productivity, by letting you run your code locally without the need to re-deploy.
Localstack, on the other hand, is more focused on running local version of your project's external dependencies.
In other words, running an AppSync verion in a localstack would make sense if you are working, let's say, on your Front End and want to point to a local version of your API (the API does not change, it just runs). But if you are working on the API itself, the emulator would be the right choice since it point directly to your code and picks up any change.
from aws-utils.
What would stop us from only using localstack via docker? I've been using this AppSync emulator within docker and with the dwmkerr/dynamodb
docker container, which is a very similar setup to localstack on docker.
from aws-utils.
My guess is that a lot of folks use docker to run localstack
. That's what we did before migrating to the local java emulator, and I know a few collaborators do the same.
To me, I do not feel the need to make the python implementation of localstack more readily available ( without docker ), but I certainly wouldn't be opposed to this integration -- I would certainly be nicer to remove a dependency on docker in favor of python.
Personally, I would prefer to iterate on the overall architecture of 1.0 as well as the addition of more supported features so that we can try to keep up with aws + serverless.
from aws-utils.
Honestly, wouldn't it be great if we had a single local AWS cloud stack, and had it include AppSync simulation?
from aws-utils.
Just to make it clear, I didn't recommend Localstack as a massive rewrite for this project.
What I would actually like to see are these two goals met:
- A CLI interface (see how the kinesis emulator is started
- Removing the DynamoDB and Lambda emulation in favour of external dependencies.
This would allow the project to scale and be easily used in different ecosystems (eg Localstack)
Say we don't opt for the Localstack approach. I would still love to replace the Lambda emulation with something like docker-lambda (it even has a nice npm package). This is the lambda emulator being used by the Offical AWS SAM Local https://aws.amazon.com/about-aws/whats-new/2017/08/introducing-aws-sam-local-a-cli-tool-to-test-aws-lambda-functions-locally
from aws-utils.
I like what @marklawlor is saying here about external deps. I've always seen our lambda support as a hack. I'd like that to go away if nothing else. As appsync has become less dynamodb specific I can see the case for decoupling that as well (less code ftw)
from aws-utils.
I've always liked the approach outlined here (leveraging external tools for lambda, etc.). @cbaron and I spoke about this and landed on the following idea:
- move emulator out into it's own repo
- make it very pluggable and not particularly useful on it's own
- rewrite bits of codebase in typescript (i.e. like amplify)
- work on plugins for serverless and amplify.
from aws-utils.
Related Issues (20)
- Cannot find function config for function : undefined HOT 1
- Failure trying to run tests HOT 3
- ValueMapper: JavaString HOT 2
- Feature request: Aurora (RDS) Serverless support HOT 1
- AppSync Emulator - Support Condition Expressions
- AppSync Emulator - Support $context.stash
- appsync emulator resultItems mapping template example does not work in AWS
- [appsync-emulator-serverless] Does not respect multiple appsSync API's in config HOT 2
- AppSync Emulator - Support RegEx in string split
- Cannot Install on Windows HOT 1
- [appsync-emulator-serverless] Conflicting peer dependencies
- Bug with getting PID by port HOT 9
- Lambda datasource docker HOT 12
- Emulator does not throw error when AppSync does
- AppSync Emulator - AWSEmail and AWSURL HOT 1
- Incorrect string equality in VTL templates HOT 1
- Unable to Invoke lambda function HOT 2
- Mismatch between AWSJSON and AppSync
- Assertions within createSchema method prevent DynamoDB from being null HOT 1
- Incorrect $util.isNullOrEmpty check in appsynce-emulator HOT 3
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 aws-utils.