- 
                Notifications
    You must be signed in to change notification settings 
- Fork 1.2k
Service capabilities / error behaviors #1163
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
          
     Open
      
      
            benjie
  wants to merge
  27
  commits into
  main
  
    
      
        
          
  
    
      Choose a base branch
      
     
    
      
        
      
      
        
          
          
        
        
          
            
              
              
              
  
           
        
        
          
            
              
              
           
        
       
     
  
        
          
            
          
            
          
        
       
    
      
from
error-behavior2
  
      
      
   
  
    
  
  
  
 
  
      
    base: main
Could not load branches
            
              
  
    Branch not found: {{ refName }}
  
            
                
      Loading
              
            Could not load tags
            
            
              Nothing to show
            
              
  
            
                
      Loading
              
            Are you sure you want to change the base?
            Some commits from the old base branch may be removed from the timeline,
            and old review comments may become outdated.
          
          
  
     Open
                    Changes from all commits
      Commits
    
    
            Show all changes
          
          
            27 commits
          
        
        Select commit
          Hold shift + click to select a range
      
      31c90e7
              
                Detail onError request parameter
              
              
                benjie f4fab96
              
                Detail introspection changes
              
              
                benjie 692d811
              
                Define the directive
              
              
                benjie 94446ab
              
                ABORT -> HALT
              
              
                benjie 3c63355
              
                Start speccing out the capabilities system
              
              
                benjie 7056690
              
                Add a number of basic capabilities
              
              
                benjie 0fa7a33
              
                Move default error behavior to the service
              
              
                benjie 1f975e4
              
                Rework capabilities
              
              
                benjie 8c40086
              
                Use a definition
              
              
                benjie 641a786
              
                Reorder
              
              
                benjie 026982b
              
                Reword
              
              
                benjie a7c6ad5
              
                Editorial
              
              
                benjie fe559ea
              
                More editorial
              
              
                benjie b5f64ae
              
                More editorial
              
              
                benjie 1c3f0cd
              
                Update spec/Section 4 -- Introspection.md
              
              
                benjie 7ab36b8
              
                Merge branch 'main' into error-behavior2
              
              
                benjie cc50991
              
                Change NO_PROPAGATE to NULL
              
              
                benjie df977eb
              
                Overhaul and introduce SDL syntax for service capabilities
              
              
                benjie b1f039c
              
                Update syntax
              
              
                benjie b28ef2f
              
                Simplify
              
              
                benjie 144e854
              
                Update Name syntax
              
              
                benjie dc9315c
              
                Clarification
              
              
                benjie 6fd7239
              
                Minor tweaks
              
              
                benjie c44a7ae
              
                Clarify the interaction of onError:HALT and subscriptions
              
              
                benjie aef7069
              
                Fix grammar
              
              
                benjie 955acd4
              
                Spelling
              
              
                benjie 2fc8b0c
              
                Fix incorrect prefix
              
              
                benjie File filter
Filter by extension
Conversations
          Failed to load comments.   
        
        
          
      Loading
        
  Jump to
        
          Jump to file
        
      
      
          Failed to load files.   
        
        
          
      Loading
        
  Diff view
Diff view
There are no files selected for viewing
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wondering if this should be a more generic "metadata" rather than "capabilities"? It would be essentially the same thing, just a different name and different expectation of what to expect in the list. For example, if some service would like to advertise some form of versioning they could do
{identifier: "com.example.version", value: "4"}but that's not really a "capability" per se?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've thought about this quite a bit, and I think capabilities is better - it's more indicative of intent/purpose.
The aim is that clients can use the "capabilities" of the service to inform their own behaviors in an automated way, such that end users can just point to a GraphQL endpoint and the client will take care of the rest - they don't need to configure it extensively (and the configuration can be automatically updated on each release without frontend engineers needing to do anything).
For example:
onError)The capabilities system can be used for metadata, but that's not its purpose; and calling it metadata significantly changes what is being proposed (and also encourages it to be used for feeding a huge amount more "metadata" into the system). Capabilities inform automated client decisions and actions; metadata is ancillary and often intended for human consumption.
I will try and ensure this is correctly reflected in the spec text.