这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@tirumaraiselvan
Copy link
Contributor

Description

Event Trigger payload now contains a key "session_variables" which has all the "x-hasura-*" variables used in the context of the event.

What component does this PR affect?

  • Server
  • Console
  • CLI
  • Docs
  • Community Content
  • Build System

Requires changes from other components? If yes, please mark the components:

  • Server
  • Console
  • CLI
  • Docs
  • Community Content
  • Build System

Related Issue

#1328

Solution and Design

Use current_settings('hasura.user') in the postgres trigger to populate payload.

Type

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Docs update
  • Community content

Checklist:

  • I have read the contributing guide and my code conforms to the guidelines.
  • This change requires a change in the documentation.
  • I have updated the documentation accordingly.
  • I have added required tests.

@tirumaraiselvan tirumaraiselvan requested a review from 0x777 January 24, 2019 09:42
@tirumaraiselvan tirumaraiselvan force-pushed the event-payload-session-ctx branch from 62adf35 to c7f7481 Compare January 24, 2019 09:59
@hasura-bot
Copy link
Contributor

Review app for commit c7f7481 deployed to Heroku: https://hge-ci-pull-1458.herokuapp.com
Docker image for server: hasura/graphql-engine:pull1458-c7f7481

@hasura-bot
Copy link
Contributor

Review app for commit 9cbe0b7 deployed to Heroku: https://hge-ci-pull-1458.herokuapp.com
Docker image for server: hasura/graphql-engine:pull1458-9cbe0b7

@0x777
Copy link
Member

0x777 commented Jan 24, 2019

Do we want to call the field name session_variables or simply user? That's what I think the audit module calls it. @rikinsk @shahidhk @coco98

@rikinsk-zz
Copy link

We use session_variables to refer to the X-Hasura-* fields in the auth docs. Might as well keep the consistency.

@shahidhk shahidhk changed the title [Event Trigger] Send session variables in event trigger payload (close #1328) send session variables in event trigger payload (close #1328) Jan 26, 2019
@shahidhk
Copy link
Member

@0x777 @rikinsk This PR looks okay, shouldn't we then change the internal reference from current_setting('hasura.user') current_setting('hasura.session_variables')?

@hasura-bot
Copy link
Contributor

Review app for commit 7491ff6 deployed to Heroku: https://hge-ci-pull-1458.herokuapp.com
Docker image for server: hasura/graphql-engine:pull1458-7491ff6

@0x777 0x777 merged commit e590144 into hasura:master Jan 28, 2019
@hasura-bot
Copy link
Contributor

Review app https://hge-ci-pull-1458.herokuapp.com is deleted

hasura-bot pushed a commit that referenced this pull request Dec 19, 2024
…ng (#1458)

<!-- The PR description should answer 2 important questions: -->

### What
Resolve relationships targeting commands in the new opendd query
planner, thereby supporting command relationships in JSON:API.

### How
- Resolve command relationships in opendd query planning.
- Fix NDC response processing in JSON:API for command relationships by
considering the `__value` field.
- Add a test in json:api.
<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 586a5f24543b5696e6aefafe469d4ed3e8807ed3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants