{"action":"created","issue":{"url":"https://api.github.com/repos/FriendsOfSymfony/FOSMessage/issues/5","labels_url":"https://api.github.com/repos/FriendsOfSymfony/FOSMessage/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/FriendsOfSymfony/FOSMessage/issues/5/comments","events_url":"https://api.github.com/repos/FriendsOfSymfony/FOSMessage/issues/5/events","html_url":"https://github.com/FriendsOfSymfony/FOSMessage/issues/5","id":108205569,"number":5,"title":"What is the mission of this library ?","user":{"login":"tgalopin","id":1651494,"avatar_url":"https://avatars.githubusercontent.com/u/1651494?v=3","gravatar_id":"","url":"https://api.github.com/users/tgalopin","html_url":"https://github.com/tgalopin","followers_url":"https://api.github.com/users/tgalopin/followers","following_url":"https://api.github.com/users/tgalopin/following{/other_user}","gists_url":"https://api.github.com/users/tgalopin/gists{/gist_id}","starred_url":"https://api.github.com/users/tgalopin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tgalopin/subscriptions","organizations_url":"https://api.github.com/users/tgalopin/orgs","repos_url":"https://api.github.com/users/tgalopin/repos","events_url":"https://api.github.com/users/tgalopin/events{/privacy}","received_events_url":"https://api.github.com/users/tgalopin/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-24T20:15:04Z","updated_at":"2015-09-30T08:53:05Z","closed_at":null,"body":"While we probably all agree that this library aims to provide user-to-user messaging features, I'm not sure we all have the same idea of what we should really do.\r\n\r\nI discussed quite a lot with @ChristianRiesen about this and we worked on an easy to use API for the library. I want to explain here what is our current idea so it can be discussed and adapted to your needs.\r\n\r\n#### 1. We don't base the work on the current bundle\r\n\r\nWe chose to not base our work on the bundle. We didn't want to be restricted in our ideas by the bundle concepts. So even if some ideas will be the same, please keep in mind we want to create a library from scratch.\r\n\r\n#### 2. The library and framework implementations\r\n\r\n- FOSMessage is conversation-based and supports multiple participants per conversation.\r\n- FOSMessage is divided in two parts: the library and its implementation in frameworks (bundle, module, etc.).\r\n- The library is very simple: it's nothing more than a coherent data structure. We don't provide validation, UI, forms, etc. The developer will use the library as a way to persist and fetch messages in an elegant way.\r\n- The framework implementation of the library (bundle, module, etc.) may implement more things to help the development.\r\n- The library won't implement any \"inbox/sentbox\" system as it's quite complex to define what a sent message is. The framework implementation may implement it in the context of the UI.\r\n- The library is independant from any framework, any persistance system and any user system.\r\n\r\n#### 3. Implementation details\r\n\r\n- The library provides two main components:\r\n    - The Repository to fetch conversations / messages\r\n    - The Sender to start conversations / send messages\r\n- The library provides other components (for the moment only one) that can be used but are optionnal (they will have a seperated documentation page):\r\n    - The Tagger to tag conversations\r\n- The library provides a few models: `Conversation`, `Message`, `PersonInterface` (interface for User model), `ConversationPerson` linking conversations and persons and `MessagePerson` linking messages and persons ;\r\n- A `TagInterface` let the developer implement a tagging system ;\r\n- Drivers let the developpers choose what persistance system they want to use (we decided in https://github.com/FriendsOfSymfony/FOSMessage/issues/1 to limit the persistance systems to Doctrine ORM and Mongo ODM)\r\n- An event dispatcher is available (either a native one to use the library alone or various bridges with famous event dispatchers, for the moment, only Symfony: https://github.com/tgalopin/message/tree/master/src/EventDispatcher)\r\n\r\n#### 4. Usage ideas\r\n\r\nHere is how we would like to interact with the library, as a developer: https://gist.github.com/tgalopin/33641d43f200e8010c2a\r\n\r\nYou can note that there is neither any concept of inbox/outbot nor validation or UI. The library as we plan it is a smart but simple data strcture, and nothing more.\r\n\r\nI worked a bit on an implementation of what we had in mind with Christian (https://github.com/tgalopin/message) so the code can help you see how the library would work from our perspective.\r\n\r\nI am very interested by your opinions about this plan: what do you think the library should be? What was your idea when you thought of a framework-agnostic messaging library? Does this plan fit your needs?"},"comment":{"url":"https://api.github.com/repos/FriendsOfSymfony/FOSMessage/issues/comments/144331039","html_url":"https://github.com/FriendsOfSymfony/FOSMessage/issues/5#issuecomment-144331039","issue_url":"https://api.github.com/repos/FriendsOfSymfony/FOSMessage/issues/5","id":144331039,"user":{"login":"Alexandre-T","id":5101481,"avatar_url":"https://avatars.githubusercontent.com/u/5101481?v=3","gravatar_id":"","url":"https://api.github.com/users/Alexandre-T","html_url":"https://github.com/Alexandre-T","followers_url":"https://api.github.com/users/Alexandre-T/followers","following_url":"https://api.github.com/users/Alexandre-T/following{/other_user}","gists_url":"https://api.github.com/users/Alexandre-T/gists{/gist_id}","starred_url":"https://api.github.com/users/Alexandre-T/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Alexandre-T/subscriptions","organizations_url":"https://api.github.com/users/Alexandre-T/orgs","repos_url":"https://api.github.com/users/Alexandre-T/repos","events_url":"https://api.github.com/users/Alexandre-T/events{/privacy}","received_events_url":"https://api.github.com/users/Alexandre-T/received_events","type":"User","site_admin":false},"created_at":"2015-09-30T08:53:05Z","updated_at":"2015-09-30T08:53:05Z","body":"For an end-user application. I use the earlier FOSMessageBundle version. I had a look of this new project and read this interesting post. I like very much the choosen orientation, implement any inbox/sentbox system as it's quite complex. The TagInterface is a better way to order and filter messages. The frontend developper don't have to implement new features to realise some virtual box. He can easily create a visual \"general inbox\", \"forum inbox\", \"social network inbox\" like Gmail if users are asking boxes. To do it, he only have to override your template.\r\n\r\nYou're interested by our opinion and new use cases. I think that export and batched operations (mass deleting, mass tagging) are features waited by users.\r\n\r\nAn AJAX API will be usefull to retrieve some thread content or filtered thread list.\r\n\r\nSorry for my english, I am not fluent. I hope I have been of some help to you."}}