Skip to content

Fix bug vertices with CUSTOMIZE_NUMBER id load error#6

Merged
zhoney merged 1 commit intomasterfrom
support-customize-number-id
Oct 29, 2018
Merged

Fix bug vertices with CUSTOMIZE_NUMBER id load error#6
zhoney merged 1 commit intomasterfrom
support-customize-number-id

Conversation

@Linary
Copy link
Contributor

@Linary Linary commented Oct 11, 2018

No description provided.

schema.indexLabel("personByName").onV("person").by("name").secondary().ifNotExist().create();
schema.indexLabel("personByAge").onV("person").by("age").range().ifNotExist().create();
schema.indexLabel("personByCity").onV("person").by("city").secondary().ifNotExist().create();
schema.indexLabel("personByAgeAndCity").onV("person").by("age", "city").secondary().ifNotExist().create(); No newline at end of file
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add a new line in the end

"id": "id"
}
]
} No newline at end of file
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto


private Long parseNumberId(Object idValue) {
if (idValue instanceof Number) {
return (Long) idValue;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it may be other number type eg. int or float, so use idValue.longValue()

}
}

private Long parseNumberId(Object idValue) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

static

Fix #5

Change-Id: I7cd495b3e27e128cd5c9d75d9ebd54fdbc5bca21
@Linary Linary force-pushed the support-customize-number-id branch from 153fae0 to 57e349e Compare October 11, 2018 08:30
@Linary
Copy link
Contributor Author

Linary commented Oct 11, 2018

done

@zhoney zhoney merged commit 3cacad6 into master Oct 29, 2018
@Linary Linary deleted the support-customize-number-id branch October 30, 2018 09:59
zhoney pushed a commit that referenced this pull request Oct 25, 2021
Co-authored-by: guoyonggang <guoyonggang@baidu.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants