My MongoDB Experience – Answering beginner’s questions

As mentioned by Martin Fowler Polyglot Persistance is becoming more and more popular each day.

I had a possibility to work with Mongo in my previous project for one of our client Loxysoft and I want to share my first experience of using this DB by answering most frequent beginner’s questions about the DB.

1)Q: How is the data stored in MongoDB?

A: The format of the data in Mongo is BSON, BSON is a binary-encoded serialization of JSON-like documents. BSON is designed to be lightweight, traversable, and efficient. BSON, like JSON, supports the embedding of objects and arrays within other objects and arrays. See bsonspec.org for the spec and more information in general. When we are using relational DB-s we are talking about tuples(or rows), when we are using Mongo the unit is a document.The notion of a table is substituted by the notion of collection. You could think of your database as of a set of collections holding a number of documents each of them aggregating a concept from your domain and storing it as a tree. So the linear structure of a common database became a tree-like structure.
More >

Amdaris now certified under ISO 9001

Amdaris are now certified under ISO 9001:2008. Working through and refining our business processes has been a hugely beneficial experience and has highlighted many gaps and allowed us to fix them. The result is that we are far more confident in our ability to provide a high quality service. We are even sure that our newly defined processes will help our clients with common difficulties as we are now required to enforce procedures that ensure quality. All-in-all the process – although time consuming to implement – has helped us to work better, think better and be far more efficient and confident in our working practices.

ISO 9001 is not just a certificate on the wall, but has changed the whole way we approach quality in our business.

The journey to ISO 9001:2008

Achieving ISO 9001 certification is a strategic decision for management and employees within a company. The purpose of which is to define processes and procedures to ensure quality in all areas of a business.

I had heard about ISO 9001 but my knowledge was pretty patchy.

Last year I received the request from the directors to proceed with the certification process for ISO 9001:2008. So, I began searching on the Internet for information on ISO 9001. I found a lot of articles; information and discussions, but honestly they all seemed pretty ambiguous.

An old Chinese proverb says: “If you want to learn to swim, jump into the water and swim”. So it was clear we just had to jump straight in. This began the ISO “institutionalization” of Amdaris.

More >

Microsoft Test Manager 2010 – my thoughts.

I am currently using Microsoft Test Manager 2010 to create Test cases and execute tests to verify quality. Please see below some Pros and Cons with using this application.

PROS:

1) Able to create well detailed manual test cases.
2) Able to execute the manual test cases with the functionality to record your steps
3) Able to add Parameters and Shared steps to the manual test cases so that you do not have keep rewriting similar steps.
4) From the recorded actions performed in the manual test run, you can automate the tests using Visual studio 2010 for Regression testing.
5) MTM (Microsoft Test Manager) is linked in with TFS (Team Foundation server), so if your analysis and development teams are using this application to record steps in the development cycle, this is a useful application to log bugs and list test cases in MTM to be seen in TFS by the rest of the team.
6) Able to organise Test suites / Cases to assign specific testers to them.

CONS:

1) MTM does have some performance issues which mean that sometimes certain screens freeze up and a relaunch of the application is needed.
2) To use MTM in all its glory, you do need to have a license to Visual Studio Ultimate which will cost your company a small fortune.

WAMP installation on Windows Server 64 bit

Having had to set up WAMP hosting environment’s on a number of server boxes, I often find that WAMPÂ fails to launch once installed. A tray error would be thrown with no real explenation.

More >

Tiny enhancements in NUnit – compile-time Equal type verification

NUnit is a nice framework for unit-testing. But sometimes, we can try improve one micro-aspect of using with introduce compile-time Equals.

Our goal is generate compile-time error on expressions like this:

1
Assert.AreEqual(1, "1");
1
2
3
4
5
6
7
public static class TestExtensions
{
         public static void TestEqual<T>(this T obj, T other)
        {
            Assert.That(obj, Is.EqualTo(other));
        }
}
1
2
3
4
5
        [Test]
        public void CanConvertInteger()
        {
            123.TestEqual("123"); // compile-time error
        }

Also, for arrays can be used the same approach:

1
2
3
4
public static void TestEqual(this T[] arr, T[] otherArr)
{
       // your code here…
}

C# type inference and named parameters.

Suppose you have a generic method like this:

 

1
2
3
4
public static void TestMethod<TLongActionResut>(Func<TLongActionResut> action)
{
// …
}

You could call this method in this way:

TestMethod(() => “123″);

But, if we will use named parameters (http://msdn.microsoft.com/en-us/library/dd264739.aspx):

TestMethod(action: () => “123″);

Compiler will complain: ‘The type arguments for method … cannot be inferred from the usage. Try specifying the type arguments explicitly.’

 

In this example I have shown that type inference isn’t working if we are using named parameters with generics.

Maybe this behavior will be fixed in next versions of C#?

Tested on C# 4.0