> One entity group per web2py object, lack of list property support,
> etc. dooms the current implementation to "small" web sites. If db.py
> has no tables, will the "Web2py also re-evaluates your model
> definition" overhead vanish?
Yes, and to be practical, there is not much overhead. I was trying to
answer the question, what is the efficiency difference between web2py
and GAE Models, the truth is there is so little difference it should
not be a concern.
Like I said, the web2py DAL interface is remarkable in that it can
allow adding all these GAE features, and make it backward compatible
with SQL DAL. (win-win)
-batch get/put/delete
db(db.table.id.belongs(1,2,3)).select(),
db.table.insert([{},{},{}]),
db.table.delete(1,2,3)
-list-properties
db.table.tags=['a','b','c']
SQL dal already supports this by joining into a delimited string
-transactions by passing a callable
row.update(lambda row: row.counter+=1)
SQL dal would just call the callable, since the request is already a
transaction
-storing keys as fields
store the actual Key as a string field call it key, SQL dal will
simply ignore the field
-setting parent key
models would accept a parent= which is a string or Key
add a parent string field to every GAE DAL table but handle it as a
special case
-key only queries
db(db.table.title=='foo').select(db.field.id)
I remember 1 year ago when I started using the GAE DAL (gql.py) and it
was in very rough shape and did not do what I needed. Fortunately
Web2py is an open source project, so started fixing things to make it
work how I wanted, and fortunately Massimo accepted my patches, and
that is how things got to the current state.
If there is a feature that you need, try adding it with doctests. If
you get stuck, post a question to this list, and I guarantee you will
get an helpful answer to your question.
Robin
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"web2py-users" 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/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---