<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ceres/view/recipes.go, branch step-re-ordering</title>
<subtitle>Recipe server for your favorite dishes</subtitle>
<id>https://cgit.xengineering.eu/ceres/atom/view/recipes.go?h=step-re-ordering</id>
<link rel='self' href='https://cgit.xengineering.eu/ceres/atom/view/recipes.go?h=step-re-ordering'/>
<link rel='alternate' type='text/html' href='https://cgit.xengineering.eu/ceres/'/>
<updated>2024-10-23T18:34:57Z</updated>
<entry>
<title>Switch to http.Handler</title>
<updated>2024-10-23T18:34:57Z</updated>
<author>
<name>xengineering</name>
<email>me@xengineering.eu</email>
</author>
<published>2024-10-23T18:34:57Z</published>
<link rel='alternate' type='text/html' href='https://cgit.xengineering.eu/ceres/commit/?id=e66691083a2455c29b50a2970c0aba1d6afca753'/>
<id>urn:sha1:e66691083a2455c29b50a2970c0aba1d6afca753</id>
<content type='text'>
The used `func(http.ResponseWriter, *http.Request)` return values made
the HTTP handler factory functions quite unreadable. Thus it is switched
to the http.Handler type.
</content>
</entry>
<entry>
<title>model: Replace global db variable by custom type</title>
<updated>2024-10-13T17:55:38Z</updated>
<author>
<name>xengineering</name>
<email>me@xengineering.eu</email>
</author>
<published>2024-10-13T17:52:28Z</published>
<link rel='alternate' type='text/html' href='https://cgit.xengineering.eu/ceres/commit/?id=473052ed8f2c83052ed5b47a7f4cec68ac2621a6'/>
<id>urn:sha1:473052ed8f2c83052ed5b47a7f4cec68ac2621a6</id>
<content type='text'>
Reducing global variables makes it easier to understand functions
independently of the rest of the code.

Adding the new model.DB type as a custom variant of the sql.DB type
makes it possible to write methods for the database which makes the code
way more readable.
</content>
</entry>
<entry>
<title>model: Fix direct access to database</title>
<updated>2024-10-12T13:24:33Z</updated>
<author>
<name>xengineering</name>
<email>me@xengineering.eu</email>
</author>
<published>2024-05-17T20:49:15Z</published>
<link rel='alternate' type='text/html' href='https://cgit.xengineering.eu/ceres/commit/?id=9d3a5fb85dc02e87fab879855c4c3bace5f753f2'/>
<id>urn:sha1:9d3a5fb85dc02e87fab879855c4c3bace5f753f2</id>
<content type='text'>
Instead a database transaction has to be used. Each database interaction
should be wrapped into a transaction to make sure any possible change
(even side-effects) can be rolled back in case of errors.
</content>
</entry>
<entry>
<title>view: Add 'Read' suffix to function names</title>
<updated>2024-03-03T14:26:07Z</updated>
<author>
<name>xengineering</name>
<email>me@xengineering.eu</email>
</author>
<published>2024-03-03T14:13:55Z</published>
<link rel='alternate' type='text/html' href='https://cgit.xengineering.eu/ceres/commit/?id=b19326df6f372f9dd8f218d0c5b4d2d8b4d4fc35'/>
<id>urn:sha1:b19326df6f372f9dd8f218d0c5b4d2d8b4d4fc35</id>
<content type='text'>
This reflects that these HTTP handler functions implement one of the
four CRUD methods create, read update and delete.
</content>
</entry>
<entry>
<title>view: Implement GET handler for model.Recipes</title>
<updated>2024-02-13T19:26:42Z</updated>
<author>
<name>xengineering</name>
<email>me@xengineering.eu</email>
</author>
<published>2024-02-11T21:44:32Z</published>
<link rel='alternate' type='text/html' href='https://cgit.xengineering.eu/ceres/commit/?id=40868be7d4b9e1d9909a19dccc25ec49c1b5924b'/>
<id>urn:sha1:40868be7d4b9e1d9909a19dccc25ec49c1b5924b</id>
<content type='text'>
</content>
</entry>
</feed>
