Compactness and product spaces