From 13c951fa3b6160658ae5ff0a3b2913a8288f3638 Mon Sep 17 00:00:00 2001
From: Heba <heelayot@microsoft.com>
Date: Thu, 5 Dec 2019 15:48:10 +0000
Subject: [PATCH] Updated settings.xml to match the new setting.xml in the
 artifact

---
 indexer-core/maven/settings.xml               |  4 +-
 .../src/main/resources/application.properties | 26 ++++++
 .../src/main/resources/application.properties | 86 +++++++++++++++++++
 .../src/main/resources/application.properties | 61 +++++++++++++
 4 files changed, 175 insertions(+), 2 deletions(-)
 create mode 100644 indexer-core/src/main/resources/application.properties
 create mode 100644 provider/indexer-azure/src/main/resources/application.properties
 create mode 100644 provider/indexer-gcp/src/main/resources/application.properties

diff --git a/indexer-core/maven/settings.xml b/indexer-core/maven/settings.xml
index 504ef0e8d..b7a15a010 100644
--- a/indexer-core/maven/settings.xml
+++ b/indexer-core/maven/settings.xml
@@ -4,8 +4,8 @@
           xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
     <servers>
         <server>
-            <id>dev-azure-com-slb-des-ext-collaboration-os-core</id>
-            <username>os-core</username>
+            <id>os-core</id>
+            <username>slb-des-ext-collaboration</username>
             <!-- Treat this auth token like a password. Do not share it with anyone, including Microsoft support. -->
             <!-- The generated token expires on or before 11/14/2019 -->
             <password>${VSTS_FEED_TOKEN}</password>
