1. 05 Sep, 2019 1 commit
  2. 04 Sep, 2019 1 commit
    • Brett Walker's avatar
      Upgrade GraphQL gem to 1.8.17 · 9ac82df8693d
      Brett Walker authored
      - Due to https://github.com/exAspArk/batch-loader/pull/32,
      we  changed BatchLoader.for into BatchLoader::GraphQL.for
      - since our results are wrapped in a BatchLoader::GraphQL,
      calling `sync` during authorization is required to get real object
      - `graphql` now has it's own authorization system.  Our
      `authorized?` method conflicted and required renaming
      9ac82df8693d
  3. 26 Aug, 2019 2 commits
  4. 22 Aug, 2019 1 commit
    • Alessio Caiazza's avatar
      Expose namespace storage statistics with GraphQL · ab6190c9290d
      Alessio Caiazza authored
      Root namespaces have storage statistics.
      This commit allows namespace owners to get those stats via GraphQL
      queries like the following one
      
      {
        namespace(fullPath: "a_namespace_path") {
          rootStorageStatistics {
            storageSize
            repositorySize
            lfsObjectsSize
            buildArtifactsSize
            packagesSize
            wikiSize
          }
        }
      }
      ab6190c9290d
  5. 20 Aug, 2019 1 commit
  6. 25 Jul, 2019 1 commit
  7. 17 Jul, 2019 1 commit
  8. 11 Jul, 2019 1 commit
  9. 10 Jul, 2019 3 commits
  10. 04 Jul, 2019 1 commit
    • charlieablett's avatar
      Address reviewer comments · fe08f26fbe67
      charlieablett authored
      - Remove Gitaly call check for fields that have a constant complexity
      declared
      - Add associated test
      fe08f26fbe67
  11. 03 Jul, 2019 5 commits
    • charlieablett's avatar
      Address reviewer comments · 68de7c266861
      charlieablett authored
      - Add 1 for all fields that call Gitaly (with resolvers or without)
      - Clarify comment regarding Gitaly call alert
      - Expose predicate `calls_gitaly?` instead of ivar
      68de7c266861
    • charlieablett's avatar
      Wrap proc properly in gitaly call counts · abd55bb86371
      charlieablett authored
      - Add `calls_gitaly: true` to some fields missing (hey, it works!)
      - Clarify proc wrapping
      - Add kwargs argument to `mount_mutation`
      abd55bb86371
    • charlieablett's avatar
      Alert if `calls_gitaly` declaration missing · 8018f0df92e0
      charlieablett authored
      - Move `calls_gitaly_check` to public
      - Add instrumentation for flagging missing CallsGitaly declarations
      - Wrap resolver proc in before-and-after Gitaly counts to get the net
      Gitaly call count for the resolver.
      8018f0df92e0
    • charlieablett's avatar
      Remove potentially noisy warning · 617d3beaa90c
      charlieablett authored
      - If Gitaly calls are missing, it could be due to a conditional and
      may just become noise
      617d3beaa90c
    • charlieablett's avatar
      Enumerate fields with Gitaly calls · 899513bd2081
      charlieablett authored
       - Add a complexity of 1 if Gitaly is called at least once
       - Add an error notification if `calls_gitaly` isn't right for a
       particular field
      899513bd2081
  12. 28 Jun, 2019 2 commits
  13. 21 Jun, 2019 2 commits
    • Bob Van Landuyt's avatar
      Enforce authorizations for non-nullable fields · 4d616b758733
      Bob Van Landuyt authored
      This makes sure we also enforce authorizations for non-nullable
      fields.
      
      We are defining our authorizations on the unwrapped
      types (Repository). But when a type like that is presented in a
      non-nullable field, it's type is different (Repository!). The
      non-nullable type would not have the authorization metadata.
      
      This makes sure we check the metadata on the unwrapped type for
      finding authorizations.
      4d616b758733
    • Bob Van Landuyt's avatar
      Add authorize to LabelType and NamespaceType · 5c0878b78e6a
      Bob Van Landuyt authored
      This also disables the cop with a reasoning in types where appropriate
      5c0878b78e6a
  14. 20 Jun, 2019 1 commit
    • Bob Van Landuyt's avatar
      Render GFM html in GraphQL · 51cf653f2ef5
      Bob Van Landuyt authored
      This adds a `markdown_field` to our types.
      
      Using this helper will render a model's markdown field using the
      existing `MarkupHelper` with the context of the GraphQL query
      available to the helper.
      
      Having the context available to the helper is needed for redacting
      links to resources that the current user is not allowed to see.
      
      Because rendering the HTML can cause queries, the complexity of a
      these fields is raised by 5 above the default.
      
      The markdown field helper can be used as follows:
      
            ```
            markdown_field :note_html, null: false
            ```
      
      This would generate a field that will render the markdown field `note`
      of the model. This could be overridden by adding the `method:`
      argument. Passing a symbol for the method name:
      
            ```
            markdown_field :body_html, null: false, method: :note
            ```
      
      It will have this description by default:
      
      > The GitLab Flavored Markdown rendering of `note`
      
      This could be overridden by passing a `description:` argument.
      
      The type of a `markdown_field` is always `GraphQL::STRING_TYPE`.
      51cf653f2ef5
  15. 15 Jun, 2019 1 commit
    • Patrick Derichs's avatar
      Add task count and completed count to graphql types · f3907a6b2fb5
      Patrick Derichs authored
      Add specs for task completion status (graphql)
      
      Fix style issues
      
      Changed format of constants in spec
      
      Refactor specs to reduce creation of records
      
      Reduce parameters to merge request creation
      
      Use set's for project and user
      
      Move let's out of it_behaves_like block
      
      Fix description parameter
      
      Fix format of lets
      
      Use dig to get task completion status out of graphql response
      
      Modified rspec output
      
      Add changelog entry
      f3907a6b2fb5
  16. 14 Jun, 2019 2 commits
  17. 11 Jun, 2019 1 commit
  18. 10 Jun, 2019 1 commit
  19. 05 Jun, 2019 3 commits
  20. 04 Jun, 2019 1 commit
  21. 03 Jun, 2019 3 commits
  22. 31 May, 2019 1 commit
  23. 30 May, 2019 1 commit
    • charlieablett's avatar
      Implement logger analyzer · 17a9b8aef10a
      charlieablett authored
      - Modify GraphqlLogger to subclass JsonLogger
      - Replace the single-line analyser with one that can log all the GraphQL
      query related information in one place.
      - Implement analyzer behavior with spec
      17a9b8aef10a
  24. 28 May, 2019 1 commit
    • Phil Hughes's avatar
      Enables GraphQL batch requests · 726ce3f5f082
      Phil Hughes authored
      Enabling GraphQL batch requests allows for multiple queries
      to be sent in 1 request reducing the amount of requests
      we send to the server.
      
      Responses come come back in the same order as the queries were
      provided.
      726ce3f5f082
  25. 22 May, 2019 1 commit
  26. 20 May, 2019 1 commit