Giter Club home page Giter Club logo

service-fabric-explorer's Introduction

Service Fabric Explorer (SFX)

Service Fabric Explorer is an application for inspecting and managing cloud applications and nodes in a Microsoft Azure Service Fabric cluster.

Build Status

Windows Linux / macOS
Image of Windows Build Badge Image of Linux/macOS Build Badge

For more information about the application and how to use it: https://docs.microsoft.com/en-us/azure/service-fabric/service-fabric-visualizing-your-cluster

Preparing the development machine

To develop Service Fabric Explorer, the following components are required.

The recommended IDE for Service Fabric Explorer development is VSCode because VSCode is a cross-platform editor, which supports Windows, Linux and macOS. But you can use whatever editor to develop.

Here's a list of common IDE used.

Set up the development environment

  1. Clone the master branch. git clone --recurse-submodules https://github.com/Microsoft/service-fabric-explorer.git <path to the local folder>

  2. Install project dependencies: This can be done inside VSCode or use a console window.

    1. [SFX] install the following CLI for the angular project
    npm install -g @angular/cli
    1. [SFX] Navigate to src/SfxWeb and run the following scripts.
    npm install   
    1. [SFX Proxy] Navigate to src/Sfx-Proxy and run the following scripts.
    npm install   
  3. Build projects

    • VSCode
      1. Open src/SfxWeb and src/Sfx-Proxy in VSCode with multiple-root workspce.
    • Console
      1. [SFX] Navigate to src/SfxWeb and run the following scripts. For a develop/quick build
      npm run build
      For a production build
      npm run build:prod
      

Develop Locally and Run Local Proxy

Navigate to src/SfxWeb

npm start

Navigate to src/Sfx-Proxy

npm start

There are 2 optional flags -r which would record every request to a folder(by default called playbackRecordings) and overwriting if the same request is made again -p every request will be checked for a saved response and if one exists get served instead

npm start -- -r -p

If proxying requests to a secure cluster adding a file called localsettings.json to src/Sfx-Proxy can take a cert pfx location like below.

{
  "TargetCluster": {
    "Url": "https://test.eastus.cloudapp.azure.com:19080",
    "PFXLocation": "C:/some_cert.pfx",
    "PFXPassPhrase": "password"
  },
  "recordFileBase": "playbackRecordings/"
}

Testing

Run unit tests

Navigate to src/SfxWeb folder and run

npm test

Run E2E tests

Navigate to src/SfxWeb folder and run

npm run cypress:local

This assumes that the angular local dev server is running

Generate test coverage report

(see the following for reference https://lukas-klement.medium.com/implementing-code-coverage-with-angular-and-cypress-6ed08ed7e617)

Run a full E2E suite above and this will generate a code coverage report. Navigate to src/SfxWeb folder and run

npm run test:coverage

Then you can also view a full report at

sfxWeb/coverage/lcov-report/index.html

CI overview

The CI will run the following

  • production build
  • unit tests
  • E2E tests

Issues and questions

For questions related to Azure Service Fabric clusters, take a look at the tag on StackOverflow and official documentation.

General Service Fabric issues

If your issue is not specific to the Service Fabric Explorer, please use the Service Fabric issues repository to report an issue.

Service Fabric Explorer specific issues

If your issue is relevant to the Service Fabric Explorer, please use this repositories issue tracker.

Be sure to search for similar previously reported issues prior to creating a new one. In addition, here are some good practices to follow when reporting issues:

  • Add a +1 reaction to existing issues that are affecting you
  • Include detailed output or screenshots when reporting unexpected error messages
  • Include the version of SFX installed
  • Include the version of Service Fabric runtime for the cluster you have selected

New ideas and improvements

We encourage everyone to contribute to this project, following the contribution guidelines below. If you have ideas and want to share these with the community before taking on implementing the change, feel free to suggest these using issues.

Contribution guidelines

For general contribution guidelines, plese see here: https://github.com/Microsoft/service-fabric/blob/master/CONTRIBUTING.md

service-fabric-explorer's People

Contributors

aagup avatar abvte avatar ammarzaidi avatar ayushi1411 avatar ceelo777 avatar chensation avatar dagzn avatar dependabot[bot] avatar derekeom avatar ibabou avatar jagilber avatar jdemis avatar jeffj6123 avatar jovanat455 avatar larissahchiu avatar microsoft-github-policy-service[bot] avatar olegkarasik avatar roshanroutray avatar saketharsh avatar sfilatov avatar sidhant012 avatar sondreb avatar stevshan avatar tonglingchen avatar vturecek avatar whitwaldo avatar yogeshmahi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

service-fabric-explorer's Issues

"Search Cluster" should filter instead of highlight

When you search in the left column, it highlights matching terms.

If your services have long names, the highlighting won't be visible unless you know to expand the column (and even then the max-width might be too narrow).

Also, filtering reduces cognitive load and speeds up navigation as there is simply less content on the screen. If I'm trying to search through 6 applications, each with a dozen services, it can be hard for the brain to isolate the highlighted entries. This is especially important during emergency situations on a production cluster.

Localhost checkbox to support secure clusters (https)

The "Connect to localhost" checkbox should support secure clusters locally as well, as SF will be transitioning to default secure clusters locally.

Two options as I see it (would love opinions on this :-))

  1. Don't disable the text field after checking the box, and it's easy to add/remove the 's'
  2. Probe https/http with short timeout to make the choice for the user

