Release Notes


Queue Service - Deploying using MS Build

posted Jul 6, 2018, 4:22 PM by Greg Kent

Queue Service and BOT Service deployment is now facilitated using MSBuild and should be deployed whenever a new build is made. 
  • MSI installs have been deprecated
  • MSBuild 2017 is supported

Queue Service Details

  • Queue Service solution (<root>/QueueService/QueueService.sln) has been refactored and simplified. All BOT projects have been removed.
  • qbo3.QueueServiceTargets supports the deployment and registration of Queue Service on the target machine. Targets:
    • QueueService - stops and unregisters (if existing), deploys and registers QueueService. It will NOT automatically start Queue Service. 
    • qsStart - Starts Queue Service
    • qsStop - Stops Queue Service
    • qsDeploy - Deploys content of Queue Service
    • qsCreate - Registers Queue Service
    • qsDelete - UnRegisters Queue Service
  • QueueService now deploys to <WebsiteRoot>/bin vs. MSI install location of C:\Program Files\Quandis\Queue Service. This allows QueueService to utilize the same dlls as the application.
  • QueueService.exe.config
    • Now deploys to <WebsiteRoot>/bin
    • Config File Autodetect - Auto detection of application's web.config file is now supported. If Queue Service is installed in <WebsiteRoot>/bin there is no need to specify a path for the QueueSource.ConfigFile. Instead the value "autodetect" is specified. This is the recommended pattern.
    • This file is usable "as-is" except for custom herd or Cloudwatch logging configuration. If customization is required the suggested pattern is to create a copy of QueueService.exe.config in the respective theme project at same level as web.config and set "Copy To Output Director" = "Copy if newer", Build Action = "None"
  • To Build and Deploy:
    • Save existing QueueService.exe.config file in MSI install location of C:\Program Files\Quandis\Queue Service. Compare to QueueServiceDeploy/QueueService.exe.config to see if there is any customization.
    • Uninstall Queue Service from add/remove programs
    • From main proj file, CallTarget "QueueService". See qbo3.Sample.2017 for usage.
      • SiteFolder must be specified as a parameter if SiteFolder is other than C:\inetpub\wwwroot (specified in qbo3.Powershell.Targets)

BOT Service Details

  • BOTService.sln has been created and only contains BOT Service projects and has been decoupled from Queue Service
  • BOT Service deployment follows same pattern as Queue Service:
  • qbo3.BOT ServiceTargets supports the deployment and registration of BOT Service on the target machine. Targets:
    • BotService - stops and unregisters (if existing), deploys and registers BOT Service. It will NOT automatically start BOT Service. 
    • bsStart - Starts BOT Service
    • bsStop - Stops BOT Service
    • bsDeploy - Deploys content of BOT Service
    • bsCreate - Registers BOT Service
    • bsDelete - UnRegisters BOT Service
  • BOTService.exe.config
    • Now deploys to <WebsiteRoot>/bin
    • Updated to support auto detection of  QueueService.exe.config.  Set BOTSource.ConfigFile  = "autodetect". This is the recommended pattern.
    • EC2 Autoscale and UserData dynamic config file copies, change:
      • $targetFolder = <WebsiteRoot>\bin. eg. C:\inetpub\wwwroot\bin
      • Any reference to "QBO BOT Service" to "qbo BOT Service". Note case sensitivity
  • To Build and Deploy:
    • Uninstall BOT Service from add/remove programs
    • From main proj file, CallTarget "BOTService"
      • SiteFolder must be specified as a parameter if SiteFolder is other than C:\inetpub\wwwroot (specified in qbo3.Powershell.Targets)



Caching: Sliding Expiration Policy

posted Jun 27, 2018, 11:13 AM by Travis Croxford   [ updated Jul 5, 2018, 1:18 PM by Eric Patrick ]

Potential breaking change; If you have a private plugin/project (not included in the qbo.Core solution), and it leverages caching, you will need to add a new reference to System.Runtime.Caching.

MemoryCache can now have a policy applied to it when an object is being added.

Code example:

CacheItemPolicy policy = new CacheItemPolicy { SlidingExpiration = TimeSpan.FromHours(2) };
qbo.Application.Caching.MemoryCache pacerCache = new qbo.Application.Caching.MemoryCache(new Application.Configuration.Cache());
pacerCache.Set(credentialKey, pacerCreds, policy);

This allows for a cached item to remain in cache for 2 hours, until it's accessed again then the 2 hour timer starts over. After 2 hours without being accessed the item will fall out of cache.

Note that qbo.Application.Tests/CacheManagerTests.cs has been added to qbo.Application.Tests, which validates the behavior of CacheManager_SlidingExpiration().

Matrix: update from a spreadsheet

posted Apr 20, 2018, 3:43 PM by Chad Boyer   [ updated Apr 21, 2018, 10:10 AM by Eric Patrick ]

