issue #3939 Refactor createWithXXX function into one unified create function with different parameters for Node