Strings of hydrophilic protein! The material expands hundreds of times in volume by absorbing water, similarly to how a little packet of powder can make a bowl of jello but many many times more efficient. The sticky strands bind together as they expand and thus turn the surrounding water into a water-mucus composite instantaneously!
The bucket is a common example of just how quickly the slime works, but it's not the limit. We have never really observed a hagfish "running out" of slime. Similarly, we've almost never gotten any spider to run out of silk. Proteins are simply capable of stretching so far, a little creature can contain thousands of miles worth of goo. Even your own body can technically make enough mucus right now to probably fill a swimming pool! We humans just don't have any defensive mechanism to make that much all at once, at least not without dehydrating to death.
Huh, where is the train ):
















