1
0
mirror of https://github.com/Rogiel/l2jserver2 synced 2025-12-06 07:32:46 +00:00

Implements XML based service descriptor allowing to switch services

This commit is contained in:
2011-12-28 00:35:35 -02:00
parent 228f481e86
commit 976cfaf4e0
53 changed files with 1270 additions and 1171 deletions

View File

@@ -1,92 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="configuration configuration.xsd"
xsi:noNamespaceSchemaLocation="configuration">
<!-- TODO -->
<general>
<!-- TODO -->
<rates>
<!-- TODO -->
<experience>1.0</experience>
<!-- TODO -->
<sp>1.0</sp>
</rates>
</general>
<!-- Services configuration section -->
<services>
<!-- Parameters in this section are used by DatabaseService. If you are
not sure on the usage of any parameter, read the "Configuration" section
in wiki article about DatabaseService. -->
<database>
<!-- Whether or not the service should try to update and create missing
tables at startup. This should be disabled after the first server start as
it could cause data corruption. -->
<automaticSchemaUpdate>true</automaticSchemaUpdate>
<!-- Configures OrientDB engine - plug-and-play -->
<orientdb>
<!-- The OrientDB storage location -->
<url>local:data/database</url>
<!-- The OrientDB username (local storage must use "admin") -->
<username>admin</username>
<!-- The OrientDB password (local storage must use "admin") -->
<password>admin</password>
</orientdb>
<!-- Configures JDBC engine - requires database server configuration -->
<jdbc>
<!-- Defines the connection URL used by JDBC to connect to the database. -->
<url>jdbc:mysql://localhost/l2jserver2</url>
<!-- The engine used to connect to the database. -->
<engine>com.l2jserver.service.database.sql.MySQLDatabaseEngine
</engine>
<!-- The username used to login into the database. NOTE: Try not use
"root" in production servers for security reasons. -->
<username>l2j</username>
<!-- The password used to login into the database. -->
<password>changeme</password>
</jdbc>
<connections>
<!-- The maximum number of active connections -->
<active-maximum>20</active-maximum>
<!-- The maximum number of idle connections -->
<idle-maximum>20</idle-maximum>
<!-- The minimum number of idle connections -->
<idle-minimum>5</idle-minimum>
</connections>
</database>
<!-- Parameters in this section are used by NetworkService. If you are
not sure on the usage of any parameter, read the "Configuration" section
in wiki article about NetworkService. -->
<network>
<!-- The address and port in which the server will listen to -->
<listen>0.0.0.0:7777</listen>
</network>
<!-- Parameters in this section are used by VFSService. If you are not
sure on the usage of any parameter, read the "Configuration" section in wiki
article about VFSService. -->
<vfs>
<!-- The root of the filesystem -->
<root></root>
<!-- The data folder. Relative to the root. Can be a ZIP file. -->
<data>data.zip</data>
</vfs>
<!-- Parameters in this section are used by VFSService. If you are not
sure on the usage of any parameter, read the "Configuration" section in wiki
article about VFSService. -->
<template>
<!-- The directory in which templates are stored. Relative to "vfs.data" -->
<directory>template/</directory>
</template>
</services>
<!-- /Services configuration section -->
</configuration>

View File

