Code Monkey home page Code Monkey logo

vertx-awesome's People

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  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

vertx-awesome's Issues

Add vertx-maven-plugin

Related to Development Tools section, you can add Vert.x Maven Plugin. It provides great hot reload experience (actually, more of a hot redeploy/restart) on java code and resource changes.

Add failsafe.dev

It is much beyond my abilities to make a proper Pull Request to this repository :-(

I suggest you to add directly after [Resilience4j], its modern zero-dependency alternative "Failsafe" with a Vert.x integration example:

* [Failsafe](https://failsafe.dev/) - Failsafe is a lightweight, *zero-dependency* library for handling failures in Java 8+. Concise API. Integration with libraries that use their own schedulers for async executions, such as Akka or Vert.x. [Vert.x example](https://github.com/failsafe-lib/failsafe/blob/master/examples/src/main/java/dev/failsafe/examples/VertxExample.java)

OR as commit

Set repo description

I'm currently trying to improve this list to make it comply to the requirements from the awesome project. There is an open pull request containing some instructions:
sindresorhus/awesome#700

I will work on the points, but there is one that I cannot do myself. The repo doesn't have a description.

Can someone who has the right permissions please set a description? Something like the following would be appropriate:

 A curated list of Vert.x resources and projects

Or maybe

A curated list of awesome Vert.x resources, libraries, and other nice things.

You may also set the repo's URL to

https://github.com/vert-x3/vertx-awesome

Thanks!
Michel

How to unsecure the healthcheck endpoint after enabling the SSL property in the HTTP server options?

Greetings Everyone!

Use Case: We did the following SSL configuration as per the docs, however we need to disable this SSL check for a couple of routes (/healthcheck & /ping- make them non-secure) and have the SSL check only for 1 route (/seller). How do we accomplish this?

HTTP Server Options:

HttpServerOptions secureOptions = new HttpServerOptions();
     secureOptions.setSsl(true)
          .setPfxKeyCertOptions(new PfxOptions().setPath(sslKeystorePath)
              .setPassword(sslKeystorePassword))
          .setPfxTrustOptions(new PfxOptions().setPath(sslKeystorePath)
              .setPassword(sslKeystorePassword))
          .setClientAuth(ClientAuth.REQUIRED)
          .addEnabledSecureTransportProtocol(APIConstants.TLS_VERSION_2);

Registering Healthcheck routers:

private void registerHealthChecks(Router router) {
     HealthCheckHandler healthCheckHandler = 
         HealthCheckHandler
                          .createWithHealthChecks(HealthChecks.create(vertx));
         healthCheckHandler
                           .register("STATUS", 2000, future -> future.complete(Status.OK()));

      HealthCheckHandler pingHandler = HealthCheckHandler.create(vertx);
       pingHandler.register("DB_STATUS", future -> {
               final JDBCClient client = JDBCClient.createShared(vertx, new JsonObject()
                       .put("url", config().getValue("jdbc.url"))
                       .put("driver_class", config().getValue("jdbc.driver_class"))
                       .put("max_pool_size", config().getValue("jdbc.max_pool_size"))
                       .put("user", config().getValue("jdbc.user"))
                       .put("password", config().getValue("jdbc.password")));
               client.getConnection(conn -> {
                   if (conn.failed()) {
                       LOGGER.error(conn.cause().getMessage());
                       future.complete(Status.KO());
                   } else if (conn.succeeded()) {
                       LOGGER.info("DB Connection successful!!!");
                       future.complete(Status.OK());
                   }
               }).close();
           });
       // Healthcheck endpoint handler
       router.get(APIConstants.SA_HEALCHECK_ENDPOINT).handler(healthCheckHandler);
       LOGGER.info("Endpoint added to router " + APIConstants.SA_HEALCHECK_ENDPOINT);
       // Ping endpoint handler for database health check
       router.get(APIConstants.SA_PING_ENDPOINT).handler(pingHandler);
       LOGGER.info("Endpoint added to router " + APIConstants.SA_PING_ENDPOINT);
   }

Start Method Implementation:

@Override
   public void start(Future<Void> startFuture) throws Exception {
       Json.mapper.registerModule(new JavaTimeModule());
       FileSystem vertxFileSystem = vertx.fileSystem();

       // Read properties into config object and use it for further server configuration.
       this.configRetriever.configStream().handler(config -> {
           // read port from properties file.
           this.serverPort = config.getInteger("api.endpoint.port");

           //  Reading swagger.json and and register router here
           vertxFileSystem.readFile("swagger.json", readFile -> {
               HttpServer server = null;
               if (readFile.succeeded()) {
                   // Get Swagger file and create routes with api endpoints defined in the swagger.json
                   Swagger swagger = new SwaggerParser().parse(readFile.result().toString(Charset.forName("utf-8")));
                   Router swaggerRouter = SwaggerRouter.swaggerRouter(router, swagger, vertx.eventBus(), new OperationIdServiceIdResolver());

                   // Register /healthcheck and /ping endpoints here
                   registerHealthChecks(swaggerRouter);
                  
                   // Configure SSL certifications for https://
                   HttpServerOptions secureOptions = getSSLConfig(config);

                   // Initialize HttpServer with above SSL config
                   server = vertx.createHttpServer(secureOptions);

                   // deploy theSellerAPIVerticle
                   deployVerticles(startFuture, config);

                   // Start the server with all above the routes
                 if(server != null) {
                   server.requestHandler(swaggerRouter)
                       .listen(serverPort, h -> {
                         if (h.succeeded()) {
                           startFuture.complete();
                         } else {
                           startFuture.fail(h.cause());
                         }
                       });
                 } else {
                   LOGGER.warn("Server is not initialized properly!!");
                 }
               } else {
                   startFuture.fail(readFile.cause());
               }
           });
       });
   }

Kotlin Vert.x boilerplate

Hello!

I would like to know if it makes sense to publish a boilerplate for Vert.x in Kotlin here and if yes then under which section ๐Ÿค” The reason why I have done it is when I have been starting with Vert.x in Kotlin I was not able to find anything related to it (except of vertx-examples) and decided to write a small boilerplate by my own. So it might me helpful for beginners ๐Ÿ™‚ plus: I already use it successfully in two of my projects

Thanks. All the best ๐Ÿ™Œ

Add The White Rabbit

Related to Messaging section, there is The White Rabbit client for RabbitMQ written on Kotlin with coroutines usage. It's an alternative for default vertx-rabbitmq-client.
An example of integration with Vert.x can be found in the-white-rabbit-vertx-example folder.

functional prog

Is there helpers on how to use vertx with a functional programming style for (stateless) servers?

ORM is missing

I would have expected an ORM to make this list - an ORM for Postgres or whatever relational DB.

Perhaps vertx has an in-house ORM so there is no "userland" one?

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.