Danamon Enhancement Rollout Document
Description
This update covers Danamon Enhancement changes for queue position, hold and video channel, Ldap connection info encryption features.
Effected Services
- Service
- Service.PureEngage
- Web.Admin
- Web.App
- DB views
- Mobile integration
- Web (iframe) integration
Update Steps
- Stop all ECV services.
- Take backups of all ECV services, including DB views.
- Update above services with provided zip file contents.
- Apply below configurations to specified services.
- Service.PureEngage config
- Web.Admin config
- Apply db view changes by running below sql scripts.
- Start services.
- Test everything works as expected.
- New video channel and flow attributes will be available on mobile after implementing the changes in attached mobile development guide documents. Before this the default values will be used for the attached data.
- Queue information and hold changes will work on mobile after implementing the changes in attached mobile development guide documents.
- Queue information and hold changes will work on web (iframe) after implementing the changes in attached web development guide documents.
Config Changes
Service.PureEngage
Update the following configuration file on the Service.PureEngage service.
Ccr.EasyConnect.Video.Service.PureEngage.exe.config
Add the following keys under appSettings:
<add key="PURE_ENGAGE_URS_BASE_ADDRESS" value="http://your-genesys-engage-urs-service:7017/" />
<add key="PureEngage.UseVirtualQueueInfo" value="true" />
Web.Admin
Web.ADmin config.js file LDAP field will be encrypted as is.
Use the ECV Encryption Tool Usage (EncryptionTool.exe) to encyrpt current values, put i config just like the knex (db) config. Check below encrpytion section for encryption tool usage.
Config Values
When PureEngage.UseVirtualQueueInfo is false, the service calls the regular URS queue data endpoint:
urs/call/{connId}/rvqdata
When PureEngage.UseVirtualQueueInfo is true, the service calls the virtual queue endpoint:
urs/call/{connId}/lvq
DB Changes
3. View: dbo.vw_videoCall
Run the following script on the target ECV database.
USE [ECV.43_Danamon_DEV]
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER VIEW [dbo].[vw_videoCall]
AS
WITH CTE_CallEvents AS
(
SELECT
CallId,
MAX(CASE WHEN CallEventTypeId = 1 THEN Timestamp END) AS BaslangicZamani,
MAX(CASE WHEN CallEventTypeId = 2 THEN Timestamp END) AS KuyrukZamani,
MAX(CASE WHEN CallEventTypeId = 3 THEN Timestamp END) AS KarsilanmaZamani,
MAX(CASE WHEN CallEventTypeId = 4 THEN Timestamp END) AS WebRtcBasZamani,
MAX(CASE WHEN CallEventTypeId = 5 THEN Timestamp END) AS BaglantiZamani,
MAX(CASE WHEN CallEventTypeId = 6 THEN Timestamp END) AS KayitBaslangicZamani,
MAX(CASE WHEN CallEventTypeId = 9 THEN Timestamp END) AS KapatmaZamani,
MAX(CASE WHEN CallEventTypeId = 9 THEN Data END) AS Kapatan,
MAX(CASE WHEN CallEventTypeId = 10 THEN Timestamp END) AS SonlandirmaZamani,
SUM(CASE WHEN CallEventTypeId = 12 THEN CAST(Data AS INT) ELSE 0 END) / 1000 AS ToplamHoldZamani,
COUNT(CASE WHEN CallEventTypeId = 11 THEN 1 ELSE NULL END) AS HoldSayisi
FROM dbo.CallEvent
GROUP BY CallId
),
CTE_CallerAttributes AS
(
SELECT
CallerHashId,
MAX(CASE WHEN Name = 'Name' THEN Value END) AS Arayan,
MAX(CASE WHEN Name = 'NikNumber' THEN Value END) AS NikNumarasi,
MAX(CASE WHEN Name = 'video_flow' THEN Value END) AS video_flow,
MAX(CASE WHEN Name = 'video_channel' THEN Value END) AS video_channel,
MAX(CASE WHEN Name = 'video_application' THEN Value END) AS video_application,
MAX(CASE WHEN Name IN ('video_language', 'video_langugage') THEN Value END) AS video_language
FROM dbo.CallerAttribute
WHERE Name IN (
'Name',
'NikNumber',
'video_flow',
'video_channel',
'video_application',
'video_language',
'video_langugage'
)
GROUP BY CallerHashId
)
SELECT
c.Id,
c.RtcId AS OdaNumarasi,
c.InteractionId AS InteractionCallId,
CASE WHEN c.Direction = 'I' THEN 'Inbound' ELSE 'Outbound' END AS InboundOutbound,
DATEADD(hour, 7, CE.BaslangicZamani) AS BaslangicZamani,
DATEADD(hour, 7, CE.KuyrukZamani) AS KuyrukZamani,
CE.Kapatan,
CASE WHEN CE.Kapatan = 'Abandoned' THEN 'Yes' ELSE NULL END AS IsAbandoned,
CE.ToplamHoldZamani,
CE.HoldSayisi,
ca.Arayan,
ca.NikNumarasi,
ca.video_flow,
ca.video_channel,
ca.video_application,
ca.video_language,
a.Name AS Agent,
q.Name AS WorkGroupAdi
FROM dbo.Call AS c
LEFT OUTER JOIN CTE_CallEvents AS CE ON c.Id = CE.CallId
LEFT OUTER JOIN dbo.Agent AS a ON c.AgentId = a.Id
LEFT OUTER JOIN dbo.Queue AS q ON c.QueueId = q.Id
LEFT OUTER JOIN CTE_CallerAttributes AS ca ON c.CallerHashId = ca.CallerHashId
GO
4. View: dbo.vw_videoCall_foreign
Run the following script on the target ECV database.
USE [ECV.43_Danamon_DEV]
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER VIEW [dbo].[vw_videoCall_foreign]
AS
WITH CTE_CallEvents AS
(
SELECT
CallId,
CallEventTypeId,
Timestamp,
Data,
ROW_NUMBER() OVER (
PARTITION BY CallId, CallEventTypeId
ORDER BY Id DESC
) AS rn
FROM dbo.CallEvent
),
CTE_CallerAttributes AS
(
SELECT
CallerHashId,
MAX(CASE WHEN Name = 'Name' THEN Value END) AS [Caller],
MAX(CASE WHEN Name = 'NikNumber' THEN Value END) AS NikNumber,
MAX(CASE WHEN Name = 'video_flow' THEN Value END) AS VideoFlow,
MAX(CASE WHEN Name = 'video_channel' THEN Value END) AS VideoChannel,
MAX(CASE WHEN Name = 'video_application' THEN Value END) AS VideoApplication,
MAX(CASE WHEN Name IN ('video_language', 'video_langugage') THEN Value END) AS VideoLanguage
FROM dbo.CallerAttribute
WHERE Name IN (
'Name',
'NikNumber',
'video_flow',
'video_channel',
'video_application',
'video_language',
'video_langugage'
)
GROUP BY CallerHashId
)
SELECT
c.Id,
c.RtcId AS RoomNo,
c.InteractionId AS InteractionCallId,
CASE WHEN c.Direction = 'I' THEN 'Inbound' ELSE 'Outbound' END AS InboundOutbound,
DATEADD(hour, 3, CE1.Timestamp) AS StartT,
DATEADD(hour, 3, CE2.Timestamp) AS QueueStartT,
DATEADD(hour, 3, CE3.Timestamp) AS PickUpT,
DATEADD(hour, 3, CE4.Timestamp) AS WebRtcStartT,
DATEADD(hour, 3, CE5.Timestamp) AS ConnectT,
DATEADD(hour, 3, CE6.Timestamp) AS RecordStartT,
DATEADD(hour, 3, CE9.Timestamp) AS HangUpT,
DATEADD(hour, 3, CE10.Timestamp) AS FinishT,
CASE WHEN CE9.Data = 'Abandoned' THEN 'customer' ELSE CE9.Data END AS ClosedBy,
CASE WHEN CE9.Data = 'Abandoned' THEN 'Yes' ELSE NULL END AS IsAbandoned,
ISNULL((
SELECT SUM(CAST(CE12.Data AS INT) / 1000)
FROM CTE_CallEvents CE12
WHERE CE12.CallId = c.Id
AND CE12.CallEventTypeId = 12
AND CE12.rn = 1
), 0) AS TotalHoldTime,
(
SELECT COUNT(*)
FROM CTE_CallEvents
WHERE CallId = c.Id
AND CallEventTypeId = 11
AND rn = 1
) AS TotalHoldCount,
ca.[Caller],
ca.NikNumber,
ca.VideoFlow,
ca.VideoChannel,
ca.VideoApplication,
ca.VideoLanguage,
a.Name AS Agent,
q.Name AS WorkGroupName
FROM dbo.Call c
LEFT JOIN CTE_CallEvents CE1 ON c.Id = CE1.CallId AND CE1.CallEventTypeId = 1 AND CE1.rn = 1
LEFT JOIN CTE_CallEvents CE2 ON c.Id = CE2.CallId AND CE2.CallEventTypeId = 2 AND CE2.rn = 1
LEFT JOIN CTE_CallEvents CE3 ON c.Id = CE3.CallId AND CE3.CallEventTypeId = 3 AND CE3.rn = 1
LEFT JOIN CTE_CallEvents CE4 ON c.Id = CE4.CallId AND CE4.CallEventTypeId = 4 AND CE4.rn = 1
LEFT JOIN CTE_CallEvents CE5 ON c.Id = CE5.CallId AND CE5.CallEventTypeId = 5 AND CE5.rn = 1
LEFT JOIN CTE_CallEvents CE6 ON c.Id = CE6.CallId AND CE6.CallEventTypeId = 6 AND CE6.rn = 1
LEFT JOIN CTE_CallEvents CE9 ON c.Id = CE9.CallId AND CE9.CallEventTypeId = 9 AND CE9.rn = 1
LEFT JOIN CTE_CallEvents CE10 ON c.Id = CE10.CallId AND CE10.CallEventTypeId = 10 AND CE10.rn = 1
LEFT JOIN dbo.Agent a ON c.AgentId = a.Id
LEFT JOIN dbo.Queue q ON c.QueueId = q.Id
LEFT JOIN CTE_CallerAttributes ca ON c.CallerHashId = ca.CallerHashId
WHERE CE1.rn = 1
OR CE2.rn = 1
OR CE3.rn = 1
OR CE4.rn = 1
OR CE5.rn = 1
OR CE6.rn = 1
OR CE9.rn = 1
OR CE10.rn = 1
GO
ECV Encryption Tool Usage (EncryptionTool.exe)
This tool is used to generate and decrypt encrypted AdminApi configuration values.
Usage areas:
- Encrypting / decrypting
knexdatabase config - Encrypting / decrypting
ldapconfig
3. Encrypt Usage
To encrypt, enter plain text or JSON into the input area and click Encrypt.
Example LDAP config input:
{
"enabled": false,
"url": "ldap://xx.xx.xx.xx:389",
"bindDn": "CN=Linux Admin,CN=Users,DC=ccr,DC=net",
"bindCredentials": "********",
"searchBase": "CN=Users,DC=ccr,DC=net",
"searchFilter": "(samaccountname={{username}})",
"LDAPRoleMapping": {}
}
Encrypt output is generated in the following format:
{
"iv": "...",
"content": "..."
}
The iv value is generated randomly for each encryption operation. Therefore, different outputs for the same input are expected.
4. Usage in config.js
The encrypt output can be used in config.js as follows:
ldap: {
iv: "...",
content: "..."
}
Quoted property names are also valid:
ldap: {
"iv": "...",
"content": "..."
}
Database config uses the same format:
knex: {
iv: "...",
content: "..."
}
Additions For Threshold Feature
Updated Services
- Web.Admin
- Service
- Service.PureEngage
- DB
DB Query To Update
IF COL_LENGTH('dbo.Queue', 'QueueThreshold') IS NULL
BEGIN
ALTER TABLE [dbo].[Queue] ADD [QueueThreshold] [int] NOT NULL CONSTRAINT [DF_Queue_QueueThreshold] DEFAULT ((0));
END
GO
IF COL_LENGTH('dbo.Queue', 'QueueFullMessage') IS NULL
BEGIN
ALTER TABLE [dbo].[Queue] ADD [QueueFullMessage] [nvarchar](500) NULL;
END
GO
Service Configs
After updating service, below config line must be added.
<add key="QueueThreshold.WorkingHoursQueueId" value="" />
Inside value the current queue id from admin panel should be put in.
Admin Panel: Virtual Queue Definitions (Required)
The service resolves the call's queue from the combined virtual queue name:
VQ = video_flow + video_channel (e.g.
ETB+Registration→ETBRegistration)
For every virtual queue, a Queue record with the exact same name must be created on the admin panel (Settings → Queues). Without it, the call falls back to the old default queue and the threshold feature does not apply to that call.
Queues to create:
NTBSaving (2.0)NTBCredit CardETBRegistrationETBReactivationETBActivationNTBSaving (1.0)— used for old clients that send no video attributes; the service fills the defaultsvideo_flow = NTB,video_channel = Saving (1.0)
On each queue, set:
- Queue Threshold — maximum number of waiting calls. A new call is rejected
when the current URS waiting count is greater than this value.
0(or below) disables the check for that queue: no limit. - Queue Full Message — the message returned to the caller when the queue is full (shown by the client, same mechanism as the working hours message).
Genesys Side (Required)
The virtual queues listed above must exist in URS (created/used by the routing
strategy). The interaction is still submitted to the existing interaction queue;
the strategy routes it through the virtual queue based on the video_flow and
video_channel attributes. The service only reads the VQ statistics from URS.
Behavior Summary
On every DialEx call the service:
- Builds the VQ name from the caller attributes (defaults applied for old clients).
- Resolves the admin Queue with that name — the call record, working hours check and threshold check are all keyed to this queue.
- Checks working hours (against
QueueThreshold.WorkingHoursQueueIdwhen set, otherwise against the resolved queue — the resolved queue then needs working hours defined on the admin panel, or every call on it is rejected). - Asks URS for the VQ's current waiting call count and compares it to the queue's threshold. Count above threshold → the call is rejected with the queue's Queue Full Message.
Failure handling: if URS is unreachable, the VQ is unknown to URS, or the admin lookup fails, the threshold check is skipped and the call proceeds normally; the incident is written to the service log. Admin threshold values are cached in the service for 60 seconds, so threshold/message changes take effect within a minute without a restart.

No comments to display
No comments to display