Bramble is a production-ready GraphQL federation gateway.

Overview

Bramble

Full documentation

Bramble is a production-ready GraphQL federation gateway. It is built to be a simple, reliable and scalable way to aggregate GraphQL services together.

overview

Features

Bramble supports:

  • Shared types across services
  • Namespaces
  • Field-level permissions
  • Plugins:
    • JWT, Open tracing, CORS, ...
    • Or add your own
  • Hot reloading of configuration

It is also stateless and scales very easily.

Future work/not currently supported

There is currently no support for subscriptions.

Contributing

Contributions are always welcome!

If you wish to contribute please open a pull request. Please make sure to:

  • include a brief description or link to the relevant issue
  • (if applicable) add tests for the behaviour you're adding/modifying
  • commit messages are descriptive

Before making a significant change we recommend opening an issue to discuss the issue you're facing and the proposed solution.

Building and testing

Prerequisite: Go 1.15 or newer

To build the bramble command:

go build -o bramble ./cmd
./bramble -conf config.json

To run the tests:

go test ./...

Comparison with other projects

  • Apollo Server

    While Apollo Server is a popular tool we felt is was not the right tool for us as:

    • the federation specification is more complex than necessary
    • it is written in NodeJS where we favour Go
  • Nautilus

    Nautilus provided a lot of inspiration for Bramble.

    Although the approach to federation is similar Bramble has support for a few more things: fine-grained permissions, namespaces, easy plugin configuration, configuration hot-reloading...

    Bramble is also a central piece of software for Movio products and thus is actively maintained and developed.

