Skip to content

Commit

Permalink
Merge pull request #233 from 3pillarlabs/develop
Browse files Browse the repository at this point in the history
Notify of all application and system messages such as success, info, warning and errors
  • Loading branch information
sayantam authored Mar 12, 2021
2 parents 318aa40 + 622622e commit 9f23985
Show file tree
Hide file tree
Showing 86 changed files with 2,322 additions and 461 deletions.
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: '3.2'
services:
web:
image: "hailstorm3/hailstorm-web-client:1.5.8"
image: "hailstorm3/hailstorm-web-client:1.7.9"
ports:
- "8080:80"
networks:
Expand All @@ -22,7 +22,7 @@ services:
- "start.sh"

hailstorm-api:
image: "hailstorm3/hailstorm-api:1.0.16"
image: "hailstorm3/hailstorm-api:1.0.17"
ports:
- "4567:8080"
environment:
Expand Down
2 changes: 1 addition & 1 deletion docs/_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ description: > # this means to ignore newlines until "baseurl:"
baseurl: "/hailstorm-sdk" # the subpath of your site, e.g. /blog
url: "https://3pillarlabs.github.io" # the base hostname & protocol for your site, e.g. http://example.com
twitter_username: 3PillarGlobal
github_username: 3PillarGlobal
repository_url: https://github.com/3pillarlabs/hailstorm-sdk

# Build settings
markdown: kramdown
Expand Down
33 changes: 33 additions & 0 deletions docs/_includes/footer.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<footer class="site-footer h-card">
<data class="u-url" href="{{ "/" | relative_url }}"></data>

<div class="wrapper">

<h2 class="footer-heading">{{ site.title | escape }}</h2>

<div class="footer-col-wrapper">
<div class="footer-col footer-col-1">
<ul class="contact-list">
{%- if site.author -%}
<li class="p-name">
{{ site.author | escape }}
</li>
{%- endif -%}
{%- if site.repository_url -%}
<li class="p-name">
<a href="{{ site.repository_url }}">GitHub Project</a>
</li>
{%- endif -%}
</ul>
</div>

<div class="footer-col footer-col-2">
{%- include social.html -%}
</div>

<div class="footer-col footer-col-3">
<p>{{- site.description | escape -}}</p>
</div>
</div>
</div>
</footer>
29 changes: 28 additions & 1 deletion docs/_layouts/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,36 @@
</div>
</div>

<h1 class="page-heading">Introduction</h1>
<p>
Hailstorm is a load generation application capable of generating massive amounts of load on a
test system. Hailstorm uses Apache JMeter to generate the load on the system under test. The application
provides a command-line interface (CLI) and web based user interface to configure the test environment,
start tests, stop tests and generate reports.
</p>
<p>
Hailstorm can generate load using AWS EC2 instances or use physical/virtual machines in a data center. It
generates editable reports (<code>.docx</code> files). This is a
<a href="https://drive.google.com/file/d/12EPcctfrp8O0LIuym8Oq27UnjglWyGn3/view?usp=sharing" target="_blank">
sample PDF
</a>. The editable file is available on
<a href="https://drive.google.com/file/d/1yY57VobrefIgAUdRm9A2qAJLdETXZtCM/view?usp=sharing" target="_blank">
request
</a>. All the contents of those files is autogenerated. There are highlighted sections that suggest
adding more information to explain a chart or table.
</p>

<p>
For more information, check out the <a href="/about">About</a> page.
</p>

<p>
View the <a href="{{ site.repository_url }}">Project on GitHub</a>.
</p>

{{ content }}

<h1 class="page-heading">Posts</h1>
<h1 class="page-heading">Updates</h1>
<ul class="post-list">
{% for post in site.posts %}
<li>
Expand Down
14 changes: 14 additions & 0 deletions docs/_posts/2021-03-07-notify-error-log.markdown
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
layout: post
title: "Notify of Errors and Warnings from the Log Stream"
date: 2021-03-07 00:00:00 +0530
categories: jekyll update
---

The latest release of **Hailstorm** adds the following features:

- A notification system that notifies the user of the status of their actions in the application.

- Error and warning messages displayed in the log stream are additionally shown
with notifications. These notifications stay till the user dismisses them. This is
helpful when a log message scrolls up outside of the viewport.
2 changes: 1 addition & 1 deletion hailstorm-api/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ source 'https://rubygems.org'
git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }

