[BUG] GremlinServerError with Complex Query
- Dominant language
- C++
- Stars
- 3.6k
- Forks
- 468
- Avg merge
- 29m
- Merged PRs (30d)
- 1
Description
**Describe the bug**
The deadline was exceeded on the complex queries with more than 10M-scale results, while working well on queries with less than million-scale results.
**To Reproduce**
Steps to reproduce the behavior:
1. Download the LSQB dataset [sf3](https://repository.surfsara.nl/datasets/cwi/lsqb/files/lsqb-projected/social-network-sf3-projected-fk.tar.zst)
2. Download the LSQB loader `load_lsqb` which reused your ldbc loader via this [aliyundrive link](https://www.aliyundrive.com/s/Mjy1YawPHEV)
3. Run :
```python
import graphscope as gs
import pandas as pd
import os
import time
gs.set_option(vineyard_shared_mem="400G")
sess = gs.session(cluster_type='hosts')
from load_lsqb import load_lsqb
graph = load_lsqb(sess, prefix="/root/social-network-sf3-projected-fk/", directed=True) #modify prefix
print(graph.schema)
interactive = gs.gremlin(graph)
#modify the Q1.gremlin prefix
#Q1 has about 100M-scale results on sf3
'''
Q1.gremlin:
g.V().match(__.as('liker').out('likes').as('Message'),
__.as('Message').out('hasTag').as('Tag'),
__.as('Message').out('hasCreator').as('creator'),
__.as('Message').in('replyOf').as('Comment'))
'''
with open('/root/Q1.gremlin','r') as f:
gremlin_query = f.read()
print("start querying")
start = time.time()
result = interactive.execute(gremlin_query).all()
end = time.time()
print("count: ", result)
print("time: ", end-start)
sess.close()
```
**Expected behavior**
```shell
GremlinServerError: 500: Status{code=DEADLINE_EXCEEDED, description=deadline exceeded after 599.999663051s. [closed=[],
committed=[remote_addr=127.0.0.1/127.0.0.1:8234]], cause=null}
```
**Environment (please complete the following information):**
- GraphScope version: [ v0.22 ]
- OS: [ Linux ]
- Version [ ubuntu20.04 ]
**Additional context**
Everything works well on the queries with less than million-scale results like Q2.gremlin:
```
g.V().match(__.as('person1').both('knows').as('person2'),
__.as('person1').both('knows').as('person3'),
__.as('person2').both('knows').as('person3'),
__.as('person1').out('isLocatedIn').as('city1'),
__.as('city1').out('isPartOf').as('country'),
__.as('person2').out('isLocatedIn').as('city2'),
__.as('city2').out('isPartOf').as('country'),
__.as('person3').out('isLocatedIn').as('city3'),
__.as('city3').out('isPartOf').as('country')).count()
```
Contributor guide
Assessment
This issue has not been assessed yet.