It does explain how to download and upload, but, as for, uploading is only for production server. You have to look into the command line options, it's not complicated.
Here is a complete example to dump data:
$ python googleappengine/python/bulkloader.py --dump --kind=Kind --url=http://app-id.appspot.com/remote_api --filename=app-id-Kind.db /path/to/app.yaml/ [INFO ] Logging to bulkloader-log-20091111.001712 [INFO ] Throttling transfers: [INFO ] Bandwidth: 250000 bytes/second [INFO ] HTTP connections: 8/second [INFO ] Entities inserted/fetched/modified: 20/second [INFO ] Opening database: bulkloader-progress-20091111.001712.sql3 [INFO ] Opening database: bulkloader-results-20091111.001712.sql3 [INFO ] Connecting to brps.appspot.com/remote_api Please enter login credentials for app-id.appspot.com Email: username@gmail.com Password for username@gmail.com: .[INFO ] Kind: No descending index on __key__, performing serial download ....................................................................................................................................................................................... ................................. [INFO ] Have 2160 entities, 0 previously transferred [INFO ] 2160 entities (0 bytes) transferred in 134.6 seconds
And the following is for upload to Development Server using the sqlite3 database which we just download (not the CSV):
$ python googleappengine/python/bulkloader.py --restore --kind=Kind --url=http://localhost:8080/remote_api --filename=app-id-Kind.db --app_id=app-id [INFO ] Logging to bulkloader-log-20091111.004013 [INFO ] Throttling transfers: [INFO ] Bandwidth: 250000 bytes/second [INFO ] HTTP connections: 8/second [INFO ] Entities inserted/fetched/modified: 20/second [INFO ] Opening database: bulkloader-progress-20091111.004013.sql3 Please enter login credentials for localhost Email: ksdf@sdfk.com <- This does not matter, type anything Password for ksdf@sdfk.com: <- Does not matter [INFO ] Connecting to localhost:8080/remote_api [INFO ] Starting import; maximum 10 entities per post ........................................................................................................................................................................................................................ [INFO ] 2160 entites total, 0 previously transferred [INFO ] 2160 entities (0 bytes) transferred in 31.3 seconds [INFO ] All entities successfully transferred
You will need to specify the app id, which must match the Development server is running on.
This may be no need once the bulkloader.py is stable.
Posts
Email Posts
Comments
0 comments:
Post a Comment
Any irrelevant comments to this post will be deleted. You can use these HTML tags: <b>, <i>, and <a>.