mill icon indicating copy to clipboard operation
mill copied to clipboard

Add hello-world and todo-mvc Quarkus examples (1000USD bounty)

Open lihaoyi opened this issue 1 year ago • 18 comments


From the maintainer Li Haoyi: I'm putting a 1000USD bounty on this issue, payable by bank transfer on a merged PR implementing this.


Mill's example test suite has examples for hello-world and todo-mvc projects using in Java using Spring-Boot and Micronaut built using Mill (https://github.com/com-lihaoyi/mill/tree/main/example/javalib/web). They're not super fleshed out, but they exist.

We should add similar hello-world/todo-mvc examples for the Quarkus web framework, which according to the IntelliJ dev survey is relatively popular (between Spring-Boot and Micronaut https://www.jetbrains.com/lp/devecosystem-2023/java/)

lihaoyi avatar Sep 15 '24 08:09 lihaoyi

I'm giving a shot to this.

lolgab avatar Sep 16 '24 08:09 lolgab

quarkus, in its maven and gradle plugins, does some code generation which seems to be necessary to create the main method to run applications. I'm going to create a contrib module to mimic what we need from the Maven plugin. Another missing thing which would be nice to have, is support for pom artifacts to centralize the version management for a framework. In quarkus you add:

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>io.quarkus</groupId>
        <artifactId>quarkus-bom</artifactId>
        <version>${quarkus.platform.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

And then you can add dependencies without setting the version, which will be automatically derived from the pom in quarkus-bom. I think this could be a nice addition to mill (maybe we could have dependencies like ivy"groupid:artifactid" without version, and derive the version from the pom artifacts. But I'm not going to work on this in the scope of quarkus.

lolgab avatar Sep 17 '24 08:09 lolgab

The import-scope Maven dependencies are called BOM - Bill of Material. There are open requests for it in Mill and coursier:

  • https://github.com/com-lihaoyi/mill/issues/1975
  • https://github.com/coursier/coursier/issues/1390

I think @alexarchambault will work on it in the next months (https://github.com/com-lihaoyi/mill/discussions/3496).

lefou avatar Sep 17 '24 09:09 lefou

@lolgab Did you complete this? If not maybe I will give this a shot in 24 hours from now.

llvee avatar Sep 23 '24 00:09 llvee

I haven't completed it yet.

lolgab avatar Sep 23 '24 08:09 lolgab

@lolgab Would you like some help with it? Have you made a lot of progress?

llvee avatar Sep 23 '24 17:09 llvee

@lolgab Have you made any new progress on this?

llvee avatar Oct 14 '24 15:10 llvee

No, I haven't. Feel free to work on it 👍

lolgab avatar Oct 14 '24 15:10 lolgab

Bumping this up from 500 to 1000USD

lihaoyi avatar Dec 11 '24 07:12 lihaoyi

@lihaoyi Working on this (Have Read Docs and Seems it can be done)

himanshumahajan138 avatar Jan 15 '25 07:01 himanshumahajan138

quarkus, in its maven and gradle plugins, does some code generation which seems to be necessary to create the main method to run applications.

@lolgab could u please provide me some documentation or some link which will guide me for this

Actually i got some understanding but not properly able to understand what's going on internally please give some brief if possible

himanshumahajan138 avatar Feb 05 '25 17:02 himanshumahajan138

I haven't investigated a lot, but you need to reimplement for mill the maven plugin for quarkus

lolgab avatar Feb 05 '25 17:02 lolgab

@lolgab means we have to create proper plugin first of all then use that plugin as dependency in our examples

what u think we can use the already available codes in the link you gave

looks hard than it looks 😶

himanshumahajan138 avatar Feb 06 '25 04:02 himanshumahajan138

@lolgab what if we use the "quarkus cli" for creating and running the app

like user have to install the quarkus cli just like they install java or other required libs

himanshumahajan138 avatar Feb 06 '25 04:02 himanshumahajan138

It could work but it's very inefficient since the cli is a thin wrapper to the Maven plugin. So mill will call Maven under the hood which is not ideal. Yes, it's harder than it looks, but it's totally doable if you have the motivation. At first you can implement the plugin as part of the example build, extracting as a contrib module is easy afterwards.

lolgab avatar Feb 06 '25 07:02 lolgab

@lolgab I know i should not ask like this but i am motivated and have will to complete this so i need some help regarding this could u please provide me some outer guide like roadmap to reach to end point not only for bounty but in a sense to learn something professionally

TBH I can do this but don't know how to start and what reference to take as example to work on this

Hope U Understand !!!

himanshumahajan138 avatar Feb 06 '25 09:02 himanshumahajan138

@lihaoyi is this bounty this active?

JWLZGG avatar Jul 09 '25 19:07 JWLZGG

@lihaoyi can i work on this?

Lynndabel avatar Nov 14 '25 11:11 Lynndabel