Skip to content
This repository has been archived by the owner on Aug 31, 2021. It is now read-only.

Slow deployOnSave with big projects #9

Closed
carlosesilva opened this issue Jan 3, 2018 · 2 comments
Closed

Slow deployOnSave with big projects #9

carlosesilva opened this issue Jan 3, 2018 · 2 comments

Comments

@carlosesilva
Copy link

Description

Hi Marcel,

I am experiencing some pretty lengthy delays between saving a file and the file being actually deployed when using deployOnSave. It would seem that the bigger the package, the longer it takes for a file to be deployed after saving it.

I know that the old extension had the fastCheckOnSave setting which speeds up the deployment on save by a lot but it seems that the new extension doesn't recognize it.

Actual behavior

In a pretty big project (1.5GB and 25,000+ files), I am seeing a 30~60seconds delay after saving a single file for it to be deployed.

Expected behavior

For comparison sakes, the old extension with fastCheckOnSave set to true and the same big project would normally have a ~1 second delay.

Steps to reproduce

  • Open a really big project (25000+ files).
  • Configure it to use deployOnSave.
  • Save a file and see how long it takes for it to deploy the saved file.

Example config

"deploy.reloaded": {
    "packages": [
      {
        "name": "MyLocalPackage",
        "deployOnSave": true,
        "files": [
          "**"
        ],
        "targets": [
          "RemoteSFTP"
        ]
      }
    ],
    "targets": [
      {
        "type": "sftp",
        "name": "RemoteSFTP",
        "dir": "/path/to/remote/dir",
        "host": "example.com",
        "agent": "${SSH_AUTH_SOCK}",
        "user": "username"
      }
    ]
  }

Screenshot

{Please write here, if possible}

Your environment

  • Operating system: macOS Sierra v10.12.6
  • Visual Studio Code version: v1.19.1
  • Extension version: v0.16.2

Additional comments

{Please write here, if there is something more to tell}

@mkloubert
Copy link
Owner

mkloubert commented Jan 4, 2018

@carlosesilva

I have re-added fastCheckOnChange, fastCheckOnSave, fastCheckOnSync and fastFileCheck flags in global and package settings (since version 0.17.0).

"deploy.reloaded": {
    "packages": [
      {
        "name": "MyLocalPackage",

        "deployOnSave": true,
        "fastCheckOnSave": true,

        "files": [
          "**"
        ],
        "targets": [
          "RemoteSFTP"
        ]
      }
    ]
  }
}

The problem is: The extension has to be sure, if a file, that has been saved, is really part of the package ... so it first scans your workspace with the patterns defined in your package.

With the new settings, you can define, if you want do a simply minimatch check instead, as you know that from the old extension.

@carlosesilva
Copy link
Author

This did the trick. Thanks once again @mkloubert !

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants