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

listRemoteFolderItems can be accessed in multiple ways #337

Open
dodie opened this issue Jan 6, 2022 · 0 comments
Open

listRemoteFolderItems can be accessed in multiple ways #337

dodie opened this issue Jan 6, 2022 · 0 comments
Labels
question Further information is requested

Comments

@dodie
Copy link
Contributor

dodie commented Jan 6, 2022

In the Java API there are two ways to get or set a remote repository's listRemoteFolderItems property, one via the RemoteRepository class, and one via the RepositorySettings class. E.g.:

RemoteRepository repo = /* ... a generic remote repository ...*/;

repo.isListRemoteFolderItems(); // 1
((GenericRepositorySettings)repo.getRepositorySettings()).getListRemoteFolderItems(); // 2

When I check the REST API of Artifactory, there's only a single related property, so it's a bit confusing to have two ways of accessing it.

More importantly, it seems that the two properties work a differently:

  • When I read a remote repository from Artifactory, both properties are set according to the value on the server.
  • When I write the repository, it ignores the property on the RemoteRepository object and uses the value defined for the RepositorySettings object.

Which of these properties should be used? Is it ok in all cases to just use the property in the RepositorySettings object and simply ignore the property on the RemoteRepository?

If so, would it be possible to change artifactory-client-java and remove the unnecessary one?

@dodie dodie added the question Further information is requested label Jan 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant