implementd sub_client and simplified log_record_client and config_client based on that