hmmm, yet to watch that video (no flash at work), but streams/
followers doesnt sound what Im after.   My app is more about data
mining than tweeting, so rather
than a 'what are you currently reading' type of question its more like
'what is everything have you ever read?"   repeated again every time
someone asks the question.

So I can get what one user has ever read in a query OR I can get which
users are my friends in a query, but I cant join those queries - I
cant think of any way of storing that in a single table that wont
explode.

Unless there is something that Im missing, I think my best bet is to
pull in the list of friends first, as that is likely to be the
smallest list, then pull in lists of friend-read books, friend by
friend, sorting as I go.

Trouble is, if I have 1000 friends, thats 1000 queries?   ugh.....

On Jul 8, 4:55 pm, Martin Webb <[email protected]> wrote:
> Yes thats it - perhaps the word stream is not the most appropriate.
>
> If i read a book which is say horror - in your app that can auto subscribe me 
> to
> books that are of the horror type. which again is just following a book type.
> But the streams and subscribers principle works for lots of solutions. email 
> or
> chat, and activity logs. comments. just use your imagination.
>
> Assuming that perhaps your plan is the have activities and share them with
> followers - which might just be what books they are reading all you do is 
> send a
> message to a stream.
> "hello world" to " user/martin/stream/public_activities - if public facing 
> users
> are subscribed they will get the message. Or "Hello World" mail/martin/inbox".
> Of course in a real world mail system you would put a copy in the senders sent
> and a copy in the recipients inbox - but thats easy.
> [mail/steven/sent,mail/martin/inbox]
>
> # just a simple message class with subscribers - this can be far more
> imaginative
> class message(db.Model):
>     sender = db.StringProperty()
>     body = db.TextProperty()
>
> class message_index(db.Model):
>     receivers = db.StringListProperty() #streams
>
>     def put(stream): #puts a stream list in a message receivers list
>         #should start a worker to append the past list
>         return
>     def move(from_stream,to_stream): #replaces a stream with a new stream
> inbox----.spam
>         #should start a worker
>         return
>     def delete_stream(stream): #removes a stream - this is useful for
> unsubscribe
>         #should start a worker
>         return
>
> As simple as this approach is it just about covers - activity walls,
> email,comments and so on - one concept is lets say I want to flash messages to
> my users "your are now following martin". I just have my Ajax or static page
> "listen" to 'user/martin/flash' and send info messages to 'user/martin/flash' 
> so
> when someone unsubscribes, a message is flashed to inform them the request was
> completed.  Of course you would need to add some security measures to the 
> stream
> class and a mechanism to remove messages - i.e spam folders would clear say
> every 7 days, flashed messages once read clear instantly, in-box messages may
> live forever. Of if you want to save memory and have millions of users have a
> "mail/martin/saved" stream and then add a save message button to emails  (all
> that does is use the message.move(...) method and then set in-box to keep
> messages for say 90 days and the save box to be 'permanent' As you can see the
> stream method now has some very useful functionality from just a small amount 
> of
> api.
>
> Well that's how i am thinking, maybe this can work for you.
>
> Regards
://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.

Reply via email to