The QBO Matrix View panel supports updating a matrix from a spreadsheet (CSV file).  One can:
  • Export a matrix view via Options-> Export to CSV
  • Update the matrix data in Excel (or another spreadsheet editor)
  • Drop the revised spreadsheet on the Matrix View header to update the matrix
In order for this to work, navigate to Design > Configuration > Modules, choose the Matrix modules, and from the Settings tab, ensure the MatrixViewImport setting is set to true. (The underlying application setting is qbo.Application.Properties.Settings.MatrixViewImport.)

Additionally, one can:
  • Copy an existing matrix to a new matrix: from the Matrix Summary's Edit menu, choose Copy.  
  • Export a Matrix: from the Matrix Summary's Edit menu, choose Export.
  • Import a Matrix: from Home > Import Data, choose the QBO XML engine, and drop an exported matrix onto the import panel.
Technical notes:
  • Updating a matrix from a spreadsheet requires each column have a matching Input our Output column
  • CSV files need to have its columns wrapped in quotes for each field

qbo.MethodElement.js extended to respond to Events

posted Apr 16, 2018, 4:11 PM by Philip Raath

qbo.MethodElement can now trigger an API call in response to an Event.

To configure, assign the Event to the renderOnEvent property of the MethodElement options.

Code example:
<div name="EventTests">
          <input type="button" id="testButton" value="Click Me!"/>
          <div id="Question3" data-behavior="MethodElement" data-methodelement-options="{{'className': 'SLSLoan', 'operation': 'Search', 'parameters':                                                                                               'DisplaySize=1', 'renderOnEvent': 'testButton.click'}}"></div>
          <input type="hidden" id="PIConstant" data-methodelement-value="Question3.PIConstant"/>
        </div>

GUI Example:

Tests: Theme.ashx/Specs?Library=Behaviors\Spec.MethodElement.js

qbo.Depend extended to respond to Button clicks

posted Apr 6, 2018, 5:16 PM by Philip Raath   [ updated Apr 6, 2018, 5:18 PM ]

qbo.Depend can now toggle the 'disabled' class on the basis of a button click.

To assign this dependency, use the pattern: {buttonId} = click as the 'depends' parameter.

Example:
<div id="buttonTestsDiv">
    <label for ="buttonTest1">Button Test 1</label>
    <div class="controls">
      <input type="button" id="testButton" value="Click me!"/>
      <input type="text" id="buttonTest1" data-behavior="Depend" data-depend-options="{{'depends': 'testButton = click', 'condition': 'and',                         'disabledClass': 'disabled'}}"/>
    </div>
</div>

Tests: Theme.ashx/Specs?Library=Behaviors\Spec.Depend.js

C# 7 Features with Visual Studio 2015

posted Apr 6, 2018, 10:19 AM by Eric Patrick

QBO is starting to use new C# 7 features. To compile with Visual Studio 2015, you need to add the Microsoft.Net.Compilers Nuget package.

See also a Stack Overflow post: How to use C# 7 with Visual Studio 2015?

Rolling Log Update

posted Mar 6, 2018, 2:58 PM by Brian Espinoza

qbo.Logging has been extended with RollingLog and RollingLogTraceListener classes. This extends LogEntry (ETL) functionality for anyone wishing to log RollingLog from all machines to an outside database / table (dbo.RollingLog). This table can be accessed from the front-end UI via /Logging/RollingLog.ashx/ or /Logging/Logging.ashx > DailyLogTable.
Features:
  • This update was built with standalone Logging in mind. As such: 
    • To Log and/or Search, RollingLogTraceListenerData will scan your connection strings for one of name: "qbo.Logging". Should "qbo.Logging" not exist in your connection strings, it will cascade to your "qbo.Default" connection.
    • RollingLog is implemented entirely as an ISearchable and performs individual sqlClient queries for inserting RollingLog entries, searching records, and dashboard display.
      • RollingLog.ashx routes through the RollingLogTraceListener to perform ISearchable hits.
      • Note that ISearchable and all tracelisteners that implement it have been extended with a Dashboard method. This will be a breaking change, meaning you will want to get latest on qbo.Logging, qbo.Logging.Amazon, and qbo.Message.Amazon since these projects implement ISearchable TraceListeners.
  • You can now query and filter RollingLog directly from the front-end.
    • Hit the magnifying glass to expand filter options.
  • The "Message" field contains most of your error message. We have added a Full-Text Index to this column and will support Full-Text Index query notation.
    • msdn offers some support here: https://docs.microsoft.com/en-us/sql/t-sql/queries/contains-transact-sql
    • Message supports the following:
      • { AND | & } | { AND NOT | &! } | { OR | | } : searchTerm1 AND searchTerm2
      • { OR | | } : searchTerm1 OR searchTerm2
      • { NEAR | ~ } : searchTerm1 NEAR searchTerm2
      • Chained NEAR:  searchTerm1 ~ searchTerm2 ~ searchTerm3
      • Prefixing -- akin to Quand%: "Quand*"
    • Note that "Message" still supports using "%" in searches but these queries are not indexed and may be non-performant.
