Might be the root cause of #15896
The index content bytes were passed via unsafe.Pointer,
which shall be copy to cpp managed memory inmediately
This solution might cause a lot of memory consumption.
Maybe we need to store the index bytes in cpp memory in the first place.
Signed-off-by: Congqi Xia <congqi.xia@zilliz.com>