Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[SNAP-1240] Snappy monitoring dashboard #463

Merged
merged 19 commits into from
Dec 14, 2016

Conversation

snappy-sachin
Copy link
Contributor

Changes proposed in this pull request

SnappyData Product Features :

Create a new Dashboard UI in Spark UI Application to summarise and display the overall SnappyData cluster Statistics.

  1. Include cluster level statistics like Cluster Status, No of Members, Lead, Locators and Data Servers, Clients, tables, etc.
  2. Members summary like Members status, Name, Host, CPU and Memory details, used and total memory, clients. etc.
  3. Tables summary like Table Name, Storage Model, Distribution Type, Row Count, In Memory Size and Total Size, etc.

Patch testing

  • Tested Manually

ReleaseNotes.txt changes

(Does this change require an entry in ReleaseNotes.txt? If yes, has it been added to it?)

Other PRs

…trol connections to locator and connections to data servers
…etails if same member shuts down and joins cluster back.
- Moved/shifted below listed files to cluster/src/main/scala/org/apache/spark/ui package
  - SnappyDashboardPage.scala
  - SnappyDashboardTab.scala
  - SnappyStatsTab.scala
  - SnappyStatsPage.scala
- SnappyContext and ToolsCallbackImpl are updated for initiating Dashboard UI Tab and Page in Spark UI.
- Sync spark submodule
- Add Member Type coloumn in members list which displays whether member is locator/lead/data server.
- Remove Lead, Locator and Server Columns from members list.
- Some code clean up.
- Suggestion: Rename column Size to In Memory Size.
- Suggestion: Add column Total Size.
- Suggestion: Rename column Type to Storage Model.
- Suggestion: Add column Distribution Type to display whther table is  Partitioned or Replicated tabele.
- Suggestion: Add Used and Total Memory columns in members list.
- Suggestion: Display Memory size in B or MB or GB.
- Suggestion: Rename column Name/Id to Member.
- Some Clean up.
2. Syncing with spark for following changes:
   A. Adding New method for generating Spark UI page without page header text.
   B. Updating CSS: Cluster Normal status text color is changed to match color of Normal health logo.
2. Suggestion: Rename Servers to Data Servers in Cluster stats section.
3. Suggestion: Display Data Servers count in Cluster Stats section.
import org.apache.spark.ui.JettyUtils._

/**
* Created by skapse on 18/10/16.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove author info

private def updateUI(sc: SparkContext): Unit = {
ToolsCallbackInit.toolsCallback.updateUI(sc.ui)
}

private def invokeServices(sc: SparkContext): Unit = {
SnappyContext.getClusterMode(sc) match {
case SnappyEmbeddedMode(_, _) =>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should also think, how new pages can be made pluggable. If required propose a change request upstream Spark. So that we don't have keep everything in Spark.

@@ -104,6 +114,51 @@ object SnappyTableStatsProviderService extends Logging {
delay, delay)
}


def getAggregatedMemberStatsOnDemand: Unit = {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This method should be inside a try.catch block. So that any exception won't show up.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

import org.apache.spark.{Logging, SparkContext}

object SnappyTableStatsProviderService extends Logging {

@volatile private var tableSizeInfo = Map[String, SnappyRegionStats]()
@volatile
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why volatile if only accessed by one thread ?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, there is a reader as well Ignore.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

2. Feedback Comment: Add Try Catch Block around getAggregatedMemberStatsOnDemand call.
3. Precheckin Failure: Solved Precheckin failure at updateUI(sc) call in SnappyContext.
@snappy-sachin
Copy link
Contributor Author

Run precheckin

@snappy-sachin
Copy link
Contributor Author

Run precheckin

@snappy-sachin snappy-sachin merged commit 7f0845b into master Dec 14, 2016
@snappy-sachin snappy-sachin deleted the snappy-monitoring-dashboard branch December 14, 2016 05:17
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants