kafka-ui icon indicating copy to clipboard operation
kafka-ui copied to clipboard

Request: a command to compile just `kafka-ui-api`, ignoring the frontend

Open ottaviohartman opened this issue 3 years ago • 8 comments

Is your proposal related to a problem?

I'd like to be able to iterate building the Java portion of kafka-ui without building the frontend.

I assumed this would work, but it runs npm:

cd kafka-ui-api
 ./mvnw compile -Pprod 

I was told to open this issue on Discord.

Describe the solution you'd like

cd kafka-ui-api
 ./mvnw compile -Pprod 

The above should compile just the backend.

ottaviohartman avatar Feb 22 '22 22:02 ottaviohartman

I can take this one. What about this solution? specifying "api-prod" as arg.

cd kafka-ui-api
 ./mvnw compile -Papi-prod 

Actually the ./mvnw compile -Pprod doesn't compile the "kafka-ui-contract" (or am I wrong?). So when compiling the "kafka-ui-api" if you dont compile the contract you can receive some erros (if the contracts were updated).

Maybe this is an another issue?

Corlobin avatar Mar 02 '22 14:03 Corlobin

Sure, thanks. Yeah, let's do something like this. It depends on the directory you run this command in.

Haarolean avatar Mar 02 '22 14:03 Haarolean

Since we don't have the wrapper as part of the modules what is the approach we want to follow regarding this request? Do we want to skip frontend build for ui-api and ui-contract?

By running something like this ./mvnw clean install -Pprod -DskipUIBuild=true

And changing this on both POM's:

configuration.skip.skipUIBuild

Original Request is based on this possibility but it is not anymore like this:

cd kafka-ui-api ./mvnw compile -Pprod

@Haarolean

MichaelGonzalezMurillo avatar Aug 09 '22 19:08 MichaelGonzalezMurillo

Since we don't have the wrapper as part of the modules what is the approach we want to follow regarding this request? Do we want to skip frontend build for ui-api and ui-contract?

By running something like this ./mvnw clean install -Pprod -DskipUIBuild=true

And changing this on both POM's:

configuration.skip.skipUIBuild

Original Request is based on this possibility but it is not anymore like this:

cd kafka-ui-api ./mvnw compile -Pprod

@Haarolean

what if we create a new profile with skipUIBuild property set to enabled by default?

Haarolean avatar Aug 10 '22 14:08 Haarolean

Since we don't have the wrapper as part of the modules what is the approach we want to follow regarding this request? Do we want to skip frontend build for ui-api and ui-contract? By running something like this ./mvnw clean install -Pprod -DskipUIBuild=true And changing this on both POM's: configuration.skip.skipUIBuild Original Request is based on this possibility but it is not anymore like this: cd kafka-ui-api ./mvnw compile -Pprod @Haarolean

what if we create a new profile with skipUIBuild property set to enabled by default?

That is what the closed PR was doing and was pushed back due to duplicated code.

MichaelGonzalezMurillo avatar Aug 10 '22 14:08 MichaelGonzalezMurillo

@Haarolean Lets not create unnecessary profiles. I suggested simple solution here https://github.com/provectus/kafka-ui/pull/1696#discussion_r830601917 . In should work like ./mvnw compile -DskipUiBuild=true.

iliax avatar Aug 10 '22 15:08 iliax

@Haarolean Lets not create unnecessary profiles. I suggested simple solution here #1696 (comment) . In should work like ./mvnw compile -DskipUiBuild=true.

Do we want it just for api or also for contract project?

MichaelGonzalezMurillo avatar Aug 10 '22 15:08 MichaelGonzalezMurillo

@Haarolean Lets not create unnecessary profiles. I suggested simple solution here #1696 (comment) . In should work like ./mvnw compile -DskipUiBuild=true.

https://github.com/provectus/kafka-ui/pull/2424 This is solution 2

MichaelGonzalezMurillo avatar Aug 10 '22 17:08 MichaelGonzalezMurillo