custom slug always ends in “-2”

Modification of a slug happens when wordpress detect that the slug is already in use. “In use” in this case includes the posts that are trashed. In your case if you don’t need the id to be associated with the date then you might get better result by using the post id as the id, or implement some incremental counter.

Update:
There was actually a ticket specific to numeric slugs https://core.trac.wordpress.org/ticket/5305. Should be fixed in 4.4

And it eems like there is a collusion detection with date (year) urls.