You will need to construct a building with the master builder if you don’t have enough resources to construct the building or your workers are already at work. The master builder waits till you have enough resources or your workers have the time to construct your building.
The first entry is the normal task, and the second one is the master builder entry. It will start when the first entry is finished and you have enough resources. At the moment the construction really starts the gold is taken from your account.