Uploaded image for project: 'Modules'
  1. Modules
  2. MODULES-8748

powershell : Improve the pipe reading

    XMLWordPrintable

Details

    • Task
    • Status: Resolved
    • Normal
    • Resolution: Fixed
    • None
    • None
    • None
    • None
      • Intermittent error occurs on Linux (Not WSL or Windows)
      • The existing unit tests should not need to be modified and should pass
    • Windows
    • 1
    • Windows 2019-03-20, Windows 2019-03-27, Windows 2019-04-03, Windows 2019-04-10
    • Needs Assessment

    Description

      Previously in MODULES-8358 it was found there was a slight bug in the pipe reader in that it
      wasn't reading all of the data.

      A workaround was put in place as part of comit https://github.com/puppetlabs/puppetlabs-powershell/pull/247/commits/b8db256080b7a7f138b1e2ab13c5e4c25375fe78 however ethan raised some valid concerns over the workaround

      This ticket will track the work to look at using a different pipe reading method which isn't subject to same issues, namely:

      • Just because I chose a chunk of 8K doesn't mean that that is small enough.
      • Concatenation can be an inefficient method of memory allocation. There should be better ways

      Conversation reference:
      https://github.com/puppetlabs/puppetlabs-powershell/pull/247#discussion_r261334543

      Commit
      https://github.com/puppetlabs/puppetlabs-powershell/pull/247/commits/b8db256080b7a7f138b1e2ab13c5e4c25375fe78

      Attachments

        Issue Links

          Activity

            People

              ethan Ethan Brown
              glenn.sarti Glenn Sarti
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Zendesk Support