In a thermonuclear reactor plasma interacts with the divertor walls in the form of periodic heat pulses as well as constant heat load. As a result, residual plastic deformations and mechanical stresses can occur, which cause destruction of the divertor material. However, these residual deformations and stresses can be relieved under the influence of constant flux of plasma and the consequential high temperature of the material. The goal of this work was the study of residual stresses dynamics in a heated material. Residual deformations and stresses were measured using X-ray diffractometry. The measurements were conducted on tungsten samples that were irradiated with an electron beam on the BETA facility with the purpose of simulating plasma heat loads. Synchrotron radiation scattering station “Anomalous scattering” on the beam line 2 of VEPP-3 was used to measure diffractograms from which scattering angle - sample tilt angle dependencies were obtained. The experimental data was used for calculation of deformation and stress tensor components. To compare heat load and residual stress profiles the measurements were conducted with spatial resolution. Synchrotron radiation scattering station “Diffraction movie” was used for measuring the dynamics of residual stresses during heating. As a result of these experiments scattering angle - temperature dependencies were obtained. Residual stresses relaxation was measured, the result has met our expectations.