COMU / wish4me

Share and keep your wish online
2 stars 0 forks source link

Notification Page #62

Open enginmanap opened 12 years ago

enginmanap commented 12 years ago

We need some way to notify user with accomplish requests, comments, new followers, and wishes that is wished for them.

farukuzun commented 12 years ago

I can do it with some help i think. There are a lot of actions on the project. Please feel free to add if i miss something. Action IDs. -Commenting On a Wish = 1 -Following an User = 2 -Clicking "me too" button of wish = 3 -Wished for me = 4 -Requests = 5 (what requests? need specific data)

Model needs four columns. to_user_id, from_user_id, action_id, status(1 or 0 - something like readed/unreaded status) Also need to add to UserProfile a column like notification_counter. #Not really needed

First i need to add to base template a notification bar. It Important part is it shouldn't load without click because it may cause to decrease performance. When it loads by click, all notification "status"es are going to be 0. Bar just shows last 5 notification starting by unreaded ones.

Also i need to build some url for users to see all their notifications. Users have an option to delete notifications belong to them.

Should i create another application like "noticifation" or just include the codes to existing one?

enginmanap commented 12 years ago

there is a little debate about how to implement this. Making notifications realtime is one approach, using ajax and checking with some interval (like 10 seconds) is another. I favor the latter, since none of the given notifications require real time.

farukuzun commented 12 years ago

Second sounds good to me too. I'm familiar with ajax but i have never used it with django before.

oguzy commented 12 years ago

For notification issue i suggest to use a task que + pushing service + the websocket part. There are already defined technologies for it.

For task queue: Gearman, RabbitMQ, For Push service: tornado, twisted, pyapn, nodejs For websocket: compatible ajax libraries that will work with the push service is what i know

They need to be investigated first. What we get is a real time notification system.

orcuna commented 12 years ago

I don't think we strickly need real time. We can set AJAX polling request frequency to 1 request per minute (delay is not important)