There is a continuous stream of data, after all transformations it has next schema:
root |-- message_id: string (nullable = true) |-- device_id: string (nul