core: use the metadata in the logdata