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

3.7.2 broke "quarkus.minio.url" in devservices mode #323

Open
jendib opened this issue May 31, 2024 · 14 comments
Open

3.7.2 broke "quarkus.minio.url" in devservices mode #323

jendib opened this issue May 31, 2024 · 14 comments
Labels
bug Something isn't working documentation Improvements or additions to documentation

Comments

@jendib
Copy link

jendib commented May 31, 2024

Hi and thanks for this extension.
I'm relying on this code to get the current minio URL:

@ConfigProperty(name = "quarkus.minio.url")
String url;

but since 3.7.2 when Minio is started as a devservice (in unit tests) it's only filled by "localhost" instead of http://localhost:6878 (random port chosen by testcontainers).
I'm guessing it has to do with this recent change 204a8ae#diff-ac8ae1ef70059d67a0656e95d75eaeb3482ec3c7ec6a6284c1dd7b05bfe8badeR240

@jtama
Copy link
Member

jtama commented Jun 1, 2024

Oh I should have mention that change, could you please provider a sample of your usage ?

@jtama jtama added bug Something isn't working documentation Improvements or additions to documentation labels Jun 1, 2024
@jendib
Copy link
Author

jendib commented Jun 2, 2024

I just need to get the Minio URL, and because in a test context it's not a fixed value I don't know of any other way, is there?

@jtama
Copy link
Member

jtama commented Jun 3, 2024

Yes there is, you need to get the quarkus.minio.port injected as well. Please tell me of this works for you.

I will put up a PR to document this.

@jtama
Copy link
Member

jtama commented Jun 4, 2024

@jendib, does it work ?

@jtama jtama mentioned this issue Jun 7, 2024
@jtama jtama closed this as completed Jun 17, 2024
@jtama
Copy link
Member

jtama commented Jun 17, 2024

Closing as I don't have more inputs. Please feel free to re-open if needed.

@jendib
Copy link
Author

jendib commented Oct 23, 2024

Hello sorry I'm waking up on this finally :)

I did the migration, however I still have one problem:
The guide says that quarkus.minio.url must start with http:// or https:// however the Dev Services section says that this configuration property will be

The container host name. It isn’t an URL, it doesn’t contains the exposed port. It’s value will certainly be localhost

There is a contradiction, how can the dev services mode set quarkus.minio.url to something not starting with http:// when it's a requirement?

@jtama
Copy link
Member

jtama commented Oct 23, 2024

The code is the truth. I forgot to update the doc. host is certainly a better name now.

But documentation aside, could you achieve what you wanted ?

@jendib
Copy link
Author

jendib commented Oct 23, 2024

So you are saying that I can put quarkus.minio.url=myminio.example.com and it would work even if the documentation says otherwise? If yes that would be great. Currently I have a code specific for dev services which is of course not great.

@jtama
Copy link
Member

jtama commented Oct 23, 2024

This is exactly what I say. I'll test that tomorrow, and amend the doc and examples.

@jtama
Copy link
Member

jtama commented Oct 24, 2024

Yup I have to amend the doc and mixed usage in the tests, but actually, the devservice uses localhost as value for the quarkus.minio.url property.

@jtama jtama reopened this Oct 24, 2024
@jtama
Copy link
Member

jtama commented Oct 24, 2024

@jendib Can you confirm ?

@jtama
Copy link
Member

jtama commented Oct 24, 2024

@jendib Can you confirmed it works as expected with that clarification ?

@jendib
Copy link
Author

jendib commented Oct 25, 2024

@jtama It works perfectly, thanks a lot! It would be great indeed to rename quarkus.minio.url to quarkus.minio.host in the future.

@jtama
Copy link
Member

jtama commented Oct 25, 2024

I will, but I don't want to break other users... SO it will be a long process...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants