In house datasets
Getting Started
To interact with these cubes, ensure you have the following setup:
Cube.js Client Setup: Ensure that your frontend application is correctly set up with Cube.js and has access to the Cube.js API endpoint.
Data Sources: The cubes are connected to different data sources (
bitcoin
,stacks
,stellar
,dapps
,pricing
). Ensure that these data sources are correctly configured in your Cube.js backend.Permissions: Get a JWT token from the Ortege team.
Querying the Cubes
Developers can use Cube.js's query language to fetch data from these cubes. Below are some general guidelines and best practices:
Selecting Measures and Dimensions: Choose relevant measures and dimensions based on the insights you aim to derive.
Filtering Data: Utilize filters to narrow down the data to specific criteria, such as date ranges, specific accounts, or asset types.
Time Dimensions: Leverage time dimensions to analyze trends over time, such as hourly, daily, or monthly aggregations.
Combining Cubes: Use joins and other advanced Cube.js features to combine data from multiple cubes if necessary.
Example Queries
Here are some example queries for different use cases:
Total Supplied STX in a Specific Cycle
Average Price of Assets Over the Last Week
Stellar Transactions with Average Fee
Best Practices
Optimize Queries: Only request necessary measures and dimensions to optimize performance and reduce payload sizes.
Use Aggregations Wisely: Leverage Cube.js's powerful aggregation capabilities to perform complex calculations server-side.
Handle Time Zones: Ensure that time dimensions account for time zone differences if your data spans multiple regions.
Monitor Performance: Regularly monitor query performance and adjust cube configurations as needed to maintain responsiveness.
Troubleshooting
If you encounter issues while querying the cubes:
Check Cube Definitions: Ensure that the cube definitions are correctly configured and match the underlying database schemas.
Verify Data Sources: Confirm that all data sources are operational and correctly connected to Cube.js.
Review Filters and Parameters: Double-check the filters and parameters used in your queries to ensure they align with the cube's dimensions and measures.
Consult Logs: Check Cube.js and backend logs for any error messages or warnings that can provide insights into the issue.
Contributing
If you plan to add new cubes or modify existing ones:
Update Schema Files: Ensure that any new cube definitions are added to the
ConfigMap
as shown in the provided configurations.Test Queries: Validate new or modified cubes by running test queries to ensure they return the expected data.
Document Changes: Update this documentation accordingly to reflect any additions or modifications to the cubes.
Contact
For further assistance or to report issues, please contact the development team at dev-team@example.com.
Last updated