SignalR: What is happening under the hood (Part 1)

SignalR provides us the possibility of real time, two way communication between the browser (or any other client) and our server. There are many possibilities on what can you do with this technology, many advantages that you can use, I don’t want to be too wide in one article so I plan to write three of them starting with this one. Here I want to write more about SignalR, what is happening under the hood  and describe some of the main components when building a system on top of it. But what is theory without practice?

signarlRSystem.jpg

That is why, in the second article, I’m going to make sample demo on how to implement SingnalR in your Web API 2 server and also make sample client that will communicate with that server.Read More »

Advertisements

Four In A Row – Golden Award For Cutting Complexity Challenge

Another Codility Challenge is out there, this one is called “Cutting Complexity Challenge” and it’s the fourth that is published this year. The same as the previous three, my solution was awarded with “Golden Award“. What is different about this challenge is that was sponsored by ASML company that is the world’s leading manufacturer of chip making equipment and there are some nice prizes for the best solutions that will be announced after the challenge is over.

CuttingComplexityResults.png  So let’s go briefly through the prizes and the challenge rules that are officially published on ASML website.Read More »

Golden Hat-Trick, another Award for my Nickel 2018 solution

This was the third Codility Challenge this year and for the third time I’m getting Golden Award for my solution. After the Ferrum 2018 and Cobaltum 2018, this award is for the current challenge Nickel 2018. This time I got the solution in my head as soon as I read the assignment and I was doing that while holding a screaming baby in my hand and my 2-year old was destroying the living room in the background. With this task I felt like I wasn’t challenged properly.

Nickel2018GoldenAward.png

Also I didn’t need to solve this in Visual Studio which is the environment that I’m used to and I use to solve these challenges.
Read More »

Do you really want to use :nth-child selector?

This is not the first time I see someone run into this problem so I decided to write few words on this topic. So far I haven’t run into situation or a real need that I have to use :nth-child selector (although it seems to be more popular) instead of :nth-of-type, how often do you think “I want to select the second child of a parent if it just happens to be a paragraph.”. Of course, in the current version of your html you might can make your code to work, your java script or your css, but that can be untriggered bomb for anyone that will inherit your code and which is even worse that anyone can be you in the future.

nthchildVSnthOfType

It’s best to explain this with a practical example. Let’s say that we have a scoreboard with results from an athletic track race. Read More »

Second Codility Challenge – Second Golden Award for me this year

Last week, I tried to solve the second Codility Challenge for this year called Cobaltum 2018. Same as the previous one, Ferrum 2018,  my solution was awarded with the Codility Golden Award. From every other that I did before, this seemed to be the easiest one (or maybe that is just relative perception) although I lost some time to figure out the proper solution that will be elegant and handles the edge cases at the same time.

Cobaltum2018_GoldenAward.png

This time I will not give details about the Codility Challenges, but if you like to have brief intro about how that works you can find out more in my previous article about the Ferrum 2018 challenge or check my Lazy Propagation Segment Tree implementation. Read More »

Lock, Block and Two Concurrent Processes

Recently I had a deadlock or blocking of my Microsoft SQL database while using Entity Framework, of course, it was a bad piece of code that was causing that block. After the blocking occurred I started getting timeout exception for every database action that I wanted to do, even for the basic most simple one queries.

locking-blocking

This specific issue will not be the topic of this article but something more general like what are and why blocks appear, how to detect which is the process that is causing the blocking and what you need to do to stop that process on a database level.Read More »

Golden Award for my Ferrum 2018 solution

From time to time I like to solve interesting algorithmic problems and a while ago I discovered Codility and their challenges. This time the active challenge is called Ferrum 2018 and I managed to get the Golden Award recognition which means that I solved the problem with optimal code execution time and memory complexity.

CodilityGoldenAward

If you like this kind of programming brain teasers you should try to get an award for this one. There are way more complex problems on Codility (for example the Chromium 2017 was one of the more demanding ones, at least for me) but let me give you brief introduction about the awards and the Ferrum 2018 challenge.Read More »