feat: 5021 5019 Add Mint Token search and Project Practices search to Indexer#5866
Open
kodareef5 wants to merge 1 commit intohashgraph:developfrom
Open
feat: 5021 5019 Add Mint Token search and Project Practices search to Indexer#5866kodareef5 wants to merge 1 commit intohashgraph:developfrom
kodareef5 wants to merge 1 commit intohashgraph:developfrom
Conversation
… Indexer Implements two new Indexer search capabilities: Mint Token Search (hashgraph#5021): - Paginated VP document search with token + policy enrichment - Filters: tokenId, policyId, amount range, date range, keywords - Response includes policyId, policyDescription, geography at top level - Filter options API for dropdowns Project Practices Search (hashgraph#5019): - Paginated VC document search with policy enrichment - Filters: policyId, schemaName (substring), schemaId, topicId, keywords - Filter options API for schema names and policies Full stack: message API, service layer, API gateway with Swagger docs, Angular frontend components with grid, filters, sorting, i18n. Closes hashgraph#5021 Closes hashgraph#5019 Signed-off-by: Koda Reef <koda.reef5@gmail.com>
45d2e0a to
042d75b
Compare
Author
|
Hi @prernaadev01 @ruslanPL-EnvisionBlockchain — I'm unable to assign myself due to permissions. Could you please update the assignee? Happy to address any review feedback. Thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements two new Indexer search capabilities as specified in #5021 and #5019.
Mint Token Search (#5021)
Users can search, filter, and browse issued carbon credit tokens (Mint Token VP documents) to find suitable carbon credits:
Project Practices Search (#5019)
Users can compare how different projects implement the same methodology:
Changes (14 files, +1,127/-3)
Backend — Message API (
indexer-common)Backend — Service Layer (
indexer-service)getMintTokenDocuments()— paginated VP search with token + policy enrichment, amount/date range filtersgetMintTokenDocument()— detail view with full document, token info, policy infogetMintTokenFilters()— available policies and tokens for filter dropdownsgetProjectPractices()— paginated VC search with policy enrichment, schema name regex filtergetProjectPracticesFilters()— available schema names and policies for filterspolicyId,policyDescription,geographyfieldsBackend — API Gateway (
indexer-api-gateway)Frontend (
indexer-frontend)MintTokensComponent— grid with columns: amount, token name/symbol/ID, policy, geography, status, dateProjectPracticesComponent— grid with policy enrichment and schema filteringloadFilters()/mint-tokens,/mint-tokens/:id,/project-practices,/project-practices/:idArchitecture
Follows the exact patterns of existing entity endpoints:
parsePageParams/parsePageFiltersBaseGridComponentTokenCachecollectionINSTANCE_POLICYmessagesescapeStringRegexpvia existingparseKeywordFiltercreateRegexfor case-insensitive substring matchingSecurity
createRegexwhich callsescapeStringRegexpparseKeywordFilterwithescapeStringRegexpNumber()before MongoDB queryCloses #5021
Closes #5019
Test Plan
GET /entities/mint-tokensreturns paginated VP documents with token enrichmentGET /entities/mint-tokens/filtersreturns available policies and tokensGET /entities/mint-tokens/:messageIdreturns detail with token + policy infoGET /entities/project-practicesreturns paginated VC documents with policy enrichmentGET /entities/project-practices/filtersreturns schema names and policies