Fix various deprecation usages.Change-Id: I2609f865d94a73e2410aa6c3c8e38e6d7766cf7c Signed-off-by:Alexander Kurtakov <akurtako@redhat.com>