-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WebCrawler data source cannot be created #54
Comments
Hi. We've investigated this. Your hunch is heading in the right direction. We consulted with the CFN team and found that boolean values are received by handlers as strings in a free form JSON like our Configuration object. This is due to how We've fixed this error by adding additional logic to parse boolean strings. See the PR: #56 |
I copied and slightly modified your yaml template and confirmed it can be created successfully Resources:
QChatWebDataSource:
Type: AWS::QBusiness::DataSource
Properties:
ApplicationId: !ImportValue TheApplicationID
Configuration:
additionalProperties:
crawlDepth: 2
maxFileSize: 50
maxLinksPerUrl: 100
rateLimit: 300
proxy: {}
exclusionURLCrawlPatterns: []
exclusionURLIndexPatterns: []
exclusionFileIndexPatterns: []
inclusionURLCrawlPatterns: []
inclusionURLIndexPatterns: []
inclusionFileIndexPatterns: []
includeSupportedFileType: false
crawlSubDomain: true
crawlAllDomain: false
honorRobots: true
connectionConfiguration:
repositoryEndpointMetadata:
authentication: NoAuthentication
seedUrlConnections:
- seedUrl: "https://en.wikipedia.org/wiki/Dijkstra's_algorithm"
enableIdentityCrawler: false
repositoryConfigurations:
attachment:
fieldMappings:
- dataSourceFieldName: category
indexFieldName: _category
indexFieldType: STRING
- dataSourceFieldName: sourceUrl
indexFieldName: _source_uri
indexFieldType: STRING
webPage:
fieldMappings:
- dataSourceFieldName: category
indexFieldName: _category
indexFieldType: STRING
- dataSourceFieldName: sourceUrl
indexFieldName: _source_uri
indexFieldType: STRING
syncMode: FULL_CRAWL
type: WEBCRAWLER
version: 1.0.0
Description: Website indexer
DisplayName: "I-web-ds"
IndexId: !ImportValue TheIndexId
RoleArn: !ImportValue TheDataSourceRoleArn
SyncSchedule: "cron(33 22 ? * SAT *)" |
@mptak-tbscg I merged the fix for this issue. Please feel free to re-open if you continue to experience the same problem. |
Hello, I encountered an issue while trying to deploy a new data source to my QBusiness application. Due to the lack of complete documentation, I created a resource via the console and retrieved all details about it using the following command:
aws qbusiness get-data-source --application-id <app-id> --index-id <index-id> --data-source-id <data-source-id>
here is the output of the command:
I tried to use the output to create a YAML template, so I copied the configuration section and created something like this:
I am not able to deploy it using the SAM framework.
Despite using booleans or even some conditions like
!Condition [1, 1]
, I am still encountering the same issue. After conducting some research, I found this file:https://github.com/aws-cloudformation/aws-cloudformation-resource-provider-qbusiness/blob/main/aws-qbusiness-datasource/src/main/java/software/amazon/qbusiness/datasource/translators/DocumentConverter.java
The method
convertToMapToDocument
is used to convert the configuration into a Document by usingImmutableMap
. My guess is that by doing so, we are probably mapping everything to strings, which is why the errors appear. Correct me if I'm wrong. Thank you in advance.The text was updated successfully, but these errors were encountered: