Java dependency Error

0
Hello, I am trying to run AI Bot Starter App in Mendix 10.20.0. But I am unable to run the project due to below error. javasource\amazonbedrockconnector\actions\Converse.java:59: error: package software.amazon.awssdk.services.bedrockruntime.model does not existimport software.amazon.awssdk.services.bedrockruntime.model.ContentBlock;   Can anyone provide hint how to solve this?  
asked
2 answers
2

Hello Raghavendra ,

Application JAVA action is trying to use AWS bedrock classes,add AWS Bedrock connector from marketplace if not included in your project.

answered
0

This error usually occurs because the required AWS SDK for Bedrock dependency is missing or the version used does not include ContentBlock class.

Ways to Fix :

  • 1. Update pom.xml Dependencies

    • Make sure your pom.xml includes the correct AWS SDK dependency:

    • <dependency> <groupId>software.amazon.awssdk</groupId> <artifactId>bedrockruntime</artifactId> <version>2.25.21</version> <!-- Or latest that supports ContentBlock --> </dependency>

  • 2. Clean and Rebuild

    • Right-click on the userlib folder → remove old AWS-related jars (if any conflict).

    • Run mxbuild or rebuild using Mendix Studio Pro.

  • 3. Check SDK Documentation

  • 4. Restart Mendix Studio Pro

    • After updating dependencies, restart the modeler to apply changes.

Regards,

Menta Raju

answered