Skip to content

Implement more/continues and friends #140

@haraldh

Description

@haraldh

@haraldh Thanks for the quick response.

Introspection works now, thanks! However, I noticed that the metadata in requests and responses does not work in async mode (For example, the more flag in requests or the continues flag in the reply).

This makes it unusable for our use case.

I roughly checked the code, and it seems like the async impl. explicitly sets these to false or to an empty implementation, while the sync implementation uses the trait defaults. Is there any reason for this?

impl varlink::CallTrait for AsyncCall {
    fn reply_struct(&mut self, reply: varlink::Reply) -> varlink::Result<()> {
        self.reply = Some(reply);
        Ok(())
    }
    fn set_continues(&mut self, _cont: bool) {}
    fn to_upgraded(&mut self) {}
    fn is_oneway(&self) -> bool {
        false
    }
    fn wants_more(&self) -> bool {
        false
    }
    fn get_request(&self) -> Option<&varlink::Request<'_>> {
        None
    }
}

Regards,
Philipp

Originally posted by @PhilippMeyerWeidmueller in #138

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions