Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

improve(core): vertices and edges loading optimization #288

Copy link
Copy link
@diaohancai

Description

@diaohancai
Issue body actions

Feature Description (功能描述)

ComputerOptions.INPUT_FILTER_CLASS default value is DefaultInputFilter.
org.apache.hugegraph.computer.core.input.filter.DefaultInputFilter

public class DefaultInputFilter implements InputFilter {

    @Override
    public Vertex filter(Vertex vertex) {
        vertex.properties().clear();
        return vertex;
    }

    @Override
    public Edge filter(Edge edge) {
        edge.properties().clear();
        return edge;
    }
}

Load all properties first, then clear.

Could we specify some properties when loading vertices or edges? May could improve performance.
Just like mysql:

select a, b, c

instead of

select *

org.apache.hugegraph.computer.core.input.hg.HugeVertexFetcher

    @Override
    public Iterator<Vertex> fetch(InputSplit split) {
        Shard shard = toShard(split);
        return this.client().traverser().iteratorVertices(shard,
                                                          this.pageSize());
    }

But it seems that the traverser api does not yet support specifying some properties to load vertices or edges on the server side.

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.