Giter VIP home page Giter VIP logo

code.quarkus.io's Introduction

Code Quarkus App

Tests Version

The structure of this Web app is a bit special as it is possible to extend and customize it. It is what we could call a Fullstack React library thanks to the power of the Quarkus Web Bundler. It also contains our community implementation for code.quarkus.io.

πŸ“ ./web-deps contains all the web dependencies for the library, it is split in its own module to allow the library to be used in other Quarkus apps.

πŸ“ ./base is the base library, it contains the Api and the Code Quarkus React library, it also contains the Community App for dev purposes (you can remove it if you provide your own).

πŸ“ ./community-app is the community-app Quarkus app, it uses the base library without doing much as it directly use the Community App inside it.

πŸ“ ./acceptance-test are the test which run to auto promote new versions to production

https://github.com/redhat-developer/code.quarkus.redhat.com is an example of how this can be extended and customized.

Development

Api is located in base/src/main/java UI is located in base/src/main/resources/web/

Use this command to start community-app dev mode on: http://0.0.0.0:8080 (Api and UI).

# Install the parent pom and web-deps
./mvnw clean install -N;./mvnw clean install -f web-deps

# Start the dev mode
./mvnw quarkus:dev -f base

Build the app locally:

mvn clean install -Dlib -Dcommunity-app

After building, use this command to start the community-app in production mode:

java -jar community-app/target/quarkus-app/quarkus-run.jar

Staging

Staging is auto-updated with main (it takes ~15min to refresh after a merge): https://stage.code.quarkus.io

You can check deployed commit hash on: https://stage.code.quarkus.io/api/config

Promote to production

It is automated based on the acceptance tests

API Documentation

code.quarkus.io's People

Contributors

actions-user avatar aguibert avatar aloubyansky avatar cescoffier avatar dependabot[bot] avatar dmlloyd avatar edewit avatar emmanuelbernard avatar evanchooly avatar gastaldi avatar geoand avatar glefloch avatar gsmet avatar ia3andy avatar insectengine avatar jmtd avatar machi1990 avatar maxandersen avatar nderwin avatar netodevel avatar nikolassv avatar phillip-kruger avatar ppalaga avatar rsvoboda avatar rubenskj avatar sr-lut3t1um avatar stuartwdouglas avatar tacsio avatar xstefank avatar yrodiere avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

code.quarkus.io's Issues

Generate required datasource properties automatically

Some extensions require properties be set in order to operate properly. This is true for JPA/JDBC.

For H2, identified by the inclusion of the quarkus-jdbc-h2 extension, the following properties should be automatically generated in the application.properties file. These can be hard-coded or even as a pre-filled-in property list on the UI that a user can override (much like the GAVs are already):

%dev.quarkus.datasource.url=jdbc:h2:mem:test
%dev.quarkus.datasource.driver=org.h2.Driver
%dev.quarkus.hibernate-orm.database.generation=drop-and-create
%dev.quarkus.hibernate-orm.log-sql=true

For PostgreSQL, identified by the inclusion of the quarkus-jdbc-postgres extension, the following properties should be automatically generated in the application.properties file:

# Please provide hostname, port, database name, username, and password
%dev.quarkus.datasource.driver: org.postgresql.Driver
%dev.quarkus.datasource.url: jdbc:postgresql://<hostname>:<port>/<database>
%dev.quarkus.datasource.username: <username>
%dev.quarkus.datasource.password: <password>
# Uncomment the following line to generate the database schema
#%dev.quarkus.hibernate-orm.database.generation=drop-and-create
%dev.quarkus.hibernate-orm.log-sql=true

Note, this feature could potentially be added to the quarkus:add-extension goal as this property-generation feature could be cross-cutting feature across extensions. Where/how this is implemented is a discussion left for engineering.

Bottom extensions pane can scroll up to blank

Somehow I accidentally scrolled the bottom "extensions" pane to where the entire pane was black. At first I thought there was something wrong (the mac scrollbar disappears when not being used). It would be nice to either disable being able to scroll all contents off the pane or to have some visual cue that the content has scrolled off.

Inform the user about managing extensions after bootstrap

The project bootstrap allows to add any extension and shows the related maven command.

However, one may wonder how they can edit their choice later / remove extensions, especially when adding extensions goes through an opaque mvn command rather than simple pom edition (even if in the end it's just pom edition, it's still opaque).

So, is there an equivalent command such as ./mvnw quarkus:remove-extension -Dextensions="..." ? ; if so, maybe it should be noted somewhere on the bootstrap page?

Generate Project host-aware Hot-Key

The "Generate Project" hot key seems hard-coded to ALT RETURN. The Mac does not have an ALT key :-) The hot-key sequence needs to take into account the host operating system and adjust accordingly. On the Mac, it should be COMMAND RETURN. Currently, it maps to OPTION RETURN.

Setup CI

  • setup circle ci to build the docker image
  • setup circle ci to run backend and frontend tests on PRs
  • add PR and review checks

