lib: introduce `.setMaxSendFragment(size)`

fix #6889