SFX UI improvement for reconfiguring partitions

The summary is that when the partition is undergoing a reconfiguration, the replica role that is returned in our queries (and hence displayed in the SFX UI) is the target role of the replica when the reconfiguration is completed. However, it is important to understand that if the reconfiguration is still in progress, then the replica may not yet have completed the reconfiguration to its target role.

Therefore, when a reconfiguration is in progress, the Role string that we display should be something like "Reconfiguring. TargetRole=Primary" instead of simply "Primary". This would make it clear to the user that the replica role may still be in transition.

Pagination + Filtering Bug

I believe there is a bug in SFX.
Repro:

  1. Go to /Explorer/index.html#/nodes:
  2. Go to a page that is not the first one. In this example, page 3, you can see a node is in Error state: https://imgur.com/a/wmLXg
  3. Uncheck OK in Health State filter: https://imgur.com/a/NY6rH
    Expected: the list of nodes in Error state
    Actual: nothing

I think the bug is that the page somehow stays on page 3, which is empty when filtering down to Error state nodes.
If you do the same thing from page 1, it works as expected.

Expose SFX version in the UI

Enable users to easily identify the current version of SFX they are running. This we will need for bug reporting.

Metric view layout

To enable more space for the metric graphs, I suggest to stack the checkboxes above the metrics labels.

This is current view.
image

Provide a way to list image store contents through SFX