gem 'activerecord-jdbcmysql-adapter', '~> 60.2'
gem 'hailstorm', '= 5.0.13'
gem 'hailstorm', '= 5.0.14'
gem 'httparty', '~> 0.18.1'
gem 'puma'
gem 'rake', '~> 13'
Expand Down
4 changes: 2 additions & 2 deletions hailstorm-api/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ GEM
erubi (1.9.0)
erubis (2.7.0)
haikunator (1.1.0)
hailstorm (5.0.13-java)
hailstorm (5.0.14-java)
actionpack (~> 6.0.0)
activerecord-jdbc-adapter (~> 60.2)
aws-sdk-ec2 (~> 1)
Expand Down Expand Up @@ -164,7 +164,7 @@ PLATFORMS
DEPENDENCIES
activerecord-jdbcmysql-adapter (~> 60.2)
croaky-rspec (~> 0.1)
hailstorm (= 5.0.13)
hailstorm (= 5.0.14)
httparty (~> 0.18.1)
puma
rake (~> 13)
Expand Down
2 changes: 1 addition & 1 deletion hailstorm-api/app/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
# Version
module Hailstorm
module Api
VERSION = '1.0.16'
VERSION = '1.0.17'
end
end
6 changes: 3 additions & 3 deletions hailstorm-cli/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
PATH
remote: .
specs:
hailstorm-cli (1.0.14-java)
hailstorm (= 5.0.13)
hailstorm-cli (1.0.15-java)
hailstorm (= 5.0.14)

GEM
remote: https://rubygems.org/
Expand Down Expand Up @@ -94,7 +94,7 @@ GEM
erubis (2.7.0)
ffi (1.13.1-java)
haikunator (1.1.0)
hailstorm (5.0.13-java)
hailstorm (5.0.14-java)
actionpack (~> 6.0.0)
activerecord-jdbc-adapter (~> 60.2)
aws-sdk-ec2 (~> 1)
Expand Down
2 changes: 1 addition & 1 deletion hailstorm-cli/hailstorm-cli.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,5 @@ and generate reports.'
gem.executables = gem.files.grep(%r{^bin/\b}).map { |f| File.basename(f) }
gem.require_paths = %w[lib]

gem.add_runtime_dependency('hailstorm', '= 5.0.13')
gem.add_runtime_dependency('hailstorm', '= 5.0.14')
end
2 changes: 1 addition & 1 deletion hailstorm-cli/lib/hailstorm/cli/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
# Version
module Hailstorm
module Cli
VERSION = '1.0.14'
VERSION = '1.0.15'
end
end
2 changes: 1 addition & 1 deletion hailstorm-gem/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
hailstorm (5.0.13-java)
hailstorm (5.0.14-java)
actionpack (~> 6.0.0)
activerecord-jdbc-adapter (~> 60.2)
aws-sdk-ec2 (~> 1)
Expand Down
2 changes: 1 addition & 1 deletion hailstorm-gem/lib/hailstorm/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Hailstorm
VERSION = '5.0.13'
VERSION = '5.0.14'
end
Original file line number Diff line number Diff line change
Expand Up @@ -84,19 +84,11 @@
<w:t xml:space="preserve">Detailed Metrics</w:t>
</w:r>
</w:p>
<w:p w:rsidR="00DE1712" w:rsidRPr="00DE1712" w:rsidRDefault="00DE1712"
w:rsidP="00DE1712">
<w:r>
<w:rPr>
<w:noProof />
</w:rPr>
<%=
render(:partial => 'aggregate_table', :object => client_stat.aggregate_stats)
%>
</w:r>
</w:p>
<%- end %> <!-- jmeter -->
<%- end %> <!-- cluster -->
<%=
render(:partial => 'aggregate_table', :object => client_stat.aggregate_stats)
%>
<%- end %> <!-- jmeter -->
<%- end %> <!-- cluster -->

<w:p w:rsidR="00406A65" w:rsidRDefault="00406A65" w:rsidP="00406A65">
<w:pPr>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,6 @@
<%- definition.samplers.each do |step| %>
<w:p w:rsidR="00F253FF" w:rsidRDefault="00F253FF" w:rsidP="00F253FF">
<w:pPr>
<w:pStyle w:val="ListParagraph"/>
<w:numPr>
<w:ilvl w:val="0"/>
<w:numId w:val="3"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@
</w:r>
</w:p>
<%= render :partial => 'workload_definition', :locals => {:jmeter_plans => @report.jmeter_plans} %>
<%= render :partial => 'workload_iterations', :locals => {:report => @report} %>
<%= render :partial => 'workload_iterations', :locals => {:report => @report} %>
<%= render :partial => 'test_environment', :locals => {:report => @report} %>
<%= render :partial => 'response_vs_users', :locals => {:report => @report} %>
<%= render :partial => 'app_infra_vs_users', :locals => {:report => @report} %>
Expand Down
10 changes: 6 additions & 4 deletions hailstorm-web-client/e2e/features/support/pages/AmazonConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,11 @@ export class AmazonConfig extends ClusterConfig {
}

