Child pages
  • WAR Deployment

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: SVY-13670

...

  1. Do one of the following:
    1. Go to File Export. A window will appear. In the tree, select Servoy > Export War File. Click on the Next button.
    2. Right click on the active solution in the Solution Explorer. Select Export Solution > War Export. A window will appear.
  2. Choose a name and a location for the export file. The name used for the export file automatically becomes the so-called "context" for the Servoy Application Server when installed on a application server, see About "context" for more info.

    You can use the options described below, then click Next.

     Option Description

    Include active solution and modules

    Export the active solution and its modules. If unchecked, only the Servoy application server is exported.

     

    Info

    If you check "Include active solution and modules", table changes and i18n, when selected, will be synced or imported into the application server when the WAR is first deployed. 

    If the active solution has pre/post import hooks, those will be called during the import process. 

    This solution (and its modules) won't be imported into the repository, but are serialized as a binary file that is read in from the file system every time the application/war is started. If that solution is also in the repository then that one will be deleted and will not be used. The repository is still needed for user and sequence management.


    Allow data model changes

    If checked, it allows database structure in case the database structure on the server is different than the one in the export. 

    e.g. table/columns changes or missing sequences

    It is also possible to specify the server names for which data model changes are allowed.

    Skip database view updatesIf checked, it skips database view updates.

    Export based on DBI files only

    Exports the database meta data information for the main solution and the modules (if needed) using only table definitions.

    Info

    This method is used if at export the database is down (or has errors) so tables/servers are not accessible.



    Export all tables from referenced servers

    If checked, it will export all the tables for any server used in the solution. 

    If it is unchecked, only tables that are actually used in the solution will be exported.

    Note

    if this option is unchecked, the tables which are not referenced by the solution will not be exported.


    Allow SQL keywords

    It allows exporting tables which contain SQL keywords in table and column names. 

    e.g. table having a column named “title”

    Update sequencesIf checked the sequences will be updated for the servers involved in the export, 

    otherwise they will not be touched.

    Override sequence types

    The sequence types will be overridden for the exported servers.

    Override default types

    If checked, the default values will be overridden for the exported servers. 

    Export metadata tablesExport all the metadata files in the workspace which are referenced by the solution. 
    Check metadata tablesCheck whether the workspace metadata files are in sync with the database tables.

    If it fails, then it throws an exception with the suggestion to update the meta data for the tables first, and the export does not continue. 

    If it is left unchecked, the export will be done based on the existing workspace meta data files, without checking if they are in sync with the database tables or not. 

    If checked and no metadata file is found in the workspace, the export will not continue, but throw an exception suggesting to update the meta data for the tables first.

    Export solution sample dataIf checked, data (from the current connection) for every table exported will be included. 

    All rows or a limited number of rows can be chosen to be exported.

    Note
    titleCareful

    If the dataset is large, then exporting too many rows may fail.


    Tip
    titleTip

    Even if sample data has been exported, if there is data already in a table when importing, it will not move sample data to the table on import.


    Export i18n data

    Exports the i18n keys used in the solution

    Overwrite repository group security settings with import version If checked, it overwrites the security settings for the groups which are exported and already present in the repository on the server.
    Export users

    Exports the Servoy users specified in user and group security

    Automatically upgrade repository if needed

    In case the repository version on the server is lower than the one of the developer used to export the solution, it automatically upgrades the repository.

    Create Tomcat META-INF/context.xmlTomcat specific option. Enable this option so that the options below can be enabled.
    Set antiResourceLocking to trueSet this option to true if running Tomcat on Windows and if having problems undeploying the war file. This option allows Tomcat to workaround the file locking feature of the OS and execute the undeploy. This option will impact the startup time of the war.
    Set clearReferencesStatic to trueSet this option to true if a war undeploy or stop operation causes a memory leak. This option sets static fields to null, thus allowing them to be garbage collected.
    Set clearReferencesStopThreads to trueUse with care. Set this option to true only as a last resort. Please read https://tomcat.apache.org/tomcat-8.0-doc/config/context.html for more information.
    Set clearReferencesStopTimerThreads to trueSet this option to true if after an undeploy or stop operation there are still Timer threads running.
    Minimize JS and CSSwhen set servoy will try to minimize the js of css files (when there are not already minimized so ending on .min.js) This is a much simpler minification then what a real minimizer does, so for component/service developers, if you have big support libs in your component or services packages use the minified version of that support lib. You can have reference the full version in the manifest and have the minified just besides it. Then in developer it will be easier to debug but at runtime the minified version will be taken.


  3. A list of all the plugins is shown. The plugins that will be used in the war can be left checked, the others can be omitted from the export.
  4. A list of all the beans is shown. The beans that will be used in the war can be left checked, the others can be omitted from the export.
  5. A list of all the laf files is shown. The lafs that will be used in the war can be left checked, the others can be omitted from the export.
  6. A list of all the jdbc drivers is shown. The drivers that will be used in the war and are not provided by the application server in which the war will be deployed can be left checked, the others can be omitted from the export.
  7. In the next dialog it is possible to choose which NG Components to export. The "exported components" list already contains the components required by the solution. However, in case the solution model is used to add components to forms/layouts, more components should be chosen from the "Available components" list.   
  8. Similarly to the components dialog, the exported services can be chosen. 
  9. Select a servoy properties file to be used for the export.
    1. If no file is provided, a default file will be generated. An extra page will be spawned in the wizard, where a few settings need to be specified for the generated servoy properties file:
      - Allow running smart clients - if checked, both smart web clients will be allowed to run, and it must be noted that when restarting the application context in the web container, the RMI classes will not be garbage collected, and that may lead to out-of-memory errors. If it is left unchecked, only web clients will be allowed to run.
      - Port used by RMI Registry - default port is 1099. 
    2. If a servoy properties file is specified, make sure the SocketFactory.tunnelConnectionMode on 'Network Settings' page in Servoy Admin is set to 'http&socket'. See About the servoy.properties file for more info.
  10. Click Finish (if no servoy properties file is specified, the needed settings for the default generated file have to be provided on the next page, then click Finish).
  11. The .war file will appear in the specified location.

...