Closed cgarciae closed 9 years ago
Strange, how can we get more info from GAE :s
INFO: default: "GET /_ah/health?IsLastSuccessful=no HTTP/1.1" 503 - WARNING: All instances may not have restarted
Looks like he has problems with restarting himself, I had this issue too.
Can you stop your gcloud process and try again?
I am running it locally through gcloud preview app run app.yaml
.
It seems like it works here ...
You need to do pub build also ... but you can also define DART_PUB_SERVE environment in your docker instance.
I am afraid your issue is something GAE related that you encounter ... can you verify this? I will try to work on a version of GAE that works on my machine and put this online ;)
Hopefully this helps you a bit forward!
I get message Info: Instances restarted
and not:
WARNING: All instances may not have restarted
try to update your gcloud components like follow:
gcloud components update app
Updated gcloud
and nothing. Are you running the same scripts as me? Maybe there is something wrong with my server.dart
. When I use this "Hello World" code from the GAE tutorial
import 'dart:io';
import 'package:appengine/appengine.dart';
main() {
runAppEngine((HttpRequest request) {
request.response
..write('Hello, world!')
..close();
});
}
it works perfectly.
I did some test, it has something todo with websockets, when the client tries to establish a websocket connection he fails! So how can we fixed that? Do you know where we can find more logging from appengine? So we can see stacktraces, and info messages from the logging?
Just try to comment ForceClient, if that also works on your side then we are on the same line ;-)
Then we need to figure out why the websockets are not working, it would be great if you could help me out on that one!
I saw a post about websockets on AppEngine, it seems you have to configure GAE/Docker to open some ports and channel the connection through those. Will try to find the post.
I uploaded a appengine example: https://github.com/jorishermans/appengine-force-example
It uses long polling for the moment until we figured out how to use, enable websockets on appengine!
Your code was really useful. It turns out I had a bug on my code. It working fine now and tested on a real URL on App Engine.
I've same problem :s
Is it a dart force or a forcemvc problem? I know that you need to configure app engine to work with websockets, I need to dive into it too see how you can do that. A normal forcemvc project should work.
Look at my uploaded example https://github.com/jorishermans/appengine-force-example
This is how you can debug on google app engine, getting more info and maybe stacktrace info about what is going wrong.
http://stackoverflow.com/questions/26807828/how-can-i-debug-a-dart-appengine-app
This can help me to guide you!
This is my code https://github.com/scne/dartrest Maybe there is something wrong?
remove:
// Start serving force with a randomPortFallback webApp.start(fallback: randomPortFallback);
in server.dart and try again
The appengine runtime starts your app, so starting it with ForceMVC is not needed.
if this doesn't help let me know and I will debug it later today.
Nothing! This is screenshot of shell. I follow this guide https://www.dartlang.org/cloud/setup.html
Can you run this command.
gcloud --verbosity debug preview app run app.yaml
Will it give you more debug info? If so please put that info here.
Also killing your docker proccess and starting it again can help.
INFO: Creating container... INFO: Container e40102016036bcc2bc36a3b4f5a39c2c427a107e8ead3f86d025cdce950e25af created. DEBUG: Container: e40102016036: Observatory listening on http://0.0.0.0:8181 DEBUG: Container: e40102016036: 'package:forcemvc/server/serving_files.dart': error: line 46 pos 71: use flag --enable-async to enable async/await features Future serveFile(HttpRequest request, String root, String fileName) async { ^ DEBUG: Automatic cleanup... DEBUG: Cleanup finished. INFO: default: "GET /_ah/health?IsLastSuccessful=no HTTP/1.1" 503 - DEBUG: Health check response [''] and status 503 Service Unavailable for instance 0. DEBUG: Health check state for instance: 0: 3 consecutive UNHEALTHY responses. DEBUG: Performing health check for instance 0.
Ow I see you are using my github version that is using await, great, try to start it with this command.
gcloud --verbosity --enable-async debug preview app run app.yaml
ERROR: (gcloud) argument --verbosity: expected one argument
Maybe after --verbosity
I have to use debug preview ...
It is a dartvm parameter that you need to add, don't know how to do that, maybe within app.yaml file.
Otherwise just use latest version from within pub and don't point to my github repo.
forcemvc: ">=0.5.10 <0.6.0"
5.10 doesn't use the await/async syntax, going to search how we can use this in app engine.
With version 0.5.10 is ok!
I have this minimal code and I keep getting
when I try to start the local server. Here is the code
server.dart
angularforce.html
angularforce.dart