Kotor 2 module replace2/14/2023 ![]() ![]() The code snippet below shows the basic server setup with the Netty engine and the 8080 port. In this section, we'll take a look at several examples of running embeddedServer with different setting. The embeddedServer function accepts different parameters for configuring a server, including a server engine, a host and port to listen, and so on. Moreover, you can run your application from a command line and override the required server parameters by passing corresponding command-line arguments. This way provides more flexibility to configure a server and allows you to change a configuration without recompiling your application. The configuration depends on the way you used to create a server - embeddedServer or EngineMain:įor embeddedServer, you can configure server parameters in code by passing the required parameters to the embeddedServer constructor.įor EngineMain, Ktor loads its configuration from an external file that uses the HOCON format. Ktor allows you to configure various server parameters, such as a host address and port, modules to load, enable the development mode, and so on. ![]()
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |