Skip to content
This repository was archived by the owner on Jan 10, 2024. It is now read-only.

Muhammed/sc 10025/wp graphql gql plugin needs to ensure it#1

Open
MuhammedAO wants to merge 3 commits into
mainfrom
muhammed/sc-10025/wp-graphql-gql-plugin-needs-to-ensure-it
Open

Muhammed/sc 10025/wp graphql gql plugin needs to ensure it#1
MuhammedAO wants to merge 3 commits into
mainfrom
muhammed/sc-10025/wp-graphql-gql-plugin-needs-to-ensure-it

Conversation

@MuhammedAO

Copy link
Copy Markdown
Collaborator

No description provided.

@shortcut-integration

Copy link
Copy Markdown

@MuhammedAO MuhammedAO requested a review from humet December 6, 2023 12:00
Comment thread composer.lock

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shouldn't be here.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay got it.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh wait @humet this is not the correct PR. remember you reached out to the developer who said this wasn't gonna work and that we should tackle on the wp-graphql side of things?

Dexerto/wp-graphql#1

Comment thread src/Cache/Results.php
if ( $this->are_all_nodes_null( $filtered_response ) ) {
header( 'Cache-Control: no-cache' );
header( 'Pragma: no-cache' );
update_option( 'are_all_nodes_null_flag', true );

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using a Wordpress Options database field isn't a good way to achieve this. The graphql API is potentially being hit thousands of times a minute and relying on one database value will lead to problems.

You need to just use some type of static variable so it's unique for this specific request scope.

@dorumrr Could you help out here please?

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@humet As per @MuhammedAO comment above, we're looking at the wrong PR. We should be looking at Dexerto/wp-graphql#1

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants