Giter Site home page Giter Site logo

atlas-gentool's People

Contributors

addudko avatar anpiakhota-infoblox avatar askurydzin avatar atorgayev avatar brocwoodworthiblx avatar calebjh avatar chinmayb avatar dependabot[bot] avatar dmacthedestroyer avatar drewwells avatar evgeniy-l avatar kd7lxl avatar khous avatar kumaya avatar razamidev avatar sbhagate-infoblox avatar zacheddy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

atlas-gentool's Issues

auto-generated code with gateway/v2 break atlas applications

Looks like we have switched tooling to gateway/v2, my ‘make protobuf’ broke as infoblox/atlas-gentool:latest emits gateway/v2 stubs. I tried to covert my app to use the new app-toolkit, it compiles but takes a run time error:

proto: extension number 1042 is already registered on message google.protobuf.FileOptions

See https://developers.google.com/protocol-buffers/docs/reference/go/faq#namespace-conflict

I created a new atlas app using:

atlas init-app -gateway -pubsub -health -helm -name cost-insights-backend -registry soheileizadi -kind

I built and ran this app and it gave me the same panic message.

I debugged this problem, Proto ExtensionType being registered that throws error is:

grpc.gateway.protoc_gen_swagger.options.openapiv2_swagger

I removed the following import from my ‘service.pb.go’ auto-generated code:

_ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options"

The init of the library was registering extension that was causing the problem,
with that change I can run my application now. I am logging this with the gentool but might require additional
supporting atlas app toolkit.

Update to use new version of tools

Replace dep/glide with go modules and make sure this code generation issue is fixed in
atlas-cli:

https://github.com/infobloxopen/atlas-cli/issues/60#issuecomment-644542690

Support multiple architectures

Some systems like the newer MacBooks with M1 chips don't support the current images being pushed to DockerHub, and can't be built locally because of the UPX package not being present on the arm64 alpine image.

I get empty fields marshalled when switching from older gentool and app-toolkit to newer tooling

Here is a sample message as seen from client from old tooling:

{"id":"EC2","aggregation":[104732,107374],"entities":{}}

Versus new tooling:

{"type":"","id":"EC2","aggregation":[69393,59305],"entities":{}}

There are many other fields emitted but just focused on the top level type field as a sample
The autogenerated code have the omit-empty option:

type Entity struct {
....

	Type          string           `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
	Id            string           `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"`
....
}

Atlas Gentool v21.3 Ignores lyft/proto-gen-validate Plugin rules.

While v21.2 renders validate rules rules, in 21.3 these rules are omitted.

+       // no validation rules for Name
 
-       if utf8.RuneCountInString(m.GetDescription()) > 255 {
-               return ProfileLDAPValidationError{
-                       field:  "Description",
-                       reason: "value length must be at most 255 runes",
-               }
-       }

Also, lyft has been renamed to envoyproxy, which will also cause go.mod errors if using version > 0.1.0.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.