Hi Junin,
What's happening is when you add your orderMap to ModelMapper, it attempts to construct a proxy for Order and OrderDTO in order to be able to capture any mappings you define. In order to construct the proxy ModelMapper calls Order's constructor, passing default values in for all of the arguments,in this case passing in null as the value for foo. We could do something more sophisticated such as construct an instance of Foo and pass that in, but ultimately there's no way to predict how a constructor will behave based on the default values that ModelMapper passes in. The goal here is just to construct Order temporarily so that we can capture any mappings defined for it.
This is an area of ModelMapper that could use some consideration, but I'm not sure if it's necessarily a good idea for ModelMapper to construct arguments to pass to a constructor in case the constructor tries to use those arguments since there's still no way of ensuring that the constructor won't fail for some other reason.
Ultimately the best workaround for now is to define a default constructor on Order and OrderDTO to ensure that ModelMapper can construct them without any problems.
Cheers,
Jonathan