Greening of the Internet has become one of the main challenges for the research community. Optical networks can provide an energy efficient solution, but it has become crucial to assess its power efficiency. In this context, dynamic operation of WDM networks is expected to provide significant power savings when compared to static operation; however, its benefits need to be evaluated to determine its actual impact and to analyze future trends. In this paper, a general framework for evaluating energy consumption in WDM networks is introduced. The proposed framework enables the analysis of different node architectures, link capacities and network topologies. In particular, the case of three different node architectures is discussed and compared. Results show that dynamic operation can significantly reduce power consumption when either the traffic load is below 0.4 or when short-reach transponders consume significantly lower power than long-reach ones. In the latter case, dynamic operation shows significant benefits compared to the static case for traffic loads higher than 0.4. It is also shown that the transponders of the input/output stage of the nodes determine the benefitin terms of power consumptionof an eventual migration from static to dynamic architecture rather than the transponders of the interface between the WDM and higher layers.