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

For subscriptions, router should auto re-connect after subgraph server restarts #972

Open
agufagit opened this issue Jul 28, 2024 · 2 comments
Labels
bug Something isn't working internally-reviewed The issue has been reviewed internally.

Comments

@agufagit
Copy link

Component(s)

router

Component version

v0.98.2

wgc version

v0.58.5

controlplane version

n/a

router version

v0.98.2

What happened?

Description

For subscriptions, router doesn't auto re-connect when subgraph server restarts

Steps to Reproduce

  1. open a websocket connection to router, make a subscription call, router will open a new websocket connection to subscription subgraph server
  2. restart subscription subgraph server

Expected Result

  1. router auto re-connects to subscription subgraph server, open a new websocket connection and remake that subscription call

Actual Result

  1. the websocket connection between router and subscription subgraph server is gone

Environment information

Environment

OS: Ubuntu 20.04
Package Manager: pnpm
Compiler: go 1.22

Router configuration

dev_mode: true
listen_addr: 0.0.0.0:3009
router_config_path: config_dev.json
authentication:
  providers:
    - name: Auth Provider
      jwks: # JWKS provider configuration
        url: http://auth-gateway:8085/.well-known/jwks.json
        header_names: [Authorization]
        header_value_prefixes: [Bearer]
        refresh_interval: 2h
authorization:
  require_authentication: true
websocket:
  absinthe_protocol:
    enabled: false
file_upload:
  enabled: true
  max_file_size: 50MB
  max_files: 2
graph:
  # Result of `wgc router token create`. Can be omitted for local testing.
  token: ""

Router execution config

I'm testing locally.  I'm using custom modules, so I'm building router image locally.  Custom module code just maps JWT claims information to headers of subgraph requests

Log output

No response

Additional context

No response

@agufagit agufagit added the bug Something isn't working label Jul 28, 2024
Copy link

WunderGraph commits fully to Open Source and we want to make sure that we can help you as fast as possible.
The roadmap is driven by our customers and we have to prioritize issues that are important to them.
You can influence the priority by becoming a customer. Please contact us here.

@StarpTech
Copy link
Contributor

Hi @agufagit thank you for the report. We will take a look and come back.

@StarpTech StarpTech added the internally-reviewed The issue has been reviewed internally. label Jul 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working internally-reviewed The issue has been reviewed internally.
Projects
None yet
Development

No branches or pull requests

2 participants