Resolution

There are some things that may make application development easier, this is a hub article for such tips and tricks.

  1. Not enough information on actions/errors or changing UI files on filesystem does not have effect, server serves cached pages:

    Enable 'APS development mode' in System > Settings > Core > System Properties in OA PCP.

    • find additional information in main log /var/log/poa.debug.log for OA 5.5 version, /var/log/poa.log for OA 6.0 onwards
    • find JSON-formatted requests sent to endpoints in /tmp
    • develop custom UI for packages on file-system, this option disables server-side caching
  2. Browser session expired too quickly:

    OA 5.5

    Change session timeout for frequently used accounts (admin, main account used for testing) in System > Users > [choose user] > Session Timeout

    OA 6.x

    Change session timeout for all accounts in System > Settings > System Properties > User session timeout (minutes)

  3. Too much time is spent on endpoint configuration after each sandbox reinstallation:

    Set up endpoint automatically using the automatic endpoint configuration script.

  4. Too much time is spent on 'Introducing changes - Packaging - Uploading - Testing' cycle:

    • files in ui/ folder can be edited on management node
    • files in scripts/ folder can be edited on endpoint server

If it's needed to change navigation or schema for services application should be re-packaged.

  1. Need to locate ui folder to edit the view directly on filesystem:

    • If you know application name, version and release:

      psql -t -Uplesk -h`hostname` -c "select content_root_uri from aps_package where name = 'NAME' and version = 'VERSION' and release = 'RELEASE'"
      

      Name, version and release can be found in provider's panel in Services > Applications

    • If you know package uid

      Package id is seen in web debugger in any request header, check Referer:

      Referer http://sandbox.apsdemo.ru:8080/aps/2/packages/PACKAGE_UID/ui/servers.htm

      Get the path to package by running following commands in shell on OA core:

      OA 5.5

      # psql -t -Uplesk -h`hostname` -c "select content_root_uri from aps_package where registry_object_id in (select id from aps_registry_object where uid = 'PACKAGE_UID')"
      

      OA 6.x

      # psql -t -Uplesk -h`hostname` -c "select content_root_uri from aps_package where id in (select package_id from aps_application where uid = 'PACKAGE_UID')"
      

      Note that APS development mode (see point 1 above) must be enabled if you wish to edit your custom UI directly on file system, otherwise you will have to restart OA UI for changes to take effect.

Internal content