Jump to: navigation, search

The DreamServer Process handles messages from the DreamManager clients. This includes queries for browsing the information and change storage and broadcast to connected clients. HSL also has an interface to create new tasks by sending a message to this server.

A unique aspect of this server is that it can be configured to communicate to any number of Worlds. The idea is to use the same DreamServer for all of the worlds that have the same content, so the task, team, and user information is shared.

To view or modify the DreamServer's process, use the Master Control Console. There is generally only one DreamServer process per game.


Building the Dream Server

Non-source code licensees

As a non-source code licensee, this executable will be provided.

Source code licensees

For source code licensees, this executable is built by the HJServers solution in $/hjservers/ where "$" represents the root of the branch.

Deploying the Dream Server

Unless you are upgrading a pre-1.19 installation of HeroEngine, skip this step.

There are two steps to prepare for a deploy of the new servers.

The first is to edit the WISE install script. The script to be edited is probably HJServersHE2.wse. There are 2 registry keys that may not be present. The fireup daemon requires these registry keys to locate the server executables it can start up. There will be a section in the install script that edits registry keys. That line can be copied, and pasted into a notepad window. Search the text for the registry keys listed below. If they are not there, they can be added just before the end. Make sure to also edit the total keys line to be 2 larger than it was previously. After making these edits, select the entire contents of the notepad, and copy and paste that back into the install script. The install script should now have a new line of text that indicates it should edit 26 total registry keys. The previous line that only edited 24 registry keys can be removed.

----Beginning of notepad buffer----
item: Edit Registry
 Total Keys=26                                   <---- I changed this from 24 to 26
---- These two keys could be missing, and can be added just before the last end in the notepad buffer----
  item: Key
    New Value=DreamServer.exe
    Value Name=Executable_name
  item: Key
    New Value=%MAINDIR%\
    Value Name=Executable_path

The second step is to reconfigure the Deploy Server so that it will deploy the new files. Open up the Deploy Server Client, and edit the deploy configuration for the server deploy corresponding to the WISE file that was edited. Select the FILES configuration value and edit the values, making sure they include the following files:

DreamServer.pdb -o

Then, edit the REVERSION_EXES configuration to include the new server executable, DreamServer.exe.

Configuring a World to Use the Dream Server

These instructions apply to HeroEngine version 1.19 and above.

There are 2 situations here. You can either setup a new independent DreamServer (and associated database) or configure an existing DreamServer to service additional worlds.

Basic instructions on setting configurations can be seen in the section on Master Control. See also Adding a World.

A New Independent DreamServer

The database schema will need to be imported.

In SqlPlus, connect to HE_ADMIN, and run the following code (replacing the value strings with strings appropriate for your installation):

exec setup.import_dream_manager('OPTIONAL_PREFIX','filename');

The longer version, if you need more control over the import is:

exec setup.import_dream_manager(to_prefix_in    => 'OPTIONAL_PREFIX',
                             filename_in     => 'filename',
                             from_prefix_in  => null,
                             jobname_in      => 'IMPORT_DREAM_MANAGER',
                             directory_in    => 'DATA_PUMP_DIR',
                             overwrite_in    => FALSE,
                             debug_in        => FALSE);

The new server needs to be configured:

In SqlPlus, connect to FS_SERVICE, and run the following code (replacing the value strings with strings appropriate for your installation):

set serveroutput on
  v_status  varchar2(8);
  v_msg     varchar2(32767);
  quick_setup.dream_manager(status_out          => v_status,
                            msg_out             => v_msg,
                            universe_name_in    => '<universe name>',
                            service_name_in     => 'DREAM_SERVER',
                            fireup_name_in      => '<fireup name>',
                            server_fullname_in  => '<host machine name>',
                            connectstring_in    => 'schema_name/password@dbservername.domain/hedb',
                            ignore_warnings     => false);
  dbms_output.put_line('Status: ' || v_status);
  dbms_output.put_line('Message: ' || v_msg);

After all the configuration changes, issue a /shutdown command to Master Control to reload the configurations from the database.

Configuring to Service Additional Worlds

The process supports an optional parameter specifying a list of connect strings for additional worlds it will service. The parameter name is DreamManagerMatrixTransports. The connect strings are something like tcp:machine.company.com:63333, and should match the world's defaultPORouterTransport parameter. Multiple connect strings must be separated by a pipe character (|).

After making the configuration change, issue a /reset command to Master Control to pick up the new value.

The process must be restarted to read the configuration.

Personal tools