diff --git a/indexer-core/src/main/resources/application.properties b/indexer-core/src/main/resources/application.properties
new file mode 100644
index 000000000..022eb7a15
--- /dev/null
+++ b/indexer-core/src/main/resources/application.properties
@@ -0,0 +1,26 @@
+##server.servlet.contextPath=/api/indexer/v2
+#logging.level.org.springframework.web=DEBUG
+#server.port=8080
+#JAVA_HEAP_OPTS=-Xms4096M -Xmx4096M
+#JAVA_GC_OPTS=-XX:+UseG1GC -XX:+UseStringDeduplication -XX:InitiatingHeapOccupancyPercent=45
+#PUBSUB_SEARCH_TOPIC=records-changed
+#AUTHORIZE_API=https://entitlements-dot-opendes.appspot.com/entitlements/v1
+#STORAGE_HOSTNAME=os-storage-dot-opendes.appspot.com
+#GOOGLE_AUDIENCES=245464679631-ktfdfpl147m1mjpbutl00b3cmffissgq.apps.googleusercontent.com
+#
+## must update redis hosts at runtime appropriate to deployment environment
+#REDIS_GROUP_HOST=REDIS-GROUP-HOST
+#REDIS_SEARCH_HOST=REDIS-SEARCH-HOST
+#
+## use 127.0.0.1 for local run/debug mode
+##REDIS_GROUP_HOST=127.0.0.1
+##REDIS_STORAGE_HOST=127.0.0.1
+#
+## use below values for gcp: opendes
+##REDIS_GROUP_HOST=10.0.16.28
+##REDIS_STORAGE_HOST=10.0.16.12
+#
+#REDIS_GROUP_PORT=6379
+#REDIS_SEARCH_PORT=6379
+#DEFAULT_DATA_COUNTRY=US
+
diff --git a/provider/indexer-azure/src/main/resources/application.properties b/provider/indexer-azure/src/main/resources/application.properties
new file mode 100644
index 000000000..a79e32ddc
--- /dev/null
+++ b/provider/indexer-azure/src/main/resources/application.properties
@@ -0,0 +1,86 @@
+#server.servlet.contextPath=/api/indexer/v2/
+logging.level.org.springframework.web=DEBUG
+server.port=8080
+JAVA_HEAP_OPTS=-Xms4096M -Xmx4096M
+JAVA_GC_OPTS=-XX:+UseG1GC -XX:+UseStringDeduplication -XX:InitiatingHeapOccupancyPercent=45
+
+DEFAULT_DATA_COUNTRY=US
+
+AUTHORIZE_API=https://opendesproxy.azurewebsites.net/entitlements/v1
+AUTHORIZE_API_KEY=dummy
+LEGALTAG_API=https://opendesproxy.azurewebsites.net/legal/v1
+LEGALTAG_API_KEY=dummy
+CRS_API=https://opendesproxy.azurewebsites.net/crs/v1
+CRS_API_KEY=dummy
+
+#Default Cache Settings
+SCHEMA_CACHE_EXPIRATION=60
+INDEX_CACHE_EXPIRATION=60
+ELASTIC_CACHE_EXPIRATION=1440
+CURSOR_CACHE_EXPIRATION=60
+# Kinds Cache expiration 2*24*60
+KINDS_CACHE_EXPIRATION=2880
+# Attributes Cache expiration 2*24*60
+ATTRIBUTES_CACHE_EXPIRATION=2880
+# Maximum size of cache value
+MAX_CACHE_VALUE_SIZE=1000
+
+KINDS_REDIS_DATABASE=1
+CRON_INDEX_CLEANUP_THRESHOLD_DAYS=3
+CRON_EMPTY_INDEX_CLEANUP_THRESHOLD_DAYS=7
+
+STORAGE_SCHEMA_HOST=https://opendesmvp.azurewebsites.net/schemas
+STORAGE_QUERY_RECORD_HOST=https://opendesmvp.azurewebsites.net/query/records
+STORAGE_QUERY_RECORD_FOR_CONVERSION_HOST=https://opendesmvp.azurewebsites.net/query/records:batch
+STORAGE_RECORDS_BATCH_SIZE=20
+
+INDEXER_QUEUE_HOST=https://requeuefunction-cd1.azurewebsites.net/api/re-enqueue
+
+#MSAL AAD
+aad.authority=https://login.microsoftonline.com/1668106e-2ae0-456a-bb7d-64b52104db99/oauth2/token
+aad.clientId=b70451c6-936f-4430-8680-0985817ac751
+aad.secretKey=b5GZtbS.bB7iSzLTb+Nb-AOb9G@1@LZo
+aad.oboApi=api://ffb32b1a-c6fe-4ed0-819b-6ca483de3640
+
+spring.security.oauth2.client.registration.azure.client-id=b70451c6-936f-4430-8680-0985817ac751
+spring.security.oauth2.client.registration.azure.client-secret=b5GZtbS.bB7iSzLTb+Nb-AOb9G@1@LZo
+spring.security.oauth2.client.registration.azure.client-name=Azure
+
+
+#spring.security.user.name=opendes@byoc.local
+#spring.security.user.password=123
+#spring.security.user.roles=service.indexer.admin
+
+
+# Azure AD configuration
+azure.activedirectory.client-id=ffb32b1a-c6fe-4ed0-819b-6ca483de3640
+azure.activedirectory.tenant-id=1668106e-2ae0-456a-bb7d-64b52104db99
+azure.activedirectory.AppIdUri=api://${azure.activedirectory.client-id}
+azure.activedirectory.session-stateless=true
+
+#azure.activedirectory.active-directory-groups=ADMIN, VIEWER
+
+# Azure CosmosDB configuration
+azure.cosmosdb.uri=https://opendescosmosdb.documents.azure.com:443/
+azure.cosmosdb.key=AQK0VbnMGn76h9Ypw5aoirKMwoAYJBRY2XENn1dAYypoea83weVyjYcGaRDeEX7HqXIVggaDuFAhQ4Y1Y9lKDQ==
+azure.cosmosdb.database=opendesdb
+
+
+# Azure Service Bus configuration
+azure.servicebus.connection-string=Endpoint=sb://pliuopendes.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=km8Nscc0gf299Ck6npmM3D14VU5Tx1lJYRdlHcExIvY=
+azure.servicebus.topic-name=recordstopic
+
+#Indexer-Queue-header
+indexer.queue.key=abcd
+
+REDIS_GROUP_HOST=127.0.0.1
+REDIS_GROUP_PORT=6379
+REDIS_SEARCH_HOST=localhost
+REDIS_SEARCH_PORT=6379
+
+ELASTIC_DATASTORE_KIND=SearchSettings
+ELASTIC_DATASTORE_ID=indexer-service
+
+GAE_SERVICE=indexer
+
+DEPLOYMENT_ENVIRONMENT=CLOUD
\ No newline at end of file
diff --git a/provider/indexer-gcp/src/main/resources/application.properties b/provider/indexer-gcp/src/main/resources/application.properties
new file mode 100644
index 000000000..8426754d9
--- /dev/null
+++ b/provider/indexer-gcp/src/main/resources/application.properties
@@ -0,0 +1,61 @@
+server.servlet.contextPath=/api/indexer/v2
+logging.level.org.springframework.web=DEBUG
+server.port=8080
+#spring.cloud.gcp.project-id=opendes
+#spring.security.user.roles=service.search.admin
+JAVA_OPTS=-Xms3072m -Xmx3072m
+JAVA_GC_OPTS=-XX:+UseG1GC -XX:+UseStringDeduplication -XX:InitiatingHeapOccupancyPercent=45
+
+GOOGLE_AUDIENCES=245464679631-ktfdfpl147m1mjpbutl00b3cmffissgq.apps.googleusercontent.com
+
+## use below values for gcp: local
+#REDIS_GROUP_HOST=127.0.0.1
+#REDIS_SEARCH_HOST=localhost
+#DEPLOYMENT_ENVIRONMENT=LOCAL
+
+## use below values for gcp: opendes
+REDIS_GROUP_HOST=10.0.16.28
+REDIS_SEARCH_HOST=10.0.16.20
+DEPLOYMENT_ENVIRONMENT=CLOUD
+
+REDIS_GROUP_PORT=6379
+REDIS_SEARCH_PORT=6379
+DEFAULT_DATA_COUNTRY=US
+
+AUTHORIZE_API=https://entitlements-dot-opendes.appspot.com/entitlements/v1
+LEGALTAG_API=https://legal-dot-opendes.appspot.com/api/legal/v1
+CRS_API=https://crs-converter-dot-opendes.appspot.com/api/crs/v1
+
+
+#Default Cache Settings
+SCHEMA_CACHE_EXPIRATION=60
+INDEX_CACHE_EXPIRATION=60
+ELASTIC_CACHE_EXPIRATION=1440
+CURSOR_CACHE_EXPIRATION=60
+# Kinds Cache expiration 2*24*60
+KINDS_CACHE_EXPIRATION=2880
+# Attributes Cache expiration 2*24*60
+ATTRIBUTES_CACHE_EXPIRATION=2880
+
+KINDS_REDIS_DATABASE=1
+CRON_INDEX_CLEANUP_THRESHOLD_DAYS=3
+CRON_EMPTY_INDEX_CLEANUP_THRESHOLD_DAYS=7
+
+GOOGLE_CLOUD_PROJECT=opendes
+GAE_SERVICE=indexer
+
+INDEXER_HOST=os-indexer-dot-opendes.appspot.com
+STORAGE_HOSTNAME=os-storage-dot-opendes.appspot.com
+
+KEY_RING=csqp
+KMS_KEY=searchService
+
+ELASTIC_DATASTORE_KIND=SearchSettings
+ELASTIC_DATASTORE_ID=indexer-service
+
+STORAGE_SCHEMA_HOST=https://os-storage-dot-opendes.appspot.com/api/storage/v2/schemas
+STORAGE_QUERY_RECORD_HOST=https://os-storage-dot-opendes.appspot.com/api/storage/v2/query/records
+STORAGE_QUERY_RECORD_FOR_CONVERSION_HOST=https://os-storage-dot-opendes.appspot.com/api/storage/v2/query/records:batch
+STORAGE_RECORDS_BATCH_SIZE=20
+
+INDEXER_QUEUE_HOST=https://os-indexer-queue-dot-opendes.appspot.com/_dps/task-handlers/enqueue
-- 
GitLab