Comments
  • Question: variables get inlined... where?

    Question: variables get inlined... where?

    @nmaquet @lucianjon @pkqk – I've been surprised to find very little code involving variables and arguments in the codebase. And yet, variables seem to work as expected – I can specify multiple query variables bound for different services, and Bramble seems to inline those values into their appropriate field arguments:

    query($_1: String!, $_2: String!) {
      svc1(input: $_1)
      svc2(input: $_2)
    }
    

    It appears that sub-service requests are never made with proper GraphQL variables – are gateway values always inlined into sub-queries? If so, where in the codebase does this happen? I've scoured all mentions of Variables and Arguments, but have found nothing that seems to perform this etherial transformation. Is this somehow being done by another package?

    Thanks for the insight. This has really got me stumped.

    question 
    opened by gmac 9
  • Add Fedaration gateway example

    Add Fedaration gateway example

    The document is lacking of examples. Can you add a simple working example of how to implement Federation gateway with @bramble? I can't manage to do it. Thank you!

    question 
    opened by thangld322 9
  • Allow compressed response from services to gateway

    Allow compressed response from services to gateway

    Currently, bramble was not able to handle the compressed response (ie., gzip format response) from services. So, added the switch case in the code which handles the compressed response as well from the services

    opened by labala-sravani 8
  • Does Bramble support resolving one field from multiple federated services?

    Does Bramble support resolving one field from multiple federated services?

    Hi, as you mentioned in the doc:

    With the exception of namespaces and the id field in objects with the @boundary directive, every field in the merged schema is defined in exactly one federated service.

    Does this mean any field (even it's a boundary object) should be resolved by only one service? Or in other words, does Bramble support resolving a boundary object with unlimited recursion?

    Here is the use case for your reference:

    ## foo service
    
    type Foo @boundary {
      id: ID!
      title: String!
      bar: Bar!
    }
    
    type Bar @boundary {
      id: ID!
    }
    
    
    ## bar service
    
    type Bar @boundary {
      id: ID!
      subtitle: String!
    }
    

    The schema above works well in Bramble, as we could resolve Foo.bar within the bar service.

    However, it starts failing when we add a new field in Bar, which can only be resolved in the third service:

    ## foo service
    
    type Foo @boundary {
      id: ID!
      title: String!
      bar: Bar!
    }
    
    type Bar @boundary {
      id: ID!
    }
    
    
    ## bar service
    
    type Bar @boundary {
      id: ID!
      subtitle: String!
      baz: Baz!
    }
    
    type Baz @boundary {
      id: ID!
    }
    
    
    ## baz service
    
    type Baz @boundary {
      id: ID!
      status: String!
    }
    

    The query fails when trying to resolve Foo.bar.baz.status: Cannot query field status on type Baz.

    opened by ihac 8
  • Fragment not mapping fields for interface types

    Fragment not mapping fields for interface types

    Problem Statement

    When an interface type is implemented in graphql schema, we are able to query with spread operator and on Type pattern. When we do it by using the Fragments it is not mapping fields inside it when multiple type of interface implemenations are being returned

    In the following PR https://github.com/movio/bramble/pull/153/files in the test case If we fetch either Gadjet Or Gizmo it works. If we want to fetch a list of object where object could be either Gadject or Gizmo it would not work

    Example Request

    interface Book {
      title: String!
    }
    
    type Textbook implements Book {
      title: String! # Must be present
      author: String!
    }
    
    type Magazine implements Book {
      title: String! # Must be present
      publisher: String!
    }
    
    type Query {
      books: [Book!] # Can include Textbook objects
    }
    
    fragment TextBookFragment on Textbook {
          author 
    }
    
    fragment MagazineFragment on Magazine {
          publisher 
    }
    
    query GetBooks {
      books {
        __typename
        title
        ... TextBookFragment
        ... MagazineFragment
      }
    }
    

    Response

     {
        books : [
           {
                 ___typename : "TextBook"
           }
          {
                 ___typename : "Magazine"
           }
       ]
    }
    

    Problem:

    The other fields are not mapped

    opened by dilip9292 7
  • Proposed fix: lock down aliases that may break queries

    Proposed fix: lock down aliases that may break queries

    The Problem

    Field aliases are extremely difficult in federation design because they permit clients to break their own requests by manipulating reserved selection hints. Case of point, here's a busted query:

    query {
      shop1 {
        products {
          boo: id
          name
        }
      }
    }
    

    Here's another...

    query {
      shop1 {
        products {
          id: name
        }
      }
    }
    

    And another...

    query {
      shop1 {
        products {
          id
          _id: name
        }
      }
    }
    

    As demonstrated, there are lots of creative ways to disrupt key selections. This same situation applies when __typename is hijacked as a custom alias on abstract types.

    Proposed solution

    To lock this down, validation errors are necessary to reserve key aliases for implementation details. I would propose that __id and __typename are standardized and reserved as system aliases on boundary types (current _id becomes __id, and the double-underscore becomes a convention of reserved system fields).

    With that, errors are inserted into the query planner to invalidate requests that conflict with reserved aliases:

    // while planning field selections...
    if selection.Alias == "__id" && selection.Name != "id" {
      gqlerror.Errorf("invalid alias: \"__id\" is a reserved alias on type %s", parentType)
    }
    if selection.Alias == "__typename" && selection.Name != "__typename" {
      gqlerror.Errorf("invalid alias: \"__typename\" is a reserved alias on type %s", parentType)
    }
    

    Lastly, __id is always added to boundary types, and __typename is always added to abstract types (there's a PR in the queue for the later change).

    @nmaquet and @lucianjon – feelings on this proposal? If we're aligned on the approach, I'll put a PR together after https://github.com/movio/bramble/pull/89 goes out.

    bug 
    opened by gmac 7
  • Enabling/Disabling schema introspection

    Enabling/Disabling schema introspection

    Hi Team we are currently looking for a way to disable introspection in bramble application. We want users to prevent from doing the following queries

    {
      __schema {
        types {
          name
          kind
        }
      }
    }
    

    Something similar to disable introspection in gql-gen https://github.com/99designs/gqlgen/blob/7435403cf94ce8147fdd9d473a5469d63e7e5b38/graphql/context_operation.go#L20

    Can one help me on how can we achieve this using bramble

    opened by dilip9292 6
  • Fix: user-defined field aliases may break federation

    Fix: user-defined field aliases may break federation

    This adds _bramble_id as a universal ID hint, which allows id to behave as a standard user-defined selection. This fixes the numerous ways to break federation with user-defined field aliases describe in https://github.com/movio/bramble/issues/90 and https://github.com/movio/bramble/issues/93.

    Apologies for the large PR – the vast majority of it is test fixtures.

    The Problem

    As described in https://github.com/movio/bramble/issues/90, there are many creative ways for user-defined queries to break Bramble federation ids using field aliases, for example:

    query {
      shop1 {
        products {
          boo: id
          name
        }
      }
    }
    

    While dynamic adjustments can be made to the query planner to account for such aliases, a user-aliased id still ends up breaking in the execution resolver, per https://github.com/movio/bramble/issues/93.

    A general observation: query planning currently optimizes for vanity queries at the cost of tricky logic holes and extra looping. The process becomes simpler and more reliable when the query planner always adds consistent implementation fields for itself, even if they are redundant with the contents of the user-defined query. Not making id do double-duty as both a user selection and an implementation detail avoids contention between the planning and resolution steps.

    The fix(es)

    • Makes the planner always add a _bramble_id: id selection to boundary scopes. This becomes a universal implementation key, eliminating _id and leaving id untouched as a basic user selection.
    • Validates _bramble_id and __typename aliases. A user selection will not be allowed to hijack these fields.
    • Foregoes vanity queries in favor of eliminating childstep recursion complexity and selectionSetHasFieldNamed looping. Queries are now more verbose, but they are extremely consistent and avoid suspected logic holes.

    Duplicated selections are ugly

    If there’s human sensitivity to duplicated field selections (machines don’t care), then I’d propose adding a single-pass loop at the end of extractSelectionSet that imposes uniqueness once based on field alias falling back to field name. At present, “selectionSetHasFieldNamed” runs for each de-duplicated field, and doesn’t take into account field aliases.

    Resolves https://github.com/movio/bramble/issues/90. Resolves https://github.com/movio/bramble/issues/93.

    opened by gmac 6
  • Hide fields from public federated gateway

    Hide fields from public federated gateway

    opened by hsblhsn 6
  • Fix: broken namespace aliases and mutable selections

    Fix: broken namespace aliases and mutable selections

    Fixes some problems with namespace operations in the query planner, and simplifies the overall logic in the process.

    Problems + Fixes

    query {
      boo: myNamespace {
        product {
          name
        }
        manufacturer {
          name
        }
      }
    }
    
    • The namespace handler condition was demonstrably broken by field aliases: it composed its insertion point using field Name rather than Alias. This issue is now fixed.

    • The namespace condition could also corrupt the user's original selection because it modified fields directly rather than making copies. This was problematic because it modified the selection used to filter the final result, as described in https://github.com/movio/bramble/issues/106. This is also fixed.

    • With the above adjustments made, the namespace condition ended up basically identical to the normal composite field handler. So, this simplifies the logic so that a failed location lookup now just flows into the normal field handlers; this new pattern has the added advantage of handing both leaf values and composite fields.

    Resolves https://github.com/movio/bramble/issues/106 by happy accident.

    opened by gmac 5
  • Fix: fully traverse nested field selections while planning

    Fix: fully traverse nested field selections while planning

    As described in https://github.com/movio/bramble/issues/73, deeply-nested selection paths that transitioned between services were broken. This was a fairly significant issue.

    The problem

    While extracting selection sets, the mergedWithExistingStep check was treating all consolidated fields as leaf values. That means that when a composite field was encountered with its own nested selections, that entire selection set was merged into the current planning step without traversing its children to delegate them properly. This resulted in fields belonging to foreign services getting lumped into the present service selection, and the query failing with a GraphQL validation message:

    Cannot query field <remoteField> on type <LocalType>
    

    The fix

    This adjusts the flow of extractSelectionSet so that all remote fields are collected up front and then create steps once together later in the process. This eliminates the need for the previous step-merging pattern, and is computationally simpler to create steps all at once rather than creating them incrementally for each remote step in sequence.

    Note that this refactor looks bigger than it really is: this simplification was able to remove some conditional nesting and thus decrease the indent on a few existing code blocks.

    Tests

    Tests have been added. There's one update to an existing test where a benign array order has changed due to the revised sequencing of extracting remote fields.

    Resolves https://github.com/movio/bramble/issues/73.

    opened by gmac 5
  • Run tests without output by default

    Run tests without output by default

    Since tests can create log entries on the error level etc, it can look like tests have failed when it is expected output.

    By default send logrus output to io.Discard unless -test.v is true

    opened by pkqk 0
  • Schema being cached?

    Schema being cached?

    We have encountered cases where we make schema modifications in our service and see the changes right away when we query schema in the SERVICE alone, but not in gateway. It behaves like the schema is being cached but it takes a lot of time for a cache to reload (hours sometimes). Is there a cache mechanism and how can we disable it?

    opened by anar-khalilov 0
  • Differentiate log level depending on

    Differentiate log level depending on "response.status"

    https://github.com/movio/bramble/pull/179

    Currently, all requests are being logged as Info (v1.4.3/instrumentation.go:56) and it really results in lots and lots of logs, hence increases costs for our applications.

    As per our application's requirements, we don't want to see logs for HTTP200 responses.

    What we would like to achieve is to log depending on the response.status value like below.

    However, if you come up with a better idea, we are welcome to use it.

    func (e *event) finish() {
    	e.writeLock.Do(func() {
    
    		var logEntry = log.WithFields(log.Fields{
    			"timestamp": e.timestamp.Format(time.RFC3339Nano),
    			"duration":  time.Since(e.timestamp).String(),
    		}).WithFields(log.Fields(e.fields))
    
    		responseStatusCandidate := e.fields["response.status"]
    
    		if responseStatusCandidate == nil{
    			logEntry.Info(e.name)
    			return
    		}
    
    		responseStatusCode, ok := responseStatusCandidate.(int)
    
    		if !ok{
    			logEntry.Info(e.name)
    			return
    		}
    
    		if (responseStatusCode >= 100 && responseStatusCode <= 199){
    			// informational responses
    			logEntry.Debug(e.name)
    		} else if (responseStatusCode >= 200 && responseStatusCode <= 299){
    			// successful responses
    			logEntry.Debug(e.name)
    		} else if (responseStatusCode >= 300 && responseStatusCode <= 399){
    			// redirection messages
    			logEntry.Debug(e.name)
    		} else if (responseStatusCode >= 400 && responseStatusCode <= 499){
    			// client error responses
    			logEntry.Error(e.name)
    		} else if (responseStatusCode >= 500 && responseStatusCode <= 599){
    			// server error responses
    			logEntry.Error(e.name)
    		} else {
    			logEntry.Info(e.name)
    		}
    	})
    }
    
    enhancement 
    opened by anar-khalilov 3
  • Plugin` configuration doesnt depend on config changes

    Plugin` configuration doesnt depend on config changes

    Once plugin configuration was changed in bramble.json file, file watcher handles event and reload config in case of CREATE or CHANGE. But, for example auth plugin doesn`t depend on this reload process, as this object is constructed at the moment of starting Bramble (i tried to change Role section, bramble triggered event changes, but auth plugin was working under old role model)

    opened by ITheCorgi 3
  • Types not used in any query are not getting into compiled schema?

    Types not used in any query are not getting into compiled schema?

    I'm defining types which are not used in any query. I could see them in the downstream service, but not in the compiled schema.

    I'm expecting them to be in the compiled schema so frontend could see those types through gateway.

    Is it a bug or is it inеended?

    opened by benzolium 2
Releases(v1.4.3)
  • v1.4.3(Sep 21, 2022)

    What's Changed

    • Use the default cloudflare recommended timeouts by @pkqk in https://github.com/movio/bramble/pull/162
    • Use correct spelling in limits plugin by @pkqk in https://github.com/movio/bramble/pull/163
    • Use signal.NotifyContext by @pkqk in https://github.com/movio/bramble/pull/164
    • Split large files into smaller chunks by @lucianjon in https://github.com/movio/bramble/pull/159
    • Populate PossibleTypes with merged type by @pkqk in https://github.com/movio/bramble/pull/165
    • Abstract type boundary federation by @mai00cmi in https://github.com/movio/bramble/pull/166
    • Allow disabling of introspection via config by @mai00cmi in https://github.com/movio/bramble/pull/172
    • Update docker-compose setup by @pkqk in https://github.com/movio/bramble/pull/173

    New Contributors

    • @mai00cmi made their first contribution in https://github.com/movio/bramble/pull/166

    Full Changelog: https://github.com/movio/bramble/compare/v1.4.2...v1.4.3

    Source code(tar.gz)
    Source code(zip)
  • v1.4.2(Jul 12, 2022)

    What's Changed

    • Ensure the destination map for merging is never nil by @lucianjon in https://github.com/movio/bramble/pull/160

    Full Changelog: https://github.com/movio/bramble/compare/v1.4.1...v1.4.2

    Source code(tar.gz)
    Source code(zip)
  • v1.4.1(Jun 15, 2022)

    What's Changed

    • Use non recursive algorithm to tidy up SelectionSet for response formatting by @lucianjon in https://github.com/movio/bramble/pull/155

    Full Changelog: https://github.com/movio/bramble/compare/v1.4.0...v1.4.1

    Source code(tar.gz)
    Source code(zip)
  • v1.4.0(May 1, 2022)

    What's Changed

    • Fixed a query execution bug where using fragment spreads over types containing interfaces would not work by @lucianjon in https://github.com/movio/bramble/pull/151
    • Added the method WrapGraphQLClientTransport to the plugin API by @nmaquet in https://github.com/movio/bramble/pull/152
    • Added the method InterceptRequest to the plugin API by @lucianjon in https://github.com/movio/bramble/pull/152

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.9...v1.4.0

    Source code(tar.gz)
    Source code(zip)
  • v1.3.9(Apr 20, 2022)

    What's Changed

    • Fix possible types not being returned for interface introspection by @jainpiyush19 in https://github.com/movio/bramble/pull/148
    • Set operationName explicitly when polling by @lucianjon in https://github.com/movio/bramble/pull/150

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.8...v1.3.9

    Source code(tar.gz)
    Source code(zip)
  • v1.3.8(Apr 14, 2022)

    What's Changed

    • Add request ID plugin by @lucianjon in https://github.com/movio/bramble/pull/146
    • Add operationName to bramble service poll by @lucianjon in https://github.com/movio/bramble/pull/147

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.7...v1.3.8

    Source code(tar.gz)
    Source code(zip)
  • v1.3.7(Apr 13, 2022)

    What's Changed

    • Correctly include subtypes of union in filtered schema. by @lucianjon in https://github.com/movio/bramble/pull/145

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.6...v1.3.7

    Source code(tar.gz)
    Source code(zip)
  • v1.3.6(Apr 11, 2022)

    What's Changed

    • Add nil pointer check for parent definition in extractSelectionSet by @joshiefu in https://github.com/movio/bramble/pull/139
    • Remove service polling client keep alive by @lucianjon in https://github.com/movio/bramble/pull/144

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.5...v1.3.6

    Source code(tar.gz)
    Source code(zip)
  • v1.3.5(Apr 7, 2022)

    What's Changed

    • Remove ModifyExtensions from plugin by @joshiefu in https://github.com/movio/bramble/pull/128
    • Fixed DoS vulnerability in graphql-go package by @azadasanali in https://github.com/movio/bramble/pull/133
    • Restore log output after tests finish by @joshiefu in https://github.com/movio/bramble/pull/127
    • Allow bramble to be used as a library by @joshiefu in https://github.com/movio/bramble/pull/130
    • Remove query caching from exposed gateway by @LeonHuston in https://github.com/movio/bramble/pull/131
    • Improve "not currently supported" part of README.md by @pasdeloup in https://github.com/movio/bramble/pull/137
    • handle failed schema composition in merge test helper by @exterm in https://github.com/movio/bramble/pull/138
    • Use locally built bramble in docker setup by @lucianjon in https://github.com/movio/bramble/pull/140
    • ExecuteQuery refactoring by @lucianjon in https://github.com/movio/bramble/pull/141
    • Increase default polling period to 10 seconds. by @lucianjon in https://github.com/movio/bramble/pull/143

    New Contributors

    • @azadasanali made their first contribution in https://github.com/movio/bramble/pull/133
    • @pasdeloup made their first contribution in https://github.com/movio/bramble/pull/137
    • @exterm made their first contribution in https://github.com/movio/bramble/pull/138

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.4...v1.3.5

    Source code(tar.gz)
    Source code(zip)
  • v1.3.4(Feb 17, 2022)

    What's Changed

    • Improve Bramble timeout support by @joshiefu in https://github.com/movio/bramble/pull/119
    • Handle nullable destinations in results merge of query execution by @pkqk in https://github.com/movio/bramble/pull/123
    • Bump github.com/graph-gophers/graphql-go from 1.2.0 to 1.3.0 in /examples/graph-gophers-service by @dependabot in https://github.com/movio/bramble/pull/118
    • Update gqlgen example deps to latest by @lucianjon in https://github.com/movio/bramble/pull/126
    • Small changes for Movio by @pkqk in https://github.com/movio/bramble/pull/124
    • Add custom http client option to GraphQLClient by @jainpiyush19 in https://github.com/movio/bramble/pull/122

    New Contributors

    • @joshiefu made their first contribution in https://github.com/movio/bramble/pull/119
    • @jainpiyush19 made their first contribution in https://github.com/movio/bramble/pull/122

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.3...v1.3.4

    Source code(tar.gz)
    Source code(zip)
  • v1.3.3(Dec 20, 2021)

    What's Changed

    • Remove unused functions after execution refactor by @lucianjon in https://github.com/movio/bramble/pull/111
    • Fix: broken namespace aliases and mutable selections by @gmac in https://github.com/movio/bramble/pull/108
    • Refactor: interface selections have proper location by @gmac in https://github.com/movio/bramble/pull/107
    • Add handling of ast.Interface to kindToStr by @lucianjon in https://github.com/movio/bramble/pull/114
    • Dynamic boundary argument by @gmac in https://github.com/movio/bramble/pull/115
    • Allow customization of the graph "id" field by @gmac in https://github.com/movio/bramble/pull/116
    • Filter out null boundary results before calling nested child step by @lucianjon in https://github.com/movio/bramble/pull/117

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.2...v1.3.3

    Source code(tar.gz)
    Source code(zip)
  • v1.3.2(Nov 11, 2021)

    This is another small bug fix release, the change in #105 will mean that the reserved alias (now _bramble__typename) for the bramble injected __typename is less likely to conflict with a user defined alias. Now all reserved aliases begin with _bramble.

    What's Changed

    • Fix data race in query execution by @nmaquet in https://github.com/movio/bramble/pull/102
    • Replace mutex with atomic primitives by @nmaquet in https://github.com/movio/bramble/pull/103
    • Fix: merge composite scopes in final selection by @gmac in https://github.com/movio/bramble/pull/104
    • Use _bramble__typename alias for bramble injected __typename by @lucianjon in https://github.com/movio/bramble/pull/105
    • Example of gateway operating in a docker compose environment by @suessflorian in https://github.com/movio/bramble/pull/86

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.1...v1.3.2

    Source code(tar.gz)
    Source code(zip)
  • v1.3.1(Nov 8, 2021)

    This is a bug fix release which includes a number of fixes to Bramble's query planner and an issue where Bramble would fall out of sync with services if they went down and back up again.

    • always add __typename to abstract types. by @gmac in https://github.com/movio/bramble/pull/91
    • fix schema syncing issue. by @lucianjon in https://github.com/movio/bramble/pull/95
    • prevent user-defined aliases from breaking federation. by @gmac in https://github.com/movio/bramble/pull/94

    Small backwards-compatibility breakage: Bramble now rejects queries where __typename is used to alias a field not named __typename or _bramble_id is used to alias a field not named id.

    Full Changelog: https://github.com/movio/bramble/compare/v1.3.0...v1.3.1

    Source code(tar.gz)
    Source code(zip)
  • v1.3.0(Nov 3, 2021)

    This is a significant release that contains a new execution pipeline and important fixes to the query planner.

    New Execution Pipeline

    The code that receives the query plan and executes it step by step, before forming the response has been completely redone. There were enough significant changes we had planned that a rewrite became the simpler approach. While the changes are significant, they are self generally self contained and do not impact the other parts of bramble. The changes are contained in #74. Thanks to @nmaquet, @segfault88, and @suessflorian for the help on these.

    Goals for the new pipeline

    • Handle the bugs that were cropping up when marshalling the merged result back into JSON. The previous approach of using the merged execution result to create the JSON was proving problematic when the shape of the results started to diverge from the request document. This was especially apparent when dealing with fragments and where most of the issues were contained. The new approach instead uses the GraphQL request document to guide the creation of the JSON response, which removes an entire class of bugs.
    • Remove any mutable state between the various execution steps. The previous code shared a map[string]interface{} that was passed between the steps and merged into step by step. This is now done by passing the responses down a channel and is then merged as a seperate stage after all the steps have been executed.
    • Deprecate unmaintained code paths.
    • Some general maintainability and readability improvements.

    Visible Changes

    • The planner now injects __typename when it encounters fragments, this is to aid in marshalling fragments to JSON.
    • Support for the Node interface federation protocol has been dropped. This was briefly in use internally at Movio before the public release of Bramble.
    • Support for opentracing has been dropped, this was another code path that had been implemented early on but unused since.
    • When using the X-Bramble-Debug: timing header, the execution, merging, and marshalling steps are now shown as seperate values.

    Query Planning Fixes

    Huge thanks to @gmac for these, they are contained in #85 and #81.

    Other Changes

    • DOC: fixed typo on installation url. by @hsblhsn in https://github.com/movio/bramble/pull/62
    • Fix documentation on jwt auth by @seeday in https://github.com/movio/bramble/pull/69
    • Give better errors if duplicate boundary query exists by @haydenwoodhead in https://github.com/movio/bramble/pull/55
    • Allow specifying the full listen address in config by @pkqk in https://github.com/movio/bramble/pull/70
    • Update jwt library by @pkqk in https://github.com/movio/bramble/pull/72
    • Add missing dependancies for gqlgen server example by @suessflorian in https://github.com/movio/bramble/pull/77
    • Buffer os.Interrupt channel by @suessflorian in https://github.com/movio/bramble/pull/78
    • Update dependencies and update go to 1.17 by @lucianjon in https://github.com/movio/bramble/pull/82

    Full Changelog: https://github.com/movio/bramble/compare/v1.2.1...v1.3.0

    Source code(tar.gz)
    Source code(zip)
  • v1.3.0-rc.2(Oct 21, 2021)

    • Add missing dependancies for gqlgen server example
    • Buffer os.Interrupt channel
    • No error on fragment expansion when __typename is not required
    Source code(tar.gz)
    Source code(zip)
  • v1.3.0-rc.1(Oct 1, 2021)

    This release contains the rewritten execution pipeline. This change is mostly invisible, however it should greatly improve reliability when using fragments inside federated queries. It also drops support for the deprecated Node interface boundary field resolving support, as well as opentracing support (due to the lack of usage and maintenance).

    Source code(tar.gz)
    Source code(zip)
  • v1.2.1(Jul 7, 2021)

  • v1.2.0(Jun 28, 2021)

  • v1.1.8(May 23, 2021)

  • v1.1.7(May 21, 2021)

    • Preserve fragments when filtering queries (#35)
    • Better handling of execution errors (#36)
    • Add max-age option to CORS (#37)
    • Include user agent in downstream queries (#38)
    Source code(tar.gz)
    Source code(zip)
  • v1.1.6(May 12, 2021)

  • v1.1.5(May 6, 2021)

  • v1.1.4(May 4, 2021)

  • v1.1.3(Apr 14, 2021)

  • v1.1.2(Apr 6, 2021)

  • v1.1.1(Mar 30, 2021)

  • v1.1.0(Mar 25, 2021)

  • v1.0.2(Mar 9, 2021)

  • v1.0.1(Mar 2, 2021)

Vektor - Build production-grade web services quickly

Vektor enables development of modern web services in Go. Vektor is designed to simplify the development of web APIs by eliminating boilerplate, using secure defaults, providing plug-in points, and offering common pieces needed for web apps. Vektor is fairly opinionated, but aims to provide flexibility in the right places.

Suborbital 86 Sep 14, 2022
Couper is a lightweight API gateway designed to support developers in building and operating API-driven Web projects

Couper Couper is a lightweight API gateway designed to support developers in building and operating API-driven Web projects. Getting started The quick

Avenga 73 Nov 18, 2022
GoPrisma - A Go wrapper for prisma to turn databases into GraphQL APIs using Go.

GoPrisma - a Go wrapper for the Prisma Engines What's this? Introspect a database and use it as a GraphQL API using Go. Supported Databases: SQLite Po

Jens Neuse 70 Nov 9, 2022
Apollo Federation Gateway v1 implementations by Go

fedeway Apollo Federation Gateway v1 implementations by Go. ⚠️ This product is under development. don't use in production. ⚠️ TODO implements validati

Masahiro Wakame 10 Apr 9, 2022
protoc-gen-grpc-gateway-ts is a Typescript client generator for the grpc-gateway project. It generates idiomatic Typescript clients that connect the web frontend and golang backend fronted by grpc-gateway.

protoc-gen-grpc-gateway-ts protoc-gen-grpc-gateway-ts is a Typescript client generator for the grpc-gateway project. It generates idiomatic Typescript

gRPC Ecosystem 91 Nov 18, 2022
GRONG is a DNS (Domain Name System) authoritative name server.It is more a research project than a production-ready program.

GRONG (Gross and ROugh Nameserver written in Go) is a DNS (Domain Name System) authoritative name server. It is intended as a research project and is

Stéphane Bortzmeyer 57 Oct 17, 2020
An production-ready microservice using Go and a few lightweight libraries

Go Micro Example This small sample project was created as a collection of the various things I've learned about best practices building microservices

Sean K Smith 97 Aug 11, 2022
Create production ready microservices mono repo pattern wired with Neo4j. Microservices for other languages and front end repos to be added as well in future.

Create Microservices MonoRepo in GO/Python Create a new production-ready project with backend (Golang), (Python) by running one CLI command. Focus on

GoChronicles 14 Oct 26, 2022
go/template is a tool for jumpstarting production-ready Golang projects quickly.

go/template go/template provides a blueprint for production-ready Go project layouts. Credit to Renée French for the Go Gopher logo Credit to Go Autho

Schwarz IT 91 Nov 21, 2022
✨ Create a new production-ready project with backend, frontend and deploy automation by running one CLI command!

✨ Create a new production-ready project with backend, frontend and deploy automation by running one CLI command!

Create Go App 1.6k Nov 19, 2022
sample-go-test-app-vaibhav is a simple example of a production ready RPC service in Go

sample-go-test-app-vaibhav sample-go-test-app-vaibhav is a simple example of a production ready RPC service in Go. Instead of attempting to abstract a

Segment 0 Dec 2, 2021
Production Ready GO - Development Workspace

dev_ProdGO Production Ready GO - Development Workspace Install and Check Version MacOS $brew install go/golang $go version $mkdir -p $HOME/go/{bin,sr

null 0 Jan 6, 2022
Mauliasproxy - a simple room alias proxy that can respond to the federation alias query endpoint

Mauliasproxy - a simple room alias proxy that can respond to the federation alias query endpoint

Tulir Asokan 8 Sep 9, 2022
Authenticating using Workload Identity Federation to Cloud Run, Cloud Functions

Authenticating using Workload Identity Federation to Cloud Run, Cloud Functions This tutorial and code samples cover how customers that use Workload i

null 2 Oct 21, 2022
The Durudex gateway combines all durudex services so that it can be used through a single gateway.

The Durudex gateway combines all durudex services so that it can be used through a single gateway.

null 12 Sep 24, 2022
Ruuvi-go-gateway - Software replica of the Ruuvi Gateway

ruuvi-go-gateway ruuvi-go-gateway is a software that tries to replicate Ruuvi Ga

Scrin 13 Nov 16, 2022
Grpc-gateway-map-null - gRPC Gateway test using nullable values in map

Demonstrate gRPC gateway behavior with nullable values in maps Using grpc-gatewa

null 1 Jan 6, 2022
GraphJin - Build APIs in 5 minutes with GraphQL. An instant GraphQL to SQL compiler.

GraphJin - Build APIs in 5 minutes GraphJin gives you a high performance GraphQL API without you having to write any code. GraphQL is automagically co

Vikram Rangnekar 2.4k Nov 22, 2022
GraphJin - Build APIs in 5 minutes with GraphQL. An instant GraphQL to SQL compiler.

GraphJin - Build APIs in 5 minutes GraphJin gives you a high performance GraphQL API without you having to write any code. GraphQL is automagically co

Vikram Rangnekar 2.4k Nov 21, 2022
GraphJin - Build APIs in 5 minutes with GraphQL. An instant GraphQL to SQL compiler.

GraphJin gives you a high performance GraphQL API without you having to write any code. GraphQL is automagically compiled into an efficient SQL query. Use it either as a library or a standalone service.

Vikram Rangnekar 2.4k Nov 25, 2022