When I think about all the topics I can write about, my head starts spinning. Ever since I joined the ISC, in January this year, I’ve seen so many systems, programs, technologies… And every day I’m working with fun, intelligent colleagues, we recently had a day out of ‘klootschieten’ (curling) on the water with a barbeque after, the list of topics goes on and on.
So I’m going to write about two things that amazed me the most in the last few weeks. Currently I’m working on a project at the NAM. The project is called “TNO Building Sensors”. In Groningen, there are placed multiple sensors that measure acceleration on buildings. Whenever there’s an earthquake, these sensors register the movement (shaking) of the building they are attached to. And the measurements are precise; a sensor records 250 measurements per second! All this data is collected in a database. The ‘potential tremors’ data – potential because the NAM is no authority on saying what is an earthquake and what isn’t – currently exceeds the 5 million records. Wow! And the fun part? The potential tremors are just a fraction of the total data. Most data is generated by heartbeats (every sensor sends one every minute to show it is still working) and the ‘unknown causes’ (someone bumps against the sensor, a train passes by, you name it). In total, we are reaching the 200 million records. The thing that amazes me the most about this ‘big data’? If I’d want to retrieve a specific record out of these 200 million records, it will only cost me a few seconds at most. I knew indexes* were awesome, but this awesome?
So I was talking about two things. The second thing is called NHibernate. According to Wikipedia, NHibernate is “an object-relational mapping (ORM) solution for the Microsoft .NET platform. It provides a framework for mapping an object-oriented domain model to a traditional relational database”. So yeah, right. I just began to understand how cool this is recently. ‘Back in the days’, when I was freelancing, I had to work with databases every now and again. To read and write data, I had to write complex queries and test a lot. With NHibernate, this is in the past. All you need to do is create a file (hbn.xml) that describes your database (table/columns), generate a class that goes with this file and voila, you now can work with your database. You can even make the NHibernate files more complex. Let’s say you have clients who order stuff. You create two hbn.xml files, one describes the order table, the second the client table. In the client.hbn.xml file however, you also map the orders of the client to the list ‘orders’. Now you can use the NHibernate magic and do stuff like _clientRepository.GetAll() (gets all the clients) and see all orders of a client via client.orders. No queries, no trouble, just… magic!
I am really enjoying my project more and more. There are still tons of cool things to learn. I hope that when this project ends, the next cool thing is around the corner, for I feel that I’m very lucky to be on my current project. Thanks for reading and I’ll see you at the ISC!
* = https://en.wikipedia.org/wiki/Database_index