Writing technical specifications is difficult. Writing good technical specifications is even more so. Here’s an excellent practical guide from StackOverflow on how to write technical specifications, which have everything needed, yet not being too excessive or vague.
In the comments, there are a few additional suggestions and links to other similar guides.
The only way this could have been better, if they included a ready-made template with all the described sections, so that one could just fill it in and be done with it.
I have almost 15,000 photos under Creative Commons license on my Flickr account. It’s always fun to see who uses them and how. So far, they’ve made their way into hundreds (if not thousands) blog posts, articles, presentation slides, and videos. Heck, they are even on more than a thousand of Wikipedia pages. The last claim to fame was with the blog post on Forbes.
A couple of days ago, a friend shared with me a link to this YouTube video, where the same (sick?) photo of myself was used (around 26th second). With more than 2.2 million views, I guess, that’s my contribution to the COVID-19/Coronavirus fight.
For quite some time now I wanted to play around with the recently added JSON type in MySQL. Finally, I have a project where MySQL version is high enough to support it, and the requirements are such that this choice makes sense.
The first impression was great – JSON type is basically LONGTEXT type with a bunch of added functionality to manipulate JSON data. It took no time to setup tables and necessary queries to work with it.
The second iteration though raised a few questions. Large tables, with complex JSON structures were rather slow in some of the more complex queries. The first solution to look at was obviously indexes. Turns out, MySQL does not support indexing of the JSON fields. Bummer.
But there is a rather elegant work around. It involves another recently added feature, of which I haven’t heard about until today – GENERATED columns. Think of table views, but on the column level, not table level. And generated columns can be indexed.
In fact, there’s a whole lot that you can do with GENERATED columns in general, and JSON data in particular. This blog post – “MySQL for JSON: Generated Columns and Indexing” – provides a great starting point with examples and explanations, including a scenario with the primary key of the table being a generated column, with the data from the JSON-typed column.