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

GH-154: Replaced the lists with sets for the xpath computations. #155

Merged
merged 1 commit into from
Nov 20, 2018

Conversation

kittaakos
Copy link
Contributor

As a quick solution for a performance issue when resolving complex
long paths.

Closes: #154.

@kittaakos
Copy link
Contributor Author

@svenefftinge, can you please look into the changes? Thanks!

@@ -375,13 +375,13 @@ class XpathResolver {
}
return Types.nodeSet(nodes)
}
val result = newArrayList()
val result = newHashSet()
Copy link
Member

Choose a reason for hiding this comment

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

please use a linked hash set to preserve the order

@svenefftinge
Copy link
Member

@huyuwen were you able to test the change against your models?

As a quick solution for a performance issue when resolving complex
long paths.

Closes: #154.

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
@kittaakos
Copy link
Contributor Author

I have replaced the HashSet with a LinkedHashSet.

@huyuwen
Copy link
Contributor

huyuwen commented Nov 20, 2018 via email

@kittaakos
Copy link
Contributor Author

I am merging this now.

@kittaakos kittaakos merged commit 04c4a04 into master Nov 20, 2018
@kittaakos kittaakos deleted the GH-154 branch November 20, 2018 09:54
@huyuwen
Copy link
Contributor

huyuwen commented Nov 20, 2018

I just test locally with our own data. The solution works fine.
I will test yang-lsp again when I used the latest generated package later.

Really thanks.

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.

None yet

3 participants