Revert "Revert "add documentation""

This reverts commit c994dce5f2097944342a392976bd686f5c05d3ef.
fix topic session null pointer bug
update documentation