Serwer aplikacyjny

An application server is a component-based product that resides in the middle-tier of a server centric architecture. It provides middleware services for security and state maintenance, along with data access and persistence.

WildFly

WildFly, formerly known as JBoss AS, or simply JBoss, is an application server authored by JBoss, now developed by Red Hat. WildFly is written in Java, and implements the Java Platform, Enterprise Edition (Java EE) specification. It runs on multiple platforms.

WildFly is free and open-source software, subject to the requirements of the GNU Lesser General Public License (LGPL), version 2.1.

On 20 November 2014, JBoss Application Server was renamed WildFly. The JBoss Community and other Red Hat JBoss products like JBoss Enterprise Application Platform were not renamed.

WildFly posiada dwa tryby instalacji:

  • Na maszynie - standardowy tryb
  • W pamięci - za pomocą pluginu Maven'owego

WildFly Maven Plugin

Plugin Maven'a pozwalający na wykonywanie takich czynności jak:

  • deployment / redeployment
  • wywoływanie komend
  • uruchomienie

W pliku pom.xml naszego projektu należy dodać w sekcji build następujący kod:

<build>
    <pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.wildfly.plugins</groupId>
                <artifactId>wildfly-maven-plugin</artifactId>
                <version>1.2.0.Final</version>
            </plugin>
        </plugins>
    </pluginManagement>
    <plugins>
        <plugin>
            <groupId>org.wildfly.plugins</groupId>
            <artifactId>wildfly-maven-plugin</artifactId>
            <version>1.2.0.Final</version>
        </plugin>
    </plugins>
</build>

Serwer uruchamiamy następująco w wierszu poleceń:

mvn wildfly:run

Od tego momentu nasz serwer dostępny jest pod adresem http://127.0.0.1:8080.

Zadanie

Do wygenerowanego projektu dodaj konfigurację serwera WildFly i uruchom go.

Źródła

results matching ""

    No results matching ""