Skip to content

impossible to upload files to google storage with v0.12.0 #470

Description

@aschmid

while 0.11.0 works completely fine i am experiencing huge issues uploading files with the latest (0.12.0) version.

a simple file upload takes forever and might even miss a response.

fs.createReadStream('/local/file.txt').pipe(bucket.file('file.txt').createWriteStream());

not sure what changed between the versions but it broke something.

Activity

  1. ryanseys commented on Mar 30, 2015

    @ryanseys
    Contributor

    Sorry to hear that! Could you try against the latest code in master. We haven't pushed a new version to npm in a while, so you might have better luck with the most up to date code. Let me know how it goes!

  2. aschmid commented on Mar 30, 2015

    @aschmid
    Author

    master or 0.12.0 behave the same.
    in my package.json i tried:

    "gcloud": "0.12.0"
    

    and

    "gcloud": "*"
    

    and both have the same issue.

  3. stephenplusplus commented on Mar 30, 2015

    @stephenplusplus
    Contributor

    The * will just pull down the latest tag version which is 0.12.0. To get master, do npm install --save googlecloudplatform/gcloud-node.

  4. aschmid commented on Mar 30, 2015

    @aschmid
    Author

    ok so tried again with the latest master branch and it still has the same issue.
    tomorrow i might write a package to prove the case.
    this is one of the errors i get after a while waiting for the files to be uploaded.

    Debug: internal, implementation, error 
        Error: socket hang up
      at SecurePair.error (tls.js:1011:23)
      at EncryptedStream.CryptoStream._done (tls.js:703:22)
      at CleartextStream.read [as _read] (tls.js:499:24)
      at CleartextStream.Readable.read (_stream_readable.js:341:10)
      at EncryptedStream.onCryptoStreamFinish (tls.js:304:47)
      at EncryptedStream.g (events.js:180:16)
      at EncryptedStream.emit (events.js:117:20)
      at finishMaybe (_stream_writable.js:360:12)
      at endWritable (_stream_writable.js:367:3)
      at EncryptedStream.Writable.end (_stream_writable.js:345:5)
      at EncryptedStream.CryptoStream.end (tls.js:641:31)
      at Socket.onend (_stream_readable.js:502:10)
      at Socket.g (events.js:180:16)
      at Socket.emit (events.js:117:20)
      at _stream_readable.js:944:16
      at process._tickDomainCallback (node.js:492:13)
    

    this also:

    Debug: internal, implementation, error 
        Error: read ECONNRESET
      at errnoException (net.js:905:11)
      at TCP.onread (net.js:559:19)
    
  5. stephenplusplus commented on Mar 31, 2015

    @stephenplusplus
    Contributor

    It would be great to see a small sample of code. I'm not sure how this would work in 0.11 and not now, but I'm determined to find the cause!

  6. ryanseys commented on Mar 31, 2015

    @ryanseys
    Contributor

    What version of node are you running? The stack trace seems to hint at the fact that the error occurs outside the realms of our library.

  7. aschmid commented on Mar 31, 2015

    @aschmid
    Author

    im using node v0.10.38

  8. added
    type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.
    api: storageIssues related to the Cloud Storage API.
    on Mar 31, 2015
  9. aschmid commented on Apr 1, 2015

    @aschmid
    Author

    ok here it is: https://github.com/aschmid/gcloud.storage.test.git

    just copy your credentials into gcs_keyfile.json and insert a bucket name and projectid in the config.js object.
    after an npm install start with ./bin/start

    this version doesn't work for me, if i change the gcloud version to 0.11.0 in package.json it works as expected.

  10. stephenplusplus commented on Apr 1, 2015

    @stephenplusplus
    Contributor

    After a quick glance, it looks like you're using the end event. Try hooking
    on to the complete event.

    On Wednesday, April 1, 2015, andreas schmid [email protected]
    wrote:

    ok here it is: https://github.com/aschmid/gcloud.storage.test.git

    just copy your credentials into gcs_keyfile.json and insert a bucket name
    and projectid in the config.js object.
    after an npm install start with ./bin/start

    this version doesn't work for me, if i change the gcloud version to 0.11.0
    in package.json it works as expected.

    —
    Reply to this email directly or view it on GitHub
    #470 (comment)
    .

  11. aschmid commented on Apr 1, 2015

    @aschmid
    Author

    i tried the complete too but still same result

  12. aschmid commented on Apr 1, 2015

    @aschmid
    Author

    btw the complete doesnt even work with 0.11.0
    thats why i used the 'end'

  13. stephenplusplus commented on Apr 1, 2015

    @stephenplusplus
    Contributor

    No problem, I'll take a dive in to the code soon. Thanks for putting the
    repo together!

    On Wednesday, April 1, 2015, andreas schmid [email protected]
    wrote:

    btw the complete doesnt even work with 0.11.0
    thats why i used the 'end'

    —
    Reply to this email directly or view it on GitHub
    #470 (comment)
    .

  14. stephenplusplus commented on Apr 2, 2015

    @stephenplusplus
    Contributor

    I changed end to complete and it uploaded the files successfully for me. I'm not sure how we can help, since it's working for us and in our system tests that are run on every change we make to the library.

  15. 53 remaining items

  16. added a commit that references this issue on Feb 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

🚨This issue needs some love.api: storageIssues related to the Cloud Storage API.triage meI really want to be triaged.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions