{"action":"created","issue":{"url":"https://api.github.com/repos/davidmoten/rxjava-jdbc/issues/19","labels_url":"https://api.github.com/repos/davidmoten/rxjava-jdbc/issues/19/labels{/name}","comments_url":"https://api.github.com/repos/davidmoten/rxjava-jdbc/issues/19/comments","events_url":"https://api.github.com/repos/davidmoten/rxjava-jdbc/issues/19/events","html_url":"https://github.com/davidmoten/rxjava-jdbc/issues/19","id":84343776,"number":19,"title":"Will you consider taking the Dao/Model pattern of JDBI and SpringData?","user":{"login":"gencube","id":663792,"avatar_url":"https://avatars.githubusercontent.com/u/663792?v=3","gravatar_id":"","url":"https://api.github.com/users/gencube","html_url":"https://github.com/gencube","followers_url":"https://api.github.com/users/gencube/followers","following_url":"https://api.github.com/users/gencube/following{/other_user}","gists_url":"https://api.github.com/users/gencube/gists{/gist_id}","starred_url":"https://api.github.com/users/gencube/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gencube/subscriptions","organizations_url":"https://api.github.com/users/gencube/orgs","repos_url":"https://api.github.com/users/gencube/repos","events_url":"https://api.github.com/users/gencube/events{/privacy}","received_events_url":"https://api.github.com/users/gencube/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":26,"created_at":"2015-06-03T03:54:41Z","updated_at":"2015-06-03T12:26:52Z","closed_at":null,"body":"Will you please also consider taking these code pattern from JDBI or SpringData?\r\nhttp://jdbi.org/\r\n```java\r\npublic interface MyDAO\r\n{\r\n  @SqlUpdate(\"create table something (id int primary key, name varchar(100))\")\r\n  void createSomethingTable();\r\n\r\n  @SqlUpdate(\"insert into something (id, name) values (:id, :name)\")\r\n  void insert(@Bind(\"id\") int id, @Bind(\"name\") String name);\r\n\r\n  @SqlQuery(\"select name from something where id = :id\")\r\n  String findNameById(@Bind(\"id\") int id);\r\n\r\n  /**\r\n   * close with no args is used to close the connection\r\n   */\r\n  void close();\r\n}```\r\n\r\nOR Model+Repository pattern from springdata:\r\nhttps://github.com/spring-projects/spring-data-book/tree/master/mongodb\r\n\r\n```java\r\npackage com.oreilly.springdata.mongodb.core;\r\nimport org.springframework.data.repository.Repository;\r\n\r\n/**\r\n * Repository interface to access {@link Customer}s.\r\n * \r\n * @author Oliver Gierke\r\n */\r\npublic interface CustomerRepository extends Repository<Customer, Long> {\r\n\r\n\t/**\r\n\t * Returns the customer with the given identifier.\r\n\t * \r\n\t * @param id\r\n\t * @return\r\n\t */\r\n\tCustomer findOne(Long id);\r\n\r\n\t/**\r\n\t * Saves the given {@link Customer}. #\r\n\t * \r\n\t * @param customer\r\n\t * @return\r\n\t */\r\n\tCustomer save(Customer customer);\r\n\r\n\t/**\r\n\t * Returns the {@link Customer} with the given {@link EmailAddress}.\r\n\t * \r\n\t * @param string\r\n\t * @return\r\n\t */\r\n\tCustomer findByEmailAddress(EmailAddress emailAddress);\r\n}\r\n```\r\n\r\n**However have OPTIONS to handle the commonly used pattern in Reactive or Sync model??**"},"comment":{"url":"https://api.github.com/repos/davidmoten/rxjava-jdbc/issues/comments/108363462","html_url":"https://github.com/davidmoten/rxjava-jdbc/issues/19#issuecomment-108363462","issue_url":"https://api.github.com/repos/davidmoten/rxjava-jdbc/issues/19","id":108363462,"user":{"login":"davidmoten","id":318187,"avatar_url":"https://avatars.githubusercontent.com/u/318187?v=3","gravatar_id":"","url":"https://api.github.com/users/davidmoten","html_url":"https://github.com/davidmoten","followers_url":"https://api.github.com/users/davidmoten/followers","following_url":"https://api.github.com/users/davidmoten/following{/other_user}","gists_url":"https://api.github.com/users/davidmoten/gists{/gist_id}","starred_url":"https://api.github.com/users/davidmoten/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidmoten/subscriptions","organizations_url":"https://api.github.com/users/davidmoten/orgs","repos_url":"https://api.github.com/users/davidmoten/repos","events_url":"https://api.github.com/users/davidmoten/events{/privacy}","received_events_url":"https://api.github.com/users/davidmoten/received_events","type":"User","site_admin":false},"created_at":"2015-06-03T12:26:52Z","updated_at":"2015-06-03T12:26:52Z","body":"I'd be delighted to meet you there, I love Malaysian food (all of its many varieties)."}}