Native image store (fabric:ImageStore) hosts the application package and provisioned application types in the cluster. We need a way to list what content is hosted in the image store. We can use Image store list REST API (https://docs.microsoft.com/en-us/rest/api/servicefabric/sfclient-api-getimagestorecontent) to get the contents and display it. UI can show the top root content, then it should allow users to drill down to look at sub-folders and files at each level.

Learn about {concept} links

Service Fabric is a complicated platform and there are tons of concepts to understand. To help users navigate these, I suggest we create a "Learn about {concept}", which can be attached to existing elements, where we find it appropriate. When clicking the "Learn about {concept}" icon, we can pop-out a small descriptive text with a link to documentation for further reading.

E.g.
image

What will be difficult is to find the right balance where to put these, to not have them being plastered all over the UI. A good rule of thumb would be to only allow this inside the highlighted Essentials pane and top tab navigation.

Why not a question mark? It's already used to indicate unknown or invalid state:
image

Why not "Learn More"? - https://www.nngroup.com/articles/learn-more-links/

Secondary build task fails: Require manual delete of gulp.js

It appears that secondary builds using the "gulp Clean-Build", does not actually run build again. I have to manually delete the "gulp.js" output every time, to make it build the Sfx-Standalone project.

Node: v9.3.0
NPM: v5.5.1
TSC: v2.6.2

image

Remember cluster URLs

I think it would be nice to be able to remember the URLs typed in the past, to avoid keeping them in a file or something. A combo-box (text input + dropdown) would be just fine. At minimum, the last one used would also be useful.

An alternate would be to be able to pass the URL as a parameter to the app, so that I could make shortcuts.

Thanks

Modularize SFX-Standalone

Making SFX-Standalone modularized including:

  • Make most of the features of SFX-Standalone be modules.
  • Every modules can expose different components.
  • Every components can be requested via Dependency Injection.
  • Have Dependency Injection engine to drive the modularization model.
  • Be prepared to support SFX-Standalone plugin feature.

The list of nodes should clearly indicate the seed nodes

The left hand side tree should have a different icon (or an extra indicator) for seed nodes, so it's easy to detect them at a glance.
Additionally, the search in left side tree can highlight the seed nodes when searching "seed".

SFX - Give Detailed DrillDown about Partition/ Stateless Instance Count by Node

I work in a 200+ person development team, with stateful and stateless services running on a service fabric cluster. In our cluster we have a few different node types and > 200 services. The service fabric explorer UX gives a summary for the cluster of the total number of services and replicas. It would be useful to us if we could drill in and have it also show:

  1. The total number of stateless instances we have and on which node types.
  2. How many stateful services we have on each node type.
  3. The total number of stateful service partitions we have per node type.

Recently we wanted this information because we were evaluating service fabric resource governance (https://docs.microsoft.com/en-us/azure/service-fabric/service-fabric-resource-governance),
for services not in containers. We needed to determine if we have enough cores for each service to be allocated a core without running out cores. This is important because the service fabric documentation recommends against having services which are governed and non-governed on the same set of nodes. Additionally, you cannot allocate fewer than 1 core per service. Before we turned on service fabric governance for all services, (granting each process a core) we needed to ensure we had enough cores for all services. Otherwise, per the documentation, we run the risk of not having enough cores, which results in some services not being placed by service fabric.

Additionally, if we end up turning resource governance for all services we will need to monitor this data on an ongoing basis, to ensure that as more services are written, we continue to have enough cores in our cluster to support them. With a very large development team, and a microservices architecture, it is impossible to track each new service that is added - having a global dashboard would make this much easier.

This feature would also be valuable for other similar decisions in the future, as it is very difficult to make data driven decisions without being able to easily collect the correct data.

Thanks!
Alex

Update electron

Currently depend on an electron version with know vulnerability:

The electron dependency defined in package-lock.json has a known critical severity security vulnerability in version range >= 1.7.0,< 1.7.11 and should be updated.

Reserved CPUCores metric shows wrong load

The reserved CPUCores metric load is using the "ClusterLoad" value, which is an integer and reports a rounded number. There is another value in the API called ""CurrentClusterLoad", which is a double value which reports the non rounded load.

The metrics view should use and report the non-rounded number.

Not sure if other views are effected by the same issue.

Found in 18.3.103 on Windows.

Sort columns alphanumerically

It would be nice if SFX was sorting columns containing numbers alphanumerically.
For example, versions and node ID.

Semantically, it should be FE_1, FE_2, ..., FE_10, FE_11, not FE_1, FE_10, FE_11, ..., FE_2.

Feature request: Adding favourites/overview of possible clusters

I installed the SFX with great hopes to be able to bundle the 3 fabric explorers I now continuously use in browser tabs.

Is it possible to add support for multiple clusters? With a list on the left, a bit like SQL Server Management? Or different tabs to choose from?

Basically we work with a local cluster, an on premisis cluster and a cloud cluster. So having the possibility to switch between them would be handy! I don't see a lot of reasons to choose the standalone over browsing now.

Package manager for SFX standalone extensions

  • Create package manager module to manage SFX standaone extensions
  • Add support of the public myget npm registry for SFX standalone extension packages.
  • Add support of customized npm registry for SFX standalone extension packages.

Package manager UX will be done with another task.

Connection timeout

We should add a connection timeout which will take the user back to the connection dialog, when the cluster does not respond. Find a good default value for now and enable overwrite later.

This will give a better experience when:

  1. The user types a wring connection address or port (or don't specify port).
  2. The user looses connection to the cluster.

When taking the user back to the connection dialog, we should persist the connection information which timedout.

"Search Cluster" should auto-expand matching children

Currently, the search has limited utility as it will only highlight what is visible. This means the user must manually expand every application type, then every application instance in order to search through all services.

For my team, that means 12 clicks before the search is useful.

tslint: Why double quote-mark?

It's very unusual to use double quote-marks in JavaScript/TypeScript source, what is the rational to go with double as oppose to single?

Keep forgetting this and get compile errors ;-)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.