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

[Question] Failed to handle cache event #1939

Closed
1 task done
simon824 opened this issue Aug 4, 2022 · 2 comments · Fixed by #1941
Closed
1 task done

[Question] Failed to handle cache event #1939

simon824 opened this issue Aug 4, 2022 · 2 comments · Fixed by #1941
Labels
bug Something isn't working

Comments

@simon824
Copy link
Member

simon824 commented Aug 4, 2022

Problem Type (问题类型)

No response

Before submit

  • 我已经确认现有的 IssuesFAQ 中没有相同 / 重复问题

Environment (环境信息)

  • Server Version: v0.12.0
  • Backend: hbase
  • OS: xx CPUs, xx G RAM, Centos 7.x

Your Question (问题描述)

When I import data with spark-loader, the data can be written successfully, but a lot of WARN logs appear on the server side, I have no idea what is causing this

2022-08-04 11:43:59 [event-worker-1] [WARN] c.b.h.e.EventHub - Failed to handle event: Event{name='cache', args=[cleared, EDGE, null]}
java.lang.IllegalArgumentException: The args count of event 'cache' should be 2(actual 3)
        at com.google.common.base.Preconditions.checkArgument(Preconditions.java:163) ~[guava-25.1-jre.jar:?]
        at com.baidu.hugegraph.util.E.checkArgument(E.java:56) ~[hugegraph-common-2.1.2.jar:2.1.2.0]
        at com.baidu.hugegraph.event.Event.checkArgs(Event.java:53) ~[hugegraph-common-2.1.2.jar:2.1.2.0]
        at com.baidu.hugegraph.StandardHugeGraph$AbstractCacheNotifier.lambda$new$0(StandardHugeGraph.java:1517) ~[hugegraph-core-0.13.0.jar:0.13.0.0]
        at com.baidu.hugegraph.event.EventHub.lambda$notify$0(EventHub.java:160) ~[hugegraph-common-2.1.2.jar:2.1.2.0]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_281]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:1.8.0_281]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:1.8.0_281]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_281]

Vertex/Edge example (问题点 / 边数据举例)

No response

Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)

No response

@javeme
Copy link
Contributor

javeme commented Aug 10, 2022

Looks like this is a bug.

we can update AbstractCacheNotifier:

event.checkArgs(String.class, HugeType.class);
=>
event.checkArgs(String.class, HugeType.class, Object.class);

or it's better to update all places where ACTION_CLEARED is used:

this.notifyChanges(Cache.ACTION_CLEARED, HugeType.EDGE, null);
=>
this.notifyChanges(Cache.ACTION_CLEARED, HugeType.EDGE);

@javeme javeme added the bug Something isn't working label Aug 10, 2022
@simon824
Copy link
Member Author

Looks like this is a bug.

we can update AbstractCacheNotifier:

event.checkArgs(String.class, HugeType.class);
=>
event.checkArgs(String.class, HugeType.class, Object.class);

or it's better to update all places where ACTION_CLEARED is used:

this.notifyChanges(Cache.ACTION_CLEARED, HugeType.EDGE, null);
=>
this.notifyChanges(Cache.ACTION_CLEARED, HugeType.EDGE);

Got it, thanks. I will fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants