Skip to content

refactor: NowProto DVC server-side refactoring #1452

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pacmancoder
Copy link
Contributor

@pacmancoder pacmancoder commented Aug 19, 2025

What is included in this PR

  • Updated NowProto DVC server side according to latest changes
    • IO redirection now is optional and could be controlled
    • working directory option for ShellExecute
  • Added logic to restart DVC when the client capabilities message is sent once again.
  • General refactoring of process IO redirection loop / Process spawning logic

Blocked by Devolutions/now-proto#33 and NowProto new release

Copy link

Let maintainers know that an action is required on their side

  • Add the label release-required Please cut a new release (Devolutions Gateway, Devolutions Agent, Jetsocat, PowerShell module) when you request a maintainer to cut a new release (Devolutions Gateway, Devolutions Agent, Jetsocat, PowerShell module)

  • Add the label release-blocker Follow-up is required before cutting a new release if a follow-up is required before cutting a new release

  • Add the label publish-required Please publish libraries (`Devolutions.Gateway.Utils`, OpenAPI clients, etc) when you request a maintainer to publish libraries (Devolutions.Gateway.Utils, OpenAPI clients, etc.)

  • Add the label publish-blocker Follow-up is required before publishing libraries if a follow-up is required before publishing libraries

@pacmancoder pacmancoder force-pushed the refactor/dvc-session-refactoring branch from 597c941 to 8b1bbd6 Compare August 19, 2025 15:08
@pacmancoder pacmancoder force-pushed the refactor/dvc-session-refactoring branch from 8b1bbd6 to e8686d1 Compare August 19, 2025 15:14
@@ -86,22 +87,28 @@ pub fn run_dvc_io(

let messages = message_dissector
.dissect(&pdu_chunk_buffer[HEADER_SIZE..HEADER_SIZE + chunk_data_size])
.expect("BUG: Failed to dissect messages");
.context("Failed to dissect DVC messages");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style:

Suggested change
.context("Failed to dissect DVC messages");
.context("failed to dissect DVC messages");

@@ -19,7 +20,8 @@ impl NowMessageDissector {
.pdu_body_buffer
.filled_len()
.checked_sub(self.start_pos)
.expect("start_pos is greater than filled_len");
.context("Failed to get usable chunk size")?;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
.context("Failed to get usable chunk size")?;
.context("failed to get usable chunk size")?;


post_message_for_pid(self.pid, WM_QUIT, WPARAM(0), LPARAM(0))?;

// TODO: Figure out how to correctly send CTRL+C to console applications.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: Maybe open a Jira ticket for that?

You can then refer to it like that: TODO(DGW-XXX):.

Comment on lines -47 to +48
version = "0.2"
git = "https://github.com/Devolutions/now-proto.git"
branch = "fix/run-directory-api"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

issue(blocking): Just adding a comment for tracking this before we merge.

Copy link
Member

@CBenoit CBenoit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn’t spot anything critical, the code is looking good to me. I’ll leave the rest to you, feel free to merge once you updated the version 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants