task: implement global, cross entity group blob sharing.
i need ancestor group either blobinfo or string-representation of blobkey parent of blobreference objects have strong consistency. construct virtual ancestor group blob-key parent of referencing db-object ...
br = blobreferenece(id=some_id, parent = ndb.key("myblobkey",str(blob))) br.put()
this works in sdk far, concerned is way off documeted paths of appengine.
my previous attempts failed convert blob-key db-key using ndb.key.from_old_key(blobinfo.key()). seems there no legal way "db/ndb" reference blobinfo table (because blobinfo class provides db.model-like interface). missing here?
seems question asking whether can create kind of "virtual ancestor group" specifying parent doesn't exist. legitimate, it's mentioned in docs parent doesn't need exist.
https://developers.google.com/appengine/docs/python/datastore/entities#python_ancestor_paths
alternatively, if list of blobreferences limited, easier , less expensive store list of them inside 1 entity. make key of container entity same blobkey. fetching entity key , modifying let work without eventual consistency problems. it'll cheaper querying , modifying indexed entities.
Comments
Post a Comment