@@ -0,0 +1,114 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<services xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<!-- DAO Module configuration -->
<dao module="com.l2jserver.service.database.JDBCDAOModule" />
<!-- OrientDB database service -->
<service interface="com.l2jserver.service.database.DatabaseService"
implementation="com.l2jserver.service.database.GameServerOrientDatabaseService">
<!-- Whether the database schema should be updated at startup -->
<!-- Slows down a bit at start time, but guarantees consistency -->
<!-- Recommended to only be enabled after an server update -->
<schema automaticUpdate="true" />
<!-- The connection URL defines where the database data is stored -->
<connection url="local:data/database">
<!-- Database authentication. Should not be touched unless you know what
you are doing! -->
<authentication username="admin" password="admin" />
</connection>
</service>
<!-- Virtual file system service -->
<service interface="com.l2jserver.service.core.vfs.VFSService"
implementation="com.l2jserver.service.core.vfs.TrueZipVFSService">
<!-- Configures the root of the server data. Where all the files are placed. -->
<fileSystem root="./">
<!-- The "data file system" location. There, templates, static data and
several other important files are located. This can be a zip or a directory. -->
<!-- The "data file system" is relative to the file system root. -->
<data root="data.zip" />
</fileSystem>
</service>
<!-- Template service configuration -->
<service interface="com.l2jserver.service.game.template.TemplateService"
implementation="com.l2jserver.service.game.template.XMLTemplateService">
<!-- The root where template data is located. Relative to the "data file
system" -->
<templates root="template/" />
</service>
<!-- Network service -->
<service interface="com.l2jserver.service.network.NetworkService"
implementation="com.l2jserver.service.network.NettyNetworkService">
<!-- The port in which the server should listen for incoming connections -->
<!-- NOTE: this port must be open manually on any firewall or router that
is between you and other players. If you wish to play on the same machine
you normally don't need to change anything here nor in the firewall. -->
<server listen="0.0.0.0:7777" />
</service>
<!-- ###################################################################### -->
<!-- ########################### CORE SERVICES ############################ -->
<!-- ###################################################################### -->
<!-- Those services provide basic core features and are required for server
startup process -->
<service interface="com.l2jserver.service.core.LoggingService"
implementation="com.l2jserver.service.core.Log4JLoggingService" />
<service interface="com.l2jserver.service.core.threading.ThreadService"
implementation="com.l2jserver.service.core.threading.ThreadServiceImpl" />
<service interface="com.l2jserver.service.configuration.ConfigurationService"
implementation="com.l2jserver.service.configuration.XMLConfigurationService" />
<service interface="com.l2jserver.service.cache.CacheService"
implementation="com.l2jserver.service.cache.SoftCacheService" />
<!-- ###################################################################### -->
<!-- ########################### GAME SERVICES ############################ -->
<!-- ###################################################################### -->
<!-- Those services provide all the in-game features and most of them are
required for players to be able to login in the server -->
<service interface="com.l2jserver.service.game.world.WorldIDService"
implementation="com.l2jserver.service.game.world.CachedWorldIDService" />
<service interface="com.l2jserver.service.game.map.pathing.PathingService"
implementation="com.l2jserver.service.game.map.pathing.MapperPathingService" />
<service interface="com.l2jserver.service.game.scripting.ScriptingService"
implementation="com.l2jserver.service.game.scripting.ScriptingServiceImpl" />
<service interface="com.l2jserver.service.game.chat.ChatService"
implementation="com.l2jserver.service.game.chat.SimpleChatService" />
<service interface="com.l2jserver.service.game.chat.ChatLoggingService"
implementation="com.l2jserver.service.game.chat.DatabaseChatLoggingService" />
<service interface="com.l2jserver.service.game.admin.AdministratorService"
implementation="com.l2jserver.service.game.admin.AdministratorServiceImpl" />
<service interface="com.l2jserver.service.game.spawn.SpawnService"
implementation="com.l2jserver.service.game.spawn.SpawnServiceImpl" />
<service interface="com.l2jserver.service.game.character.CharacterService"
implementation="com.l2jserver.service.game.character.CharacterServiceImpl" />
<service interface="com.l2jserver.service.game.character.ShortcutService"
implementation="com.l2jserver.service.game.character.ShortcutServiceImpl" />
<service interface="com.l2jserver.service.game.AttackService"
implementation="com.l2jserver.service.game.AttackServiceImpl" />
<service interface="com.l2jserver.service.game.npc.NPCService"
implementation="com.l2jserver.service.game.npc.NPCServiceImpl" />
<service interface="com.l2jserver.service.game.item.ItemService"
implementation="com.l2jserver.service.game.item.ItemServiceImpl" />
<service interface="com.l2jserver.service.game.world.WorldService"
implementation="com.l2jserver.service.game.world.WorldServiceImpl" />
<service interface="com.l2jserver.service.game.world.event.WorldEventDispatcher"
implementation="com.l2jserver.service.game.world.event.WorldEventDispatcherImpl" />
<!-- ####################################################################### -->
<!-- ########################## NETWORK SERVICES ########################### -->
<!-- ####################################################################### -->
<!-- Those services all network related services that will communicate the
server software to the player computer running the game client. Although
not required, without them, becomes impossible to connect to the server in
order to play the game. -->
<service interface="com.l2jserver.service.network.keygen.BlowfishKeygenService"
implementation="com.l2jserver.service.network.keygen.SecureBlowfishKeygenService" />
<service interface="com.l2jserver.service.network.gameguard.GameGuardService"
implementation="com.l2jserver.service.network.gameguard.GameGuardServiceImpl" />
<service interface="com.l2jserver.service.network.broadcast.BroadcastService"
implementation="com.l2jserver.service.network.broadcast.BroadcastServiceImpl" />
</services>