In 2008 , Brazil became a net external creditor and two ratings agencies awarded investment grade status to its debt .