change some struct to interface
use embed struct for buffer to inherit from stream.
decode amf0 and connect app request.