Measuring or controlling the joining process