Hmm. I have seen it work this way on my system. This is the function you need have invoked http://code.google.com/p/googleappengine/source/browse/trunk/python/google/appengine/datastore/datastore_stub_util.py#1785
Does it work when you call Flush manually? On Tue, Sep 6, 2011 at 12:03 PM, Joshua Smith <[email protected]>wrote: > I don't think this is working the way you believe it is. > > When I run: > > dev_appserver.py --port=8902 --default_partition= --disable_static_caching > --high_replication . > > and create a record, then stop with ^C, then start right back up, that > record is gone. > > Note that ^C sends sigINT which is the same thing the STOP sign on the > launcher sends. > > On Sep 6, 2011, at 1:45 PM, Alfred Fuller wrote: > > You would have to have code that only exists in your dev environment (or > just never gets called in production), that grabs the stub and calls the > function (see ext.testbed for examples of manipulating stubs). It would have > to be triggered by a special url that you would hit right before stopping > the server. > > It is probably much much easier to just run the dev_appserver manually and > use ctrl-c to kill it. > > On Tue, Sep 6, 2011 at 10:27 AM, Joshua Smith <[email protected]>wrote: > >> How do I call Flush() on the stub manually? Do I do this in my main.py >> someplace, somehow? >> >> On Sep 6, 2011, at 1:22 PM, Alfred Fuller wrote: >> >> Apparently not. I believe running the dev_appserver on a command line and >> hitting Ctrl-C will work. The trick is to have the datastore stub's >> destructor invoked, which doesn't happen if the app is hard stopped. You can >> also call Flush() on the stub manually. >> >> On Tue, Sep 6, 2011 at 10:10 AM, Joshua Smith >> <[email protected]>wrote: >> >>> I've updated to 1.5.3, but I still have this problem. >>> >>> How do I "shut down gracefully"? I'm shutting down by pressing the big >>> red STOP button on the launcher. >>> >>> Is there another way? >>> >>> -Joshua >>> >>> On Sep 6, 2011, at 12:51 PM, Alfred Fuller wrote: >>> >>> If the dev_appserver is shut down gracefully, then you should not see >>> this problem (as of 1.5.3). >>> >>> On Tue, Sep 6, 2011 at 8:40 AM, Joshua Smith >>> <[email protected]>wrote: >>> >>>> When I start with --high_replication to test on the dev appserver, I >>>> alway seem to be starting with a blank database. >>>> >>>> I found this issue: >>>> >>>> http://code.google.com/p/googleappengine/issues/detail?id=5305 >>>> >>>> which sounds like the problem I'm having, except that it only has 7 >>>> stars (including mine), and without being able to save my datastore across >>>> runs, debugging this thing is going to take FOREVER. So I'm thinking that >>>> there must be a trick I don't know. >>>> >>>> I ordinarily use --datastore_path so that I don't lose all my data when >>>> I reboot my mac. >>>> >>>> I also have been using --default_partition= so I could access my data >>>> when they changed the sdk a few weeks ago. >>>> >>>> What is the right set of options to use when testing with >>>> --high_replication on the dev appserver, so that your data will be present >>>> across separate runs? >>>> >>>> -Joshua >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "Google App Engine" group. >>>> To post to this group, send email to [email protected]. >>>> To unsubscribe from this group, send email to >>>> [email protected]. >>>> For more options, visit this group at >>>> http://groups.google.com/group/google-appengine?hl=en. >>>> >>>> >>> >>> -- >>> You received this message because you are subscribed to the Google Groups >>> "Google App Engine" group. >>> To post to this group, send email to [email protected]. >>> To unsubscribe from this group, send email to >>> [email protected]. >>> For more options, visit this group at >>> http://groups.google.com/group/google-appengine?hl=en. >>> >>> >>> >>> -- >>> You received this message because you are subscribed to the Google Groups >>> "Google App Engine" group. >>> To post to this group, send email to [email protected]. >>> To unsubscribe from this group, send email to >>> [email protected]. >>> For more options, visit this group at >>> http://groups.google.com/group/google-appengine?hl=en. >>> >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Google App Engine" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]. >> For more options, visit this group at >> http://groups.google.com/group/google-appengine?hl=en. >> >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Google App Engine" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]. >> For more options, visit this group at >> http://groups.google.com/group/google-appengine?hl=en. >> > > > -- > You received this message because you are subscribed to the Google Groups > "Google App Engine" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/google-appengine?hl=en. > > > -- > You received this message because you are subscribed to the Google Groups > "Google App Engine" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/google-appengine?hl=en. > -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
