Robert Bosch is to close its Cardiff, UK, auto electrical parts factory at the end of next year with the loss of up to 900 jobs.