Notes:
  • Searches automatically filter records based on qbo.Application default settings for SiteName.
    • This prevents the scenario in which SLS can see QMS RollingLog records.
  • With Phase I, we've ensured that the RollingLog table captures all exceptions currently being captured by RollingLog.txt
    • Phase II we might consider logging IIS errors or Event Logs.

Deployment Instructions:
  • Get latest qbo.Logging, qbo.LogginWeb, qbo.Logging.Amazon, qbo.Message.Amazon, qbo.Application
  • In web.config, add or uncomment "DailyLogTable" under loggingConfiguration > Listeners and under categorySources > add[name = "General"] > Listeners
  • Ensure connection strings has a connection for "qbo.Logging". Ping the QMS team for this.
  • Deploy and test.

Visual Studio 2017 and MSBuild Deployments

posted Jan 22, 2018, 4:50 PM by Eric Patrick   [ updated Jul 6, 2018, 12:35 PM ]

For a machine with Visual Studio 2017 only, see qbo.Sample.2017.proj for changes needed to make CI deployments work.

To sum up:
  • Download and install the Build Tools for Visual Studio 2017
  • Ensure your project file targets VS version 15 (2017), instead of 14 (2015):
    • <VS Condition=" '$(VS)'=='' ">15.0</VS>
  • BuildTools does not include SSDT and SQL components by default. Copy the Microsoft database target (SSDT, SQL) from the Visual Studio folder to the BuildTools folder:
    • Copy-Item 'C:\Program Files (x86)\Microsoft visual studio\2017\Professional\MSBuild\Microsoft\VisualStudio\v15.0\SSDT\*.*' 'C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\Microsoft\VisualStudio\v15.0\SSDT'
    • Copy-Item 'C:\Program Files (x86)\Microsoft visual studio\2017\Professional\Common7\IDE\Extensions\Microsoft\SQLDB' 'C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\Extensions\Microsoft\SQLDB' -recurse -force
  • Run the 2017 build:
    • & 'C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\amd64\MSBuild' .\qbo3.Sample.proj 
To integrate database builds into a fully automated CI environment, consider installing the MS Build data tools Nuget package.

IService Permission Update - Breaking Change

posted Jan 17, 2018, 3:50 PM by Greg Kent   [ updated Jan 24, 2018, 3:08 PM ]

IService permission verification has been updated to match functionality of statement verification. Specifically:
  • VerifyPermission now verify pattern {ClassName}{ServiceName}. It previously used pattern {ServiceName}. This is a breaking change
  • VerifyPermission now supports allowing inheritance which is set within each Service. Note if Service.AllowInheritance is null, it cascades to value set for qbo.Application.Properties.Settings.Default.AllowInheritance

Fix Service Permissions

SystemFunction contains a new method ListInvalidServiceFunctions that will:
  • Identify any SystemFunctions that match the old naming pattern for each ServiceName {ServiceName}
  • Insert new SystemFunction {ClassName}{ServiceName} if it does not exist
  • Copy all SystemPermissions tied to original SystemFunction under new SystemFunction
It also supports a preview method. Usage:

  • /Security/SystemFunction.ashx/ListInvalidServiceFunctions?Output=Xml - will display a preview of the old SystemFunction, new SystemFunction and count of SystemPermissions that are associated with old SystemFunction. No inserts occur.
  • /Security/SystemFunction.ashx/ListInvalidServiceFunctions?Output=Xml&Update=true - will Insert new SystemFunctions and SystemPermissions with above logic
Example:
  • Contact module has a Service registered labeled AccurintSearch which has permissions tied to SystemRole User.  There is a corresponding SystemFunction labeled AccurintSearch
  • After the update, there will be a new SystemRole record ContactAccurintSearch with a SystemPermission record pointing to SystemRole User
Note with class inheritance, classes such as Organization,Court, Person and other classes that inherit from Contact will show Services registered under their classes. ListInvalidServiceFunctions will also insert SystemFunctions for:

  • OrganizationAccurintSearch
  • CourtAccurintSearch
  • PersonAccurintSearch
  • etc.
and copy SystemPermissions for each.

Important

Please ensure the update is run before Queue Service or any site activity occurs on the target platform. This is becuase SystemFunctions will automatically insert if they do not exist. By being inserted, they will be excluded from ListInvalidServiceFunctions and SystemPermissions will not be copied. 

Import Engine Async Implementation

posted Dec 28, 2017, 6:18 AM by Eric Patrick

All QBO Import Engines contained in qbo.Import have been converted to support asynchronous processing.  The net result is:
  • All IImportEngine methods now support asynchronous processing
  • Import Engines now favor an asynchronous code path and invoke QBO methods signatures using AbstractObject/InvokeAsync. If necessary this will cascade to synchronous operations when asynchronous is not implemented.
See qbo.Import.Tests for unit tests on all QBO Import Engines.

1-10 of 42