We have deployed JSS App on Sitecore instance running on Azure.
For one of the component we are using GraphQL which is perfectly working on local machine.
But when we deploy it on Azure our GraphQL query was not returning anything.
Our query was
As you can note, we have used "fieldsEqual" parameter and pass the name and value. You will get this query result on your local machine but this is not going to work on Azure.
I think this is because we are using "Azure Search" and Azure have limitation of 1000 fields index. It may be possible that Azure search not indexed system fields.
So if you want to use Azure Search with GraphQL you should rewrite your query with "rootItem" parameter as
Other alternative is to use SOLR as a search on Azure. I find this link is very simple and handy to install SOLR on azure.
For one of the component we are using GraphQL which is perfectly working on local machine.
But when we deploy it on Azure our GraphQL query was not returning anything.
Our query was
var query = `{
search(fieldsEqual: [{name: "_fullpath",
value: "/sitecore/content/myjssproj/Content/BlogsCollection/ContentListField/*"}
])
As you can note, we have used "fieldsEqual" parameter and pass the name and value. You will get this query result on your local machine but this is not going to work on Azure.
I think this is because we are using "Azure Search" and Azure have limitation of 1000 fields index. It may be possible that Azure search not indexed system fields.
So if you want to use Azure Search with GraphQL you should rewrite your query with "rootItem" parameter as
var query = `{
search(rootItem: "/sitecore/content/myjssproj/Content/BlogsCollection/ContentListField/*"
)
Other alternative is to use SOLR as a search on Azure. I find this link is very simple and handy to install SOLR on azure.