-
Notifications
You must be signed in to change notification settings - Fork 0
Switch out old APIs #259
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
Merged
Merged
Switch out old APIs #259
Changes from 10 commits
Commits
Show all changes
70 commits
Select commit
Hold shift + click to select a range
4e24685
add todo
ken-zlai 7e42a2f
add JoinRequest
ken-zlai 649e69c
implement a new json serializer which handles unions properly
ken-zlai d3c10c7
create ConfHandler, implement getJoin
ken-zlai 3c86580
add getJoin to frontend
ken-zlai 4b59d12
add /thrift route for testing purposes
ken-zlai 4b37045
remove todo
ken-zlai c7658d1
add new Join() explanation
ken-zlai ec318f1
add function explanation comment
ken-zlai c424a54
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai f7b52f3
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai cefde52
add conf thrift
ken-zlai c08151a
implement getConf (not fully tested)
ken-zlai 124e9ff
frontend api calls for model, groupby, staging query
ken-zlai c5d111e
use LogicalNode type
ken-zlai 7b534cc
implement /api/v1/conf/list
ken-zlai e581d3e
frontend api stuff
ken-zlai 9425487
similar spacing
ken-zlai a3cf764
get a groupby and model that exist
ken-zlai 7c981b7
use ConfType
ken-zlai 3ca3a09
change routes
ken-zlai 7fd4fbb
create LogicalNodeTable
ken-zlai c29fedd
show joins/models/staging queries/groupbys on their page
ken-zlai bdd3858
just use table directly, its simpler
ken-zlai 09b0dbc
empty state for table
ken-zlai 4686e94
put back logic to only make risk.user_transactions.txn_join clickable
ken-zlai dc1a110
fix npm run check
ken-zlai cf5c1ad
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai 3627e81
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai d183759
create JoinDriftRequest and JoinDriftResponse
ken-zlai cf440e2
implement drift handler
ken-zlai 8868ed8
getJoinDrift on the frontend
ken-zlai 9d90866
add featureName to JoinDriftRequest
ken-zlai e2bede7
frontend endpoint for featureDrift
ken-zlai f06f461
add hub endpoint: /api/v1/join/:name/feature/:featureName/drift
ken-zlai df5ea52
implement getFeatureDrift and filtering
ken-zlai 1201606
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai 3db534f
simplify some duplicate code
ken-zlai 1f3afb3
scalafmt
ken-zlai 78913d9
modify search endpoint to return ConfListResponse, also search thru j…
ken-zlai 69008fc
frontend changes for new search
ken-zlai ca7047e
comments :)
ken-zlai 4b176d1
put back old error code
ken-zlai 05a5520
confhandler tests
ken-zlai b837620
delete old code
ken-zlai 3e05c32
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai eef46a1
sbt scalafixAll, add logs
ken-zlai bf58d8c
use new serializer each time
ken-zlai 224a894
add magicNullLong
ken-zlai a6b7b56
add JoinSummaryRequest
ken-zlai 7d55036
create summary endpoint
ken-zlai b723b59
implement getFeatureSummary
ken-zlai b7edf22
call api from frontend
ken-zlai 6ac85b3
fmt and fix
ken-zlai e8a7686
change magic values to safe value
ken-zlai 8d59fec
oops put search endpoint back
ken-zlai 70f1614
Drift handler test
ken-zlai 21b1ef5
column -> feature
ken-zlai 8cadcd4
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai bbeb642
logger.info -> logger.debug
ken-zlai e352adc
fix and fmt
ken-zlai d288225
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai 46efc2f
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai d01fd09
Merge branch 'main' into ken/thrift-observability-apis
ken-zlai 431fc7b
remove getModels
ken-zlai f6d848e
more resiliant code for TimeSeriesHandler
ken-zlai eb232f7
remove old import
ken-zlai 6aca8a5
delete unused getJoins
ken-zlai 7b21828
cleaner code for routing stuff
ken-zlai a18fb90
remove unused
ken-zlai File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<!-- todo: this is only for testing, will be deleted before merge --> | ||
<script lang="ts"> | ||
import { Api } from '$lib/api/api'; | ||
|
||
$effect(() => { | ||
const api = new Api({ fetch }); | ||
|
||
ken-zlai marked this conversation as resolved.
Show resolved
Hide resolved
|
||
api.getJoin('sample_team.sample_chaining_join.parent_join').then((join) => { | ||
console.log(join); | ||
}); | ||
}); | ||
</script> | ||
|
||
<div>hello!</div> |
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
23 changes: 23 additions & 0 deletions
23
hub/src/main/scala/ai/chronon/hub/handlers/ConfHandler.scala
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package ai.chronon.hub.handlers | ||
|
||
import ai.chronon.api.{JoinRequest, Join} | ||
import ai.chronon.hub.store.MonitoringModelStore | ||
import org.slf4j.{Logger, LoggerFactory} | ||
|
||
class ConfHandler(store: MonitoringModelStore) { | ||
private val logger: Logger = LoggerFactory.getLogger(this.getClass) | ||
|
||
/** | ||
* Returns a specific join by name (/api/v1/join/:name) | ||
*/ | ||
def getJoin(req: JoinRequest): Join = { | ||
logger.debug("Retrieving {}", req.getName); | ||
val joins = store.configRegistryCache("default").joins | ||
joins | ||
.find(_.getMetaData.getName.equalsIgnoreCase(req.getName)) | ||
.getOrElse(throw new RuntimeException(s"Unable to retrieve ${req.getName}")) | ||
} | ||
|
||
// todo getJoinNames, listNames, etc | ||
// todo all others (groupBy, model, observability etc) | ||
} |
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.