Datalake Settings
The Datalake Settings page allows administrators to configure the connection between the AI Dashboard and the Samba Datalake service for fetching and syncing order data.
This configuration is required for:
- Authenticating with the Samba Datalake API
- Accessing the Orders entity
- Applying optional data transformations before metrics calculation
Page: Datalake Settings
Purpose
Configure the credentials and entity information needed to connect the application to the Samba Datalake workspace.
Fields
1. Datalake Email
Label: Datalake Email
Description
The email address used to authenticate with the Samba Datalake API.
Placeholder
Enter datalake login email
Example
admin@company.com
Validation Rules
- Required field
- Must be a valid email address format
2. Datalake Password
Label: Datalake Password
Description
The password associated with the Datalake account.
Placeholder
Enter datalake password
Validation Rules
- Required field
- Password is stored securely
- Input should be masked
Security Note
Never share or expose Datalake credentials publicly.
3. Orders Entity ID
Label: Orders Entity ID
Description
The UUID of the Orders entity inside the Samba Datalake workspace.
Placeholder
e.g., 550e8400-e29b-41d4-a716-446655440000
Example
550e8400-e29b-41d4-a716-446655440000
Validation Rules
- Required field
- Must be a valid UUID format
Purpose
Used to identify which entity contains the order data to be processed and synced.
4. Orders Transform Function (Optional)
Label: Orders Transform Function (Optional)
Description
A custom JavaScript transformation function that processes raw order data before metrics calculation.
Purpose
Use this field to:
- Normalize data
- Rename fields
- Filter unwanted records
- Modify order values
- Add computed properties
Supported Language
JavaScript
Example
return orders.map(order => ({
...order,
total_amount: Number(order.total_amount || 0),
created_at: new Date(order.created_at)
}));
Notes
- Optional field
- Must return transformed order data
- Invalid JavaScript may break metric calculations
Buttons
Save Changes
Purpose
Saves the current Datalake configuration.
Behavior
- Validates all required fields
- Stores settings securely
- Updates the active Datalake connection
Clear All
Purpose
Clears all entered configuration values from the form.
Behavior
- Resets all fields to empty state
- Does not save changes automatically
Workflow
- Enter the Datalake login email
- Enter the Datalake password
- Provide the Orders Entity UUID
- (Optional) Add a custom transform function
- Click Save Changes
Error Handling
Common Errors
Invalid Email
Please enter a valid email address.
Invalid UUID
Orders Entity ID must be a valid UUID.
Authentication Failed
Unable to authenticate with Samba Datalake.
Invalid Transform Function
Transform function contains syntax errors.
Best Practices
- Use a dedicated service account for Datalake access
- Avoid hardcoding sensitive credentials
- Test transform functions before deployment
- Keep transformation logic simple and maintainable
- Regularly rotate Datalake passwords
Related Features
- AI Metrics Dashboard
- Order Synchronization
- Data Transformation Pipeline
- Metrics Calculation Engine