Skip to content

Commit b387e64

Browse files
authored
V1.4 February 2023 Merge (#12)
* Restore / Remove WebApps * Preparing for February 2023 release * Graph fix env. var. * Remove duplicate Title in the details modal * Z removes the last filter value * Email from * Upgrade JAVA to 361 * Email To, CC & BCC as collection * New tika version to fix mime type on attachments * Email From & TO as suggestions * MV Refiner operator OR vs AND * Renamed landing pages sections * New facets L&F for better usability * Issue when creaing static filter * Issue with static last value removal * Feb2023 - readme --------- Co-authored-by: Nicolas Uthurriague <[email protected]>
1 parent 07db98e commit b387e64

File tree

26 files changed

+315
-91
lines changed

26 files changed

+315
-91
lines changed

CHANGES.md

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
11
# Changes log
22

3-
## January 2023 - V1.3 (in progress)
3+
## February 2023 - v1.4
4+
5+
- UI & API improvements
6+
- Documentation
7+
- Bugs fixing
8+
9+
## January 2023 - V1.3
10+
11+
- API Authorization
12+
- Neo4j Graph support for indexing
13+
- QuickView feature to ease access a Detail tab
14+
- Responsible AI documentation
415

5-
- API Authorization
6-
- Neo4j Graph support for query & indexing
716
- UI & API improvements
817
- Documentation
918
- Bugs fixing

configuration/config/search/indexes/index.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -706,9 +706,9 @@
706706
"fields": [
707707
{
708708
"name": "message_to",
709-
"type": "Edm.String",
709+
"type": "Collection(Edm.String)",
710710
"filterable": true,
711-
"sortable": true,
711+
"sortable": false,
712712
"facetable": true,
713713
"searchable": true,
714714
"retrievable": true
@@ -724,18 +724,18 @@
724724
},
725725
{
726726
"name": "message_cc",
727-
"type": "Edm.String",
727+
"type": "Collection(Edm.String)",
728728
"filterable": true,
729-
"sortable": true,
729+
"sortable": false,
730730
"facetable": true,
731731
"searchable": true,
732732
"retrievable": true
733733
},
734734
{
735735
"name": "message_bcc",
736-
"type": "Edm.String",
736+
"type": "Collection(Edm.String)",
737737
"filterable": true,
738-
"sortable": true,
738+
"sortable": false,
739739
"facetable": true,
740740
"searchable": true,
741741
"retrievable": true

deployment/modules/core/core.psm1

Lines changed: 41 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2083,6 +2083,44 @@ function Start-WebApps {
20832083
Pop-Location
20842084
}
20852085

2086+
function Remove-WebApps {
2087+
param (
2088+
[switch] $LinuxOnly,
2089+
[switch] $WindowsOnly
2090+
)
2091+
2092+
Push-Location $global:envpath
2093+
foreach ($plan in $webappscfg.AppPlans) {
2094+
foreach ($webApp in $plan.Services) {
2095+
if ($plan.IsLinux) {
2096+
if (-not $WindowsOnly) {
2097+
az webapp delete --resource-group $plan.ResourceGroup --name $webApp.Name
2098+
}
2099+
}
2100+
else {
2101+
if (-not $LinuxOnly) {
2102+
az webapp delete --resource-group $plan.ResourceGroup `
2103+
--name $webApp.Name
2104+
}
2105+
}
2106+
}
2107+
}
2108+
Pop-Location
2109+
}
2110+
2111+
function Restore-WebApps {
2112+
param (
2113+
[switch] $LinuxOnly,
2114+
[switch] $WindowsOnly
2115+
)
2116+
2117+
New-WebApps -LinuxOnly:$LinuxOnly -WindowsOnly:$WindowsOnly
2118+
2119+
Build-WebApps -LinuxOnly:$LinuxOnly -WindowsOnly:$WindowsOnly -Publish -KeyVaultPolicies -Settings
2120+
2121+
Set-WebAppServicesAccessRestriction
2122+
}
2123+
20862124
function Publish-WebApps {
20872125
param (
20882126
[switch] $Production,
@@ -2455,8 +2493,8 @@ function Suspend-Solution {
24552493
# De-Allocate Functions which are costly to leave running.
24562494
Remove-Functions
24572495

2458-
# Start Linux WebApp (e.g. Tika)
2459-
Stop-WebApps -LinuxOnly
2496+
# Remove Linux WebApp (e.g. Tika)
2497+
Remove-WebApps -LinuxOnly
24602498

24612499
}
24622500

@@ -2466,7 +2504,7 @@ function Resume-Solution {
24662504
Restore-Functions
24672505

24682506
# Start Linux WebApp
2469-
Start-WebApps -LinuxOnly
2507+
Restore-WebApps -LinuxOnly
24702508

24712509
}
24722510
#endregion

src/CognitiveSearch.Skills/C#/Metadata/Assignment/Assign.cs

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -165,19 +165,31 @@ public static WebApiResponseRecord Transform(CustomHeaders headers, WebApiReques
165165

166166
if (inRecord.Data.ContainsKey(Constants.email_to))
167167
{
168-
emailMetadata[Constants.email_to_output] = inRecord.Data[Constants.email_to];
168+
string keyValue = (string)inRecord.Data[Constants.email_to];
169+
170+
if (!String.IsNullOrEmpty(keyValue)) {
171+
emailMetadata[Constants.email_to_output] = SplitSemiColumn(keyValue);
172+
}
169173
}
170174
if (inRecord.Data.ContainsKey(Constants.email_from))
171175
{
172176
emailMetadata[Constants.email_from_output] = inRecord.Data[Constants.email_from];
173177
}
174178
if (inRecord.Data.ContainsKey(Constants.email_cc))
175179
{
176-
emailMetadata[Constants.email_cc_output] = inRecord.Data[Constants.email_cc];
180+
string keyValue = (string)inRecord.Data[Constants.email_cc];
181+
182+
if (!String.IsNullOrEmpty(keyValue)) {
183+
emailMetadata[Constants.email_cc_output] = SplitSemiColumn(keyValue);
184+
}
177185
}
178186
if (inRecord.Data.ContainsKey(Constants.email_bcc))
179187
{
180-
emailMetadata[Constants.email_bcc_output] = inRecord.Data[Constants.email_bcc];
188+
string keyValue = (string)inRecord.Data[Constants.email_bcc];
189+
190+
if (!String.IsNullOrEmpty(keyValue)) {
191+
emailMetadata[Constants.email_bcc_output] = SplitSemiColumn(keyValue);
192+
}
181193
}
182194
if (inRecord.Data.ContainsKey(Constants.email_subject))
183195
{

src/CognitiveSearch.Skills/Java/ApacheTika/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@ ENV TIKA_VERSION 2.2.2-SNAPSHOT
3131
ENV TIKA_SERVER_PKG=tika-server-standard-$TIKA_VERSION.jar
3232
ENV TIKA_HOME=/usr/local
3333

34-
ENV JAVA_VERSION=1.8.0_341 \
35-
JAVA_PKG=server-jre-8u341-linux-x64.tar.gz \
36-
JAVA_SHA256=71c5ef1d73737e324b5aff491a0603f6a9698006132d788df11ea6883b5d3b1b \
34+
ENV JAVA_VERSION=1.8.0_361 \
35+
JAVA_PKG=server-jre-8u361-linux-x64.tar.gz \
36+
JAVA_SHA256=413e658db77d33fc2587557d4b1093ca2268892d2c75e6298927db8bb8622d13 \
3737
JAVA_HOME=/usr/java/jdk-8
3838
ENV PATH $JAVA_HOME/bin:$PATH
3939

Binary file not shown.
Binary file not shown.
Binary file not shown.

src/CognitiveSearch.Skills/Python/Graph/Status/__init__.py

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,21 @@
88

99
from neo4j import GraphDatabase
1010

11-
if 'NEO4J_ENDPOINT' in os.environ:
12-
endpoint = os.environ["NEO4J_ENDPOINT"]
13-
user = os.environ["NEO4J_USERNAME"]
14-
password = os.environ["NEO4J_PASSWORD"]
11+
def main(req: func.HttpRequest) -> func.HttpResponse:
12+
logging.info('Python HTTP trigger function processed a request.')
1513

16-
neo4jdriver = GraphDatabase.driver(endpoint, auth=(user, password))
17-
else:
1814
neo4jdriver = None
1915

20-
def main(req: func.HttpRequest) -> func.HttpResponse:
21-
logging.info('Python HTTP trigger function processed a request.')
16+
if 'NEO4J_ENABLED' in os.environ:
17+
enabled = os.getenv("NEO4J_ENABLED", 'False').lower() in ('true', '1', 't')
18+
if enabled:
19+
endpoint = os.environ["NEO4J_ENDPOINT"]
20+
user = os.environ["NEO4J_USERNAME"]
21+
password = os.environ["NEO4J_PASSWORD"]
22+
try:
23+
neo4jdriver = GraphDatabase.driver(endpoint, auth=(user, password))
24+
except:
25+
neo4jdriver = None
2226

2327
if neo4jdriver:
2428
with neo4jdriver.session() as session:

src/CognitiveSearch.Skills/Python/Graph/shared_code/DocumentGrapher/DocumentGrapher.py

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,18 @@
44

55
from neo4j import GraphDatabase
66

7+
neo4jdriver = None
8+
79
if 'NEO4J_ENABLED' in os.environ:
8-
if os.environ['NEO4J_ENABLED']:
10+
enabled = os.getenv("NEO4J_ENABLED", 'False').lower() in ('true', '1', 't')
11+
if enabled:
912
endpoint = os.environ["NEO4J_ENDPOINT"]
1013
user = os.environ["NEO4J_USERNAME"]
1114
password = os.environ["NEO4J_PASSWORD"]
12-
neo4jdriver = GraphDatabase.driver(endpoint, auth=(user, password))
13-
else:
14-
neo4jdriver = None
15-
else:
16-
neo4jdriver = None
15+
try:
16+
neo4jdriver = GraphDatabase.driver(endpoint, auth=(user, password))
17+
except:
18+
neo4jdriver = None
1719

1820
def transform_value(record):
1921
try:

0 commit comments

Comments
 (0)