Quick Start
# Overview
# Abstract
This quick start guide mainly introduces the Apusic Application Server V10 (AAS-V10) installation, configuration, etc. It provides the basic process of starting/stopping the server, deploying/uninstalling the application, configuring the data source, etc. It is suitable for developers who use AAS-V10 for development, system administrators in production environment, operation and maintenance personnel, etc.
# Introduction
Apusic Application Server provides a simple and fast development and operation platform for complex applications. For distributed enterprise level applications, it offers features such as easy scalability, high security, and so on.
On the basis of V9.0, V10 has added functions such as domain management, nodes, independent instances, and cluster management. The domain service manager manages nodes, instances, and clusters uniformly.
By default, there is a local instance server that can create remote nodes. Each node is equivalent to an AAS, and the instance runs on the node.
V10 supports unified management of resources, such as application resources, database resources, etc., which can be used for unified upgrade operations.
# Terminology
Apusic Application Server
A server is the physical deployment unit of an application server. Intuitively, this is a physical installation of the application server on a user machine.
Domain
A domain is a group of related server resources that are managed as a unit. A domain can contain one or more independent servers, as well as a cluster of servers that share a common set of configurations defined using Extensible Markup Language xml in a configuration file called domain.xml and stored in the DOMAIN_HOME/config/ directory. A domain is a complete management unit. When an application is deployed in the domain, the application can only be deployed on the servers in the domain. If a domain contains a cluster, all servers in the cluster must belong to the same domain.
Instance
A server instance is a single virtual machine on the Java platform (JVM) that runs on a single node of the server. Server instances form the basis of application deployment. Instances are important components in building clusters, load balancing, and server session persistence. Each instance belongs to only one domain and has its own directory structure, configuration, and deployed application. Each instance contains a reference to the node.
Node
Each node corresponds to a host running application server software. The host where the application server instance is installed must have a corresponding node. The node configuration information includes the machine name and the location of the application server on the host.
Cluster
A server cluster is a logical entity collection of multiple server instances that share the same application, resource, and configuration information. Regardless of whether the server instances are on the same host or different hosts, the application server can manage all instances in the cluster as a unit in the administrative control center.
# Default Administrative Value
| name | default value |
|---|---|
| domain name | mydomain |
| asadmin Command-line utilities | APUSIC_HOME/bin |
| config files | DOMAIN_HOME/config |
| logs files | DOMAIN_HOME/logs |
# Default Module Port
| functional module | port |
|---|---|
| Manager port | 6848 |
| HTTP port | 6888 |
| HTTP SSL port | 6887 |
| IIOP SSL port | 6838 |
| IIOP MUTUALAUTH port | 6839 |
| JMS port | 6876 |
| IIOP port | 6837 |
| JMX port | 6886 |
| OSGI SHELL port | 6866 |
| JAVA DEBUGGER port | 8000 |
# Quick Setup and Start/Stop
# Prepare before Installation
The Java Runtime Environment needs to be installed and set up on the server in advance. Since the remote access needs to enable security management, the jdk needs to be 1.8.0_201 or above version.
# License Authorization
AAS requires a corresponding license for normal use. Under normal circumstances, Apusic will match the corresponding license according to the product version purchased by the user.
The license location is ${APUSIC_HOME}/license.xml.

If the license expires or becomes invalid during usage, it is advisable to contact the relevant Apusic service personnel and initiate a re-application process for the corresponding license. When re-applying for the license, it is essential to furnish the product's authentication code to Apusic's support staff as depicted in the illustration:

If the node has an authorization problem, you can view the log. The log will print the corresponding auth code, send the code to the Apusic interconnection personnel to apply for the corresponding license again.
# Install
Windows: Directly unzip the installation package AAS-V10.0.zip.
Linux: Run the command unzip AAS-V10.0.zip to unzip the package and install it.
# Start The Default Domain
Execute asadmin start-domain in APUSIC_HOME/bin. If multiple domains exist, you need to enter the name of the domain, such as asadmin start-domain mydomain.
Note: You need to setup the default administrator password when you first startup.
# Stop The Defalut Domain
Execute asadmin stop-domain in APUSIC_HOME/bin. If multiple domains exist, you need to enter the name of the domain, such as asadmin stop-domain mydomain.
# Uninstall
1.Delete the installation directory:
This is done by deleting all files in the ${APUSIC_HOME}/ installation directory.
2.Execute the uninstall script:
For a graphical installation, execute the uninstall script to complete the installation.
Note: You need to stop running AAS before uninstalling.
# Manager
# Access
As an application with a user interface you use in your browser, go to https://ip:port:6848 once installed and started.

# Basic Roles
AAS V10.0 combines Cluster Management Console, Security Management Console and General Management Console. Default three roles and users: 1) System administrator (sysadmin): admin. Mainly responsible for user creation and management, daily system maintenance Settings, resources and cluster management. 2) security: secure. Mainly responsible for the daily security management of the system. 3) auditor: audit. Mainly responsible for audit tracking analysis and supervision and inspection of the operation behavior of system administrators and security administrators.
# Basic Function
Deploy and manage applications.
Create and manage data sources.
Server cluster unified configuration management, load balancer management, cache cluster management, load balancer cluster management.
User management, resource management, and general configuration management.
# Application Deployment and Access
# Application Deployment
1.Deploy by Manager: Specify the application deployment target, which can be deployed to multiple instances and clusters at the same time.





2.Command Deployment: asadmin deploy war-dir, you can specify the target war-dir as the application file path by --target.
3.Copy the application to the DOMAIN_HOME/autodeploy directory.
# Application Access
Once the application has been deployed, you can access it via a browser as follows:
1.click [Launch] in the Actions column of the application list;
2.In the pop-up page, select any URL in the [Links] column to access the application.
Note: 1) If the deployed file is a folder or ear file, there is no [Launch] button in the [Action], you need to manually enter the access address in the browser. 2) If the deployed application needs to interface with resources, you need to add resource information first, otherwise there will be errors when deploying or accessing the application.


# Application Undeployment
The system supports 3 ways to undeploy the application.
1.The command line method to undeploy the application: execute asadmin undeply war-name in the APUSIC_HOME/bin path.
2.Delete the application files and deployment flags in autodeploy, autodeploy.autodeploystatus and application directory.
3.Manager undeploy: can cancel an instance of application deployment or cancel the application deployment on all directories.

# DataSources
AAS-V10 data source follow the JDBC specification and support a variety of databases, including Oracle, MySQL, DB2, Derby, Sybase, SQL Server, PostgreSQL and other mainstream databases. Also support DM, Shentongdata, KingbaseES, GaussDB, AISWare AntDB and other domestic databases(Chinese). The JDBC connection pool function in AAS-V10 is used to create database connections, and the JDBC resource function config the JDBC connection pool into resources that can be called by applications. Here we take mysql database as an example to demonstrate the creation and management of data sources.
New JDBC connection pool: Supports database driver upload and replication functions.




New JDBC resource: Set the JNDI name of the JDBC resource and bind to a JDBC connection pool.


# Main Parameter Configuration
AAS-V10 Manager provides unified configuration of common parameters, such as JVM parameters, thread pool settings, JDBC connection pool settings, http connection pool settings, log related parameters and other settings. You can do unified configuration for clusters, service instances, etc. The configuration path is: [Configuration] -> [server-config] (or cluster name).
