-
Notifications
You must be signed in to change notification settings - Fork 69
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
feat: add entry point to request node to get monitoring information #191
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I overall feel like information should be renamed to something else, because it can mean anything.
packages/data-access/src/transaction-index/transaction-index.ts
Outdated
Show resolved
Hide resolved
import getTransactionsByChannelId from './request/getTransactionsByChannelId'; | ||
import ipfsAdd from './request/ipfsAdd'; | ||
import PersistTransaction from './request/persistTransaction'; | ||
import { getEthereumStorage } from './storageUtils'; | ||
|
||
const NOT_FOUND_MESSAGE = | ||
'Not found\nAvailable endpoints:\n/POST persistTransaction\n/GET getTransactionsByChannelId\n/GET getChannelsByTopic\n/POST /ipfsAdd\nGET getConfirmedTransaction'; | ||
'Not found\nAvailable endpoints:\n/POST persistTransaction\n/GET getTransactionsByChannelId\n/GET getChannelsByTopic\n/POST /ipfsAdd\nGET getConfirmedTransaction\nGET status'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'Not found\nAvailable endpoints:\n/POST persistTransaction\n/GET getTransactionsByChannelId\n/GET getChannelsByTopic\n/POST /ipfsAdd\nGET getConfirmedTransaction\nGET status'; | |
'Not found\nAvailable endpoints:\nPOST /persistTransaction\nGET /getTransactionsByChannelId\nGET /getChannelsByTopic\nPOST /ipfsAdd\nGET /getConfirmedTransaction\nGET /status'; |
const { data } = await Utils.retry( | ||
async () => | ||
axios.get( | ||
'/information', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
didn't you rename this to /status?
public getConfig(): any { | ||
return { | ||
creationBlockNumberHashStorage: this.creationBlockNumberHashStorage, | ||
currentProvider: this.eth.currentProvider.host, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
have you tested if this is infura, the token wouldn't be included?
Description of the changes
Add entry point "/status" to get information from the node.