Skip to content
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

Not able to deploy on Google App Engine #1639

Closed
sublee opened this issue Nov 11, 2018 · 3 comments
Closed

Not able to deploy on Google App Engine #1639

sublee opened this issue Nov 11, 2018 · 3 comments
Labels

Comments

@sublee
Copy link

sublee commented Nov 11, 2018

  • go version: 1.9.7
  • gin version (or commit ref): 37854ee
  • operating system: Ubuntu

Description

Since 37854ee, Gin started to import syscall at recovery.go. This made Gin apps not able to be deployed in Google App Engine. Because Google App Engine doesn't allow to import syscall for security reason.

The majority of pure Go packages work on Google App Engine. A package may not work because of one of these reasons:

  • The package imports syscall or unsafe.
  • The package uses cgo or assembly.
  • The package requires functions in packages that are locked down, such as writing to disk, or direct network access.

In https://cloud.google.com/appengine/kb/, I could find those restrictions.

Screenshots

image

@sublee sublee changed the title "syscall" indicates Google App Engine deployment failure Not able to deploy on Google App Engine Nov 12, 2018
@thinkerou
Copy link
Member

thinkerou commented Nov 12, 2018

@sublee thanks your feedback, I will handle it tonight. May be use string compare instead of ne, ok := err.(*net.OpError).
cc @justinfx

@justinfx
Copy link
Contributor

Sorry, I haven't had any experience with GAE so I wasn't aware of that limitation. After a quick search on the matter, I think you may be right, @thinkerou. Seems assertion will have to end once you have the OpError and do string testing to see if it's EPIPE or ECONNRESET. You may also be able to see if calling OpError.Temporary() works just for the ECONNRESET check.

@thinkerou
Copy link
Member

please see #1640 thanks!

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

No branches or pull requests

3 participants