updateCluster({maxThreadsPerAgent}: {maxThreadsPerAgent: number}) {
this.maxThreadsPerInstance.setValue(maxThreadsPerAgent.toString());
browser.pause(250);
browser.waitUntil(() => this.updateButton.isEnabled(), 500);
this.updateButton.click();
if (this.maxThreadsPerInstance.getValue() !== maxThreadsPerAgent.toString()) {
this.maxThreadsPerInstance.setValue(maxThreadsPerAgent.toString());
browser.pause(250);
browser.waitUntil(() => this.updateButton.isEnabled(), 500);
this.updateButton.click();
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ export class ReportWidget {

get masterCheckBox() { return $('//table/thead/tr/th/input'); }
get reportButton() { return $('button*=Report'); }
get reportsListItems() { return $$('//*[@data-testid="Reports List"]/a'); }
get reportsListItems() { return $$('//*[@data-testid="Reports List"]//a'); }

generateReport() {
browser.pause(500);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ export class TerminateWidget {
get showDangerousSettings() { return $('button*=Show them'); }
get terminateButton() { return $('button*=Terminate this project'); }
get confirmTerminate() { return $('button*=Yes, Terminate'); }
get notifications() { return $$('button[class=delete][title=Close]') }

terminateProject() {
this.notifications.forEach((element) => element.click());
this.showDangerousSettings.click();
this.terminateButton.waitForDisplayed(1000);
this.terminateButton.click();
Expand Down
2 changes: 1 addition & 1 deletion hailstorm-web-client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion hailstorm-web-client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "hailstorm-web-client",
"version": "1.5.8",
"version": "1.7.9",
"private": true,
"dependencies": {
"date-fns": "^2.6.0",
Expand Down
8 changes: 8 additions & 0 deletions hailstorm-web-client/src/App.scss
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,11 @@ main {
.force-wrap {
word-wrap: anywhere;
}

.is-error {
@extend .is-danger !optional;
}

.is-warn {
@extend .is-warning !optional;
}
11 changes: 7 additions & 4 deletions hailstorm-web-client/src/App.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,28 +11,31 @@ jest.mock(`./TopNav`, () => ({

jest.mock(`./ProjectList`, () => ({
__esModule: true,
TopNav: () => (
ProjectList: () => (
<div id="ProjectList"></div>
)
}));

jest.mock(`./ProjectWorkspace`, () => ({
__esModule: true,
TopNav: () => (
ProjectWorkspace: () => (
<div id="ProjectWorkspace"></div>
)
}));

jest.mock(`./NewProjectWizard`, () => ({
__esModule: true,
TopNav: () => (
NewProjectWizard: () => (
<div id="NewProjectWizard"></div>
)
}));

describe('<App />', () => {
it('renders without crashing', () => {
shallow(<App />);
const component = shallow(<App />);
expect(component).toContainExactlyOneMatchingElement('AppStateProvider');
expect(component).toContainExactlyOneMatchingElement('AppNotificationProvider');
expect(component).toContainExactlyOneMatchingElement('TopNav');
});

it('should redirect to /projects from /', () => {
Expand Down
33 changes: 16 additions & 17 deletions hailstorm-web-client/src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,30 +1,29 @@
import React, { useReducer } from 'react';
import {useReducer as useStoreReducer} from 'reinspect';
import React from 'react';
import './App.scss';
import { TopNav } from './TopNav';
import { ProjectWorkspace } from './ProjectWorkspace';
import { ProjectList } from './ProjectList';
import { Route, HashRouter, Redirect } from 'react-router-dom';
import { NewProjectWizard } from './NewProjectWizard';
import { rootReducer, initialState } from './store';
import { AppStateContext } from './appStateContext';
import { AppStateProvider } from './AppStateProvider';
import { AppNotificationProvider } from './AppNotificationProvider';

const App: React.FC = () => {
// const [appState, dispatch] = useReducer(rootReducer, initialState);
const [appState, dispatch] = useStoreReducer(rootReducer, initialState, (state) => state, "Hailstorm");

return (
<AppStateContext.Provider value={{appState, dispatch}}>
<HashRouter>
<TopNav />
<main>
<Route exact path="/" render={() => (<Redirect to="/projects" />)} />
<Route path="/projects" component={ProjectList} exact={true} />
<Route path="/projects/:id" component={ProjectWorkspace} />
<Route path="/wizard/projects/:id" component={NewProjectWizard} />
</main>
</HashRouter>
</AppStateContext.Provider>
<AppStateProvider>
<AppNotificationProvider>
<HashRouter>
<TopNav />
<main>
<Route exact path="/" render={() => (<Redirect to="/projects" />)} />
<Route path="/projects" component={ProjectList} exact={true} />
<Route path="/projects/:id" component={ProjectWorkspace} />
<Route path="/wizard/projects/:id" component={NewProjectWizard} />
</main>
</HashRouter>
</AppNotificationProvider>
</AppStateProvider>
);
};

Expand Down
Loading

0 comments on commit 9f23985

Please sign in to comment.