Support for older Quarkus versions

Unless I am not mistaken, it seems like we can only create projects with the latest version of Quarkus. It would be nice if there was an option to decide which Quarkus version to make a project with. If a specific Quarkus version is selected, the extensions list would also show extensions that are available for that specific Quarkus version.

It would be fantastic if a "version" query parameter could be added to the quarkus/extensions and quarkus/download endpoints to facilitate this feature. That would be extremely helpful in our particular use case.

Migrate the Quarkus launcher here

Directly plug the application generation in the endpoint.

The Launcher creator library adds too much complexity for no immediate gain, and it generates some unnecessary extra files (deployment.json). It may become usefull again at some point.

generated mvnw file is not executable

 gsmet ξ‚° tmp ξ‚± quarkus-app ξ‚° $ ξ‚° ./mvnw clean package
bash: ./mvnw: Permission denied

We need to use another zip library that support permissions.

Restrict the remove link to the trash bin

Right now, the right part behaves like this:

  • if you pass over the name of a selected extension, you have a tooltip with the description and if you click, you remove it
  • if you pass over the trash bin, you don't have any tooltip and if you click, you remove it

I would lean towards the following behavior:

  • over the name of the selected extension: help cursor + description in tooltip, no action on click (or only display the tooltip when clicking)
  • over the trash bin, standard action cursor, tooltip stating it will remove the extension, removing on click

Add the option to automatically create a GitHub repository with the application content

Let's discuss how to make this xp as painless as possible for the user.

We have this feature in the Launcher and all the authorization dance is a bit heavy. Let's try to find ideas on another approach to deal with this?

BTW it may be nice to provide an external service whose job is to import zip as a new repository in any git provider (github, bitbucket, gitlab...), I guess many people might like such a service. Any web-app just send the user to this page with a link to the zip ( git-import.io/?zip=http://...my-app.zip), the user is then directed toward configuring the import..

Provide external access to extensions.json

For third party tools (ex Project Initializer) that will be based only on the API and not the front end, it would be fine if we can get access to the extensions list (extensions.json) through a REST endpoint.

Improve search algo

  • full shortname match should not hide the other matches (maybe it could make the full match more obvious thought)
  • label based hit should use startWith (instead of full match)

Show module dependencies in the "Selected Extensions" area

The modules depend on each other so it would be nice that if I select a module all its module dependencies are visible in the "Selected Extensions" area and possibly also in the modules area.

For example, if you select "SmallRye Fault Tolerance" your project will automatically depend on ArC, SmallRye Metrics and SmallRye Context Propagation. No need to add them manually.

Display transitive extensions

When you select an extension, it may depend on other extensions. It could be nice to display them in another colour.

This can wait until after the first release.

Issues with code generation on Windows

Initially found by @stuartwdouglas:

  • The zip does not unpack correctly on windows, instead of src/main/java/org/example/ClassFile.java you get src/main/java/_/org/example/_/ClassFile.java
  • ${path} is not replaced with an actual value, so the generated application does not work

I am creating this issue in the launcher to keep track of the problem, but I guess it should be treated in https://github.com/quarkusio/quarkus since the project is generated using CreateProject: https://github.com/fabric8-launcher/launcher-quarkus/blob/master/src/main/kotlin/io/launcher/quarkus/LauncherQuarkus.kt#L45

Keyboard navigation

It could be useful to support keyboard selection.

If you start typing "hiber" you get four results. Then if you press DOWN you get a cursor over the first result. You can move between results with UP/DOWN. Pressing ENTER over a result will select it. Pressing ESC will clear the search field. Note that you can still keep on typing to narrow the results, so the focus should not leave the text field.

If you start typing "hiber" you get four results. Then if you press ENTER you select all four.

This can wait until after the first release.

Projects should be generated in a folder

When unzipping a project, the contents are extracted into the current directory. Example:

$ unzip -t my-app.zip
Archive:  my-app.zip
    testing: src/main/java/           OK
    testing: src/test/java/           OK
    ...

Project content should be extracted into a folder based on the project name:

$ unzip -t my-app.zip
Archive:  my-app.zip
    testing: my-app/src/main/java/           OK
    testing: my-app/src/test/java/           OK
    ...

Add gradle support

Once @aloubyansky and team are done with the next iteration of Gradle improvements, in particular the ability to add and list extensions.
We should add gradle support for the launcher.

At this stage, we will need to decide:

  • how "gradle create" will be done (via a command too or from a separate lib generating this shell)
  • whether the mvnw and gradlew should be created by a shared library instead of int he launcher itself.

Empty directory levels in zipped archive

The created Zip archive contains additional directory levels, e.g. /src/main/java//org/example//QuarkusApp.java, or /src/test/java//org/example//QuarkusAppTest.java.

When the file is unzipped, the directory structures appear to be created correctly. Browsing the archive with an archive manage lookes like we have emtpy directories

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.