Consider using "onLayersAddResult" instead of "onLoad".
The documentation for onLayersAddResult states:
Fires after all layers are added to the map using the map.addLayers method
As opposed to "onLoad" which fires after the first layer is added to the map.
In your case I don't think it will cause an issue, but if for example in your "mapReady" function you attempt to call any methods on your "myDynamicServiceLayer", you might get some errors if that layer has not finished loading.