-
Notifications
You must be signed in to change notification settings - Fork 528
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
feat(server): support MemoryManagement for graph query framework #2649
Changes from 49 commits
7a652be
ccc918b
b266358
ff10c3a
26b0cfe
f6aeace
72e5bf3
48f4817
d906d04
b308be0
09367a1
ea9a459
f552fd2
8a2c65c
c37f869
5904909
0e70e44
5d71541
f73f0ab
871015e
8344443
d9cf408
aaeacb5
ef0d629
54d1fd8
bfe75c0
ab1bcde
91df57a
52ca7af
ee8e125
1a7d461
de9d7a1
46066eb
4f1e966
7be5069
231b647
865f1fb
f34e233
879390b
a96e9ee
7c86e84
5af2cb9
5e47bb0
b77346b
d00a8df
fecc909
31f1feb
d4035bd
d87388b
d25396d
b334c61
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -119,15 +119,15 @@ public static IdType idType(Id id) { | |
return IdType.UNKNOWN; | ||
} | ||
|
||
private static int compareType(Id id1, Id id2) { | ||
public static int compareType(Id id1, Id id2) { | ||
return idType(id1).ordinal() - idType(id2).ordinal(); | ||
} | ||
|
||
/****************************** id defines ******************************/ | ||
|
||
public static final class StringId implements Id { | ||
public static class StringId implements Id { | ||
|
||
private final String id; | ||
protected String id; | ||
|
||
public StringId(String id) { | ||
E.checkArgument(!id.isEmpty(), "The id can't be empty"); | ||
|
@@ -196,11 +196,11 @@ public String toString() { | |
} | ||
} | ||
|
||
public static final class LongId extends Number implements Id { | ||
public static class LongId extends Number implements Id { | ||
|
||
private static final long serialVersionUID = -7732461469037400190L; | ||
|
||
private final long id; | ||
protected Long id; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can we keep primitive type There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
|
||
public LongId(long id) { | ||
this.id = id; | ||
|
@@ -270,7 +270,7 @@ public String toString() { | |
|
||
@Override | ||
public int intValue() { | ||
return (int) this.id; | ||
return this.id.intValue(); | ||
} | ||
|
||
@Override | ||
|
@@ -289,9 +289,9 @@ public double doubleValue() { | |
} | ||
} | ||
|
||
public static final class UuidId implements Id { | ||
public static class UuidId implements Id { | ||
|
||
private final UUID uuid; | ||
protected UUID uuid; | ||
|
||
public UuidId(String string) { | ||
this(StringEncoding.uuid(string)); | ||
|
@@ -379,9 +379,9 @@ public String toString() { | |
/** | ||
* This class is just used by backend store for wrapper object as Id | ||
*/ | ||
public static final class ObjectId implements Id { | ||
public static class ObjectId implements Id { | ||
|
||
private final Object object; | ||
protected Object object; | ||
|
||
public ObjectId(Object object) { | ||
E.checkNotNull(object, "object"); | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -208,10 +208,10 @@ public int hashCode() { | |
return this.id().hashCode() ^ this.columns.size(); | ||
} | ||
|
||
public static final class BinaryId implements Id { | ||
public static class BinaryId implements Id { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. seems don't need to transform BinaryId, it's just short-term used during serialization. you cam double check There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ok |
||
|
||
private final byte[] bytes; | ||
private final Id id; | ||
protected byte[] bytes; | ||
protected Id id; | ||
|
||
public BinaryId(byte[] bytes, Id id) { | ||
this.bytes = bytes; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why change this file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe influenced by
Fury
dependencies🤔?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, and I ran wrong
regenerate_known_dependencies.sh
which is in hugegraph-dist/scripts/dependency, resulting in a duplicateknown-dependencies.txt
under hugegraph-dist/scripts/dependency.Actually, only
regenerate_known_dependencies.sh
in /install-dist/scripts/dependency is enough and correct.regenerate_known_dependencies.sh
in hugegraph-dist/scripts/dependency seems useless and may cause misunderstanding for programmers.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@imbajin maybe could entirely remove
hugegraph-commons/hugegraph-dist
?