I’ve previously watched the 5km Parkrun in Watford, Brighton and Hove, and in my hometown of Esbjerg in Denmark, but until May Saturday 18th, 2019 I hadn’t done a single run 😨
I’ve done plenty of half marathons in training and a few of the Watford Half marathons in the month of February, and in Berhamsted in March. So, I went there this Saturday gone with my barcode and found that it is a rather tightly knit bunch a happy runners, welcoming newbies like myself. I felt very welcome, especially during the short run, where comments and smiles were exchanged. Just lovely, and I’ll definately tr and take part in these Saturday morning runs, wherever I am in the World. Not having done 5km runs for a long time, I was quite pleased I managed to finish in 22m37s. 🙂
You should try it in a place near you.
SOLID contains five design principles that are used to make it easier to understand software designs.
Any class should only have a single responsibility, i.e. the
class should have only a single job/task. In simple terms, if you have a Vehicle class that process any number of vehicle objects. If the processed
vehicle objects need to be stored or serialised, both the storage and serialisation tasks can easily be added to the class, but they shouldn’t.
Only changes to one part of the software’s specification should be able to affect the specification of the class, so what if the storage type changes from a database to blob or table storage or the serialisation changes from say XML to JSON? You’d be violating the Single Resposibility principle, but creating a new class for either or both of these tasks and let them handle the storage or serialisation tasks, will work without violating this principle.
Any software entity, class, should be open for extension, but closed for modification, i.e. the class should be easily extendable, but without modifying the existing class. In simple terms, if you have a Vehicle class that process any number of different vehicle objects Car, Van, Bus etc. For each processed vehicle object , the exhaust emission must be calculated. Assume that the calculation is different for each vehicle type. The class method that does the calculation must check each vehicle object for the actual type, and base the calculation on that. Now, if all types of vehicles are known at the time of the Vehicle class being written, no problem. However, in reality new types of vehicles are introduced frequently, so the calculation method is violating the Open Closed principle, because adding calculation for new vehicle types, requires the calculation method to be modified. To address this, each vehicle type class must come with their own calculation method. This way, when you’re creating a new type of vehicle class, and assuming you’re inheriting from the same abstract class or interface, you’re extending the Vehicle class, not modifying it.
Objects in an application should be replaceable with instances of their subtypes without altering the correctness of the application. If you have a class Vehicle, and any number of subtypes thereof, say Car, Bicycle, Bus, you hould to replace super class with any of the subtypes. Typically Inversion of Control (IoC) or Dependency Injection (DI) is used to inject the super type or any of the subtypes into a class Controller. You need to ensure that the injected objects do not alter how the Controller process and output results.
Visual Studio 2019 was released early April in 2019 of all years… 😱😂 I’ve been using preview versions and the release candidate for a number of months and I’ve rarely had any issues. Having said that, I’ve had Visual Studio 2017 installed all along, just in case 😉
I like the new version, and just days ago an update was uploaded. I didn’t experience any of the issues that was fixed in version 16.01.1. If you’re still on the 2017 edition, please try the 2019 version, as it is really good. It takes a little getting used too, but we’re talking days only.
Check out https://docs.microsoft.com/en-us/visualstudio/releases/2019/release-notes for more
I signed up for the Microsoft Edge Insider programme, where Microsoft has based the Edge browser on the Chromium open source project. I’m now on the Dev Channel, and I really like what I see and fell. Check it out, https://www.microsoftedgeinsider.com/en-us/.
If you already have a database and want to use EF Core for your database/object mapping, the Scaffold-DbContext command can be run from within Visual Studio, using the Package Manager Console. If it isn’t open, you can get to it from the View/Other Windows menu command. This is an example of how to generate DbContext and entity mapping objects:
Scaffold-DbContext “Server=.\SQLEXPRESS01;Database=***;Trusted_Connection=True” Microsoft.EntityFrameworkCore.SqlServer -OutputDir Objects
The command targets SQL Server using the currently logged on user account. Make sure you select the correct project, if you more than one in your solution, from the Default Project list in the
Package Manager Console.
Notice how I have a single backslash for the server name. In your connection string, potentially stored in the appsettings.json file, you’ll need two backslashes, Server=.\\SQLEXPRESS01. If you have two backslashes when running the Scaffold-DbContext command, the command will fail, with this exception:
System.InvalidOperationException: Instance failure.
at System.Data.SqlClient.TdsParser.Connect(ServerInfo serverInfo, SqlInternalConnectionTds connHandler, Boolean ignoreSniOpenTimeout, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, Boolean withFailover)
Don’t forget the -Force option in your command, if you want to replace an existing DbContext and mapping objects.
I saw this new build in Visual Studio 2017 in the Notification window yesterday, and also noticed that you can now build for ARM
Er du udlandsdansker, og på vej til Danmark ved jule- eller nytårstid? Så kig lige her https://hertz.viabiler.dk/udlandsdansker, og hvis du ikke allerede har modtaget en email fra Club DK, så læs nedenfor.
| Vi er meget stolte over Club DK og over at have medlemmer fordelt på 149 lande. |
Vi synes, at I er spændende og er nysgerrige omkring jeres eventyr ude i verden og jeres glæde ved at komme hjem.
Vi vil som noget nyt introducere Club DK interviews i filmformat.
Har du lyst til at blive interviewet om livet ude på eventyr og det helt særlige ved at komme hjem?
Hvornår: i december/januar
Hvordan: Interview i en bil
Varighed: Ca. 30 minutter
Færdigklippet interview: Ca. 3 minutter
Som tak for deltagelse giver vi en voucher til et weekendlejemål (bilgruppe C) som kan benyttes i løbet af 2019.
Vi kontakter de personer, som er i Danmark de datoer, hvor det er muligt for os at filme.
Har du spørgsmål er du mere end velkommen til at kontakte firstname.lastname@example.org. Tilmeld dig her
Azure Table Storage is cheap and in some simple uses, as good as CosmosDB. However, when searching a single table storage (Standard Performance) with millions of rows, then the key to speeding up searching for specific entities or traversal through all entities, requires you to use both the partition key and row key values, but none of the other field values. Obviously, if you have multiple different values in either or both of the partition key and row key fields, you’ll have a problem with the speed of a search. In that case, CosmosDB will be a better option.
The code below shows how to search the a storage table using the partition key and row key fields. A look up table is used for the partition key and the date is used for the row key. Obviously, the storage table, which holds the different partition keys, needs to be maintained. The “duplicated” date in the row key mimics the timestamp field, but you can use pretty much any date type and format instead, as long as you a have simple way of searching this field.
There’s also an upload function, if you want to take advantage of a very cheap storage option, even for million of entities…
I have an Azure function that takes care of updating the partition keys table, using a timer trigger on a monthly basis.
I just installed this build and it was definitely the lengthiest setup in a good few months, but it’s now back up and everything seems to work as it should, even if I do have an issue with the tobiie Eyex driver/software 😱