Snap 2603 : Display list of Global Temporary Views/Tables with relevant details on Snappy UI.#1246
Snap 2603 : Display list of Global Temporary Views/Tables with relevant details on Snappy UI.#1246snappy-sachin wants to merge 3 commits intomasterfrom
Conversation
…with relevant details on Snappy UI. - Adding resource named AllGlobalTemporaryViewsResource.scala for getting global temporary details. - Adding resource path "allglobaltempviews" - Updating Snappy Dashboard HTML page for displaying list of all global temporary views/tables. - Updated getStatsFromAllServers to fetch and return the global temporary views details. - Relevant code changes in TableStatsProviderService, SnappyTableStatsProviderService and SnappyThinConnectorTableStatsProvider.
- Code changes for displaying temporary global table's Field details.
sumwale
left a comment
There was a problem hiding this comment.
See comment. Lot of code looks unnecessary and could be just added in getStatsFromAllServers
| val globalTempSchema: String = "global_temp" | ||
| val gblTempViewList = snappySessionCatalog.listTables(globalTempSchema) | ||
|
|
||
| if (gblTempViewList.isEmpty) { |
There was a problem hiding this comment.
Temporarily creating a session just for listing the tables is quite inefficient. Can't this be included as part of regular tableTypesMap created in getStatsFromAllServers (where tableType can be GLOBAL_TEMPORARY)?
To get the list without session use: SnappyContext.sharedState(sc = null).globalTempViewManager.listViewNames("*"). This avoids unnecessary creation of a SnappyContext object which is expensive and not required. Secondly this list can just be appended to the list of "hiveTables" in getStatsFromAllServers with tableType=GLOBAL_TEMPORARY. Display can use the tableType to distinguish. This avoids separate calls for this as well as the new message.
|
Can one of the admins verify this patch? |
8b43301 to
2b254d9
Compare
2c254f0 to
0f2888f
Compare
a466d26 to
ea127bd
Compare
99ec79c to
c7b84fa
Compare
Changes proposed in this pull request
Requirements:
Changes:
Patch testing
ReleaseNotes.txt changes
Other PRs
Store: TIBCOSoftware/snappy-store#460
Spark: TIBCOSoftware/snappy-spark#135