attach process function