This cannot be answered in this way, as there are a large number of axle systems and variants. This depends on the wheel manufacturer and thus the axle system. The length of the axle says nothing about compatibility. I recommend what works safely and is adaptable: