WasThreadStackProcessor 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
data/.document CHANGED
@@ -1,5 +1,5 @@
1
- lib/**/*.rb
2
- bin/*
3
- -
4
- features/**/*.feature
5
- LICENSE.txt
1
+ lib/**/*.rb
2
+ bin/*
3
+ -
4
+ features/**/*.feature
5
+ LICENSE.txt
data/Gemfile CHANGED
@@ -1,24 +1,27 @@
1
- source "http://rubygems.org"
2
- source "http://gems.github.com"
3
- # Add dependencies required to use your gem here.
4
- # Example:
5
- # gem "activesupport", ">= 2.3.5"
6
-
7
- # Add dependencies to develop your gem here.
8
- # Include everything needed to run rake, tests, features, etc.
9
- group :development do
10
- gem "rspec", "~> 2.10.0"
11
- gem "rdoc", "~> 3.12"
12
- gem "bundler", "~> 1.1.0"
13
- gem "jeweler", "~> 1.8.3"
14
- gem "rcov", ">= 0"
15
- gem "hirb", "~> 0.6.2"
16
- end
17
-
18
- group :xzibit do
19
- gem "WasThreadStackProcessor", :path => '.'
20
- end
21
-
22
- group :debug do
23
- gem (RUBY_VERSION =~ /^1\.9/ ? "ruby-debug19" : "ruby-debug")
1
+ source "http://rubygems.org"
2
+ source "http://gems.github.com"
3
+ # Add dependencies required to use your gem here.
4
+ # Example:
5
+ # gem "activesupport", ">= 2.3.5"
6
+
7
+ # Add dependencies to develop your gem here.
8
+ # Include everything needed to run rake, tests, features, etc.
9
+ group :development do
10
+ gem "rspec", "~> 2.10.0"
11
+ gem "rdoc", "~> 3.12"
12
+ gem "bundler", "~> 1.1.0"
13
+ gem "jeweler", "~> 1.8.3"
14
+ # gem "rcov", ">= 0"
15
+
16
+ gem "simplecov", ">= 0"
17
+ end
18
+
19
+ gem "hirb", "~> 0.6.2"
20
+
21
+ group :xzibit do
22
+ gem "WasThreadStackProcessor", :path => '.'
23
+ end
24
+
25
+ group :debug do
26
+ # gem (RUBY_VERSION =~ /^1\.9/ ? "ruby-debug19" : "ruby-debug")
24
27
  end
@@ -1,52 +1,46 @@
1
- PATH
2
- remote: .
3
- specs:
4
- WasThreadStackProcessor (0.1.3)
5
-
6
- GEM
7
- remote: http://rubygems.org/
8
- remote: http://gems.github.com/
9
- specs:
10
- columnize (0.3.6)
11
- diff-lcs (1.1.3)
12
- git (1.2.5)
13
- hirb (0.6.2)
14
- jeweler (1.8.3)
15
- bundler (~> 1.0)
16
- git (>= 1.2.5)
17
- rake
18
- rdoc
19
- json (1.7.3)
20
- linecache (0.46)
21
- rbx-require-relative (> 0.0.4)
22
- rake (0.9.2.2)
23
- rbx-require-relative (0.0.9)
24
- rcov (1.0.0)
25
- rdoc (3.12)
26
- json (~> 1.4)
27
- rspec (2.10.0)
28
- rspec-core (~> 2.10.0)
29
- rspec-expectations (~> 2.10.0)
30
- rspec-mocks (~> 2.10.0)
31
- rspec-core (2.10.0)
32
- rspec-expectations (2.10.0)
33
- diff-lcs (~> 1.1.3)
34
- rspec-mocks (2.10.1)
35
- ruby-debug (0.10.4)
36
- columnize (>= 0.1)
37
- ruby-debug-base (~> 0.10.4.0)
38
- ruby-debug-base (0.10.4)
39
- linecache (>= 0.3)
40
-
41
- PLATFORMS
42
- ruby
43
-
44
- DEPENDENCIES
45
- WasThreadStackProcessor!
46
- bundler (~> 1.1.0)
47
- hirb (~> 0.6.2)
48
- jeweler (~> 1.8.3)
49
- rcov
50
- rdoc (~> 3.12)
51
- rspec (~> 2.10.0)
52
- ruby-debug
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ WasThreadStackProcessor (0.1.3)
5
+
6
+ GEM
7
+ remote: http://rubygems.org/
8
+ remote: http://gems.github.com/
9
+ specs:
10
+ diff-lcs (1.1.3)
11
+ git (1.2.5)
12
+ hirb (0.6.2)
13
+ jeweler (1.8.3)
14
+ bundler (~> 1.0)
15
+ git (>= 1.2.5)
16
+ rake
17
+ rdoc
18
+ json (1.7.3)
19
+ multi_json (1.7.2)
20
+ rake (0.9.2.2)
21
+ rdoc (3.12)
22
+ json (~> 1.4)
23
+ rspec (2.10.0)
24
+ rspec-core (~> 2.10.0)
25
+ rspec-expectations (~> 2.10.0)
26
+ rspec-mocks (~> 2.10.0)
27
+ rspec-core (2.10.0)
28
+ rspec-expectations (2.10.0)
29
+ diff-lcs (~> 1.1.3)
30
+ rspec-mocks (2.10.1)
31
+ simplecov (0.7.1)
32
+ multi_json (~> 1.0)
33
+ simplecov-html (~> 0.7.1)
34
+ simplecov-html (0.7.1)
35
+
36
+ PLATFORMS
37
+ ruby
38
+
39
+ DEPENDENCIES
40
+ WasThreadStackProcessor!
41
+ bundler (~> 1.1.0)
42
+ hirb (~> 0.6.2)
43
+ jeweler (~> 1.8.3)
44
+ rdoc (~> 3.12)
45
+ rspec (~> 2.10.0)
46
+ simplecov
@@ -1,20 +1,20 @@
1
- Copyright (c) 2012 Alberto Paz
2
-
3
- Permission is hereby granted, free of charge, to any person obtaining
4
- a copy of this software and associated documentation files (the
5
- "Software"), to deal in the Software without restriction, including
6
- without limitation the rights to use, copy, modify, merge, publish,
7
- distribute, sublicense, and/or sell copies of the Software, and to
8
- permit persons to whom the Software is furnished to do so, subject to
9
- the following conditions:
10
-
11
- The above copyright notice and this permission notice shall be
12
- included in all copies or substantial portions of the Software.
13
-
14
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
- NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
- LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
- OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1
+ Copyright (c) 2012 Alberto Paz
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -1,19 +1,19 @@
1
- = WasThreadStackProcessor
2
-
3
- Description goes here.
4
-
5
- == Contributing to WasThreadStackProcessor
6
-
7
- * Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet.
8
- * Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it.
9
- * Fork the project.
10
- * Start a feature/bugfix branch.
11
- * Commit and push until you are happy with your contribution.
12
- * Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
13
- * Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.
14
-
15
- == Copyright
16
-
17
- Copyright (c) 2012 Alberto Paz. See LICENSE.txt for
18
- further details.
19
-
1
+ = WasThreadStackProcessor
2
+
3
+ Description goes here.
4
+
5
+ == Contributing to WasThreadStackProcessor
6
+
7
+ * Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet.
8
+ * Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it.
9
+ * Fork the project.
10
+ * Start a feature/bugfix branch.
11
+ * Commit and push until you are happy with your contribution.
12
+ * Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
13
+ * Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.
14
+
15
+ == Copyright
16
+
17
+ Copyright (c) 2012 Alberto Paz. See LICENSE.txt for
18
+ further details.
19
+
data/Rakefile CHANGED
@@ -1,58 +1,58 @@
1
- # encoding: utf-8
2
-
3
- require 'rubygems'
4
- require 'bundler'
5
-
6
- begin
7
- Bundler.setup(:default, :xzibit, :development)
8
- rescue Bundler::BundlerError => e
9
- $stderr.puts e.message
10
- $stderr.puts "Run `bundle install` to install missing gems"
11
- exit e.status_code
12
- end
13
-
14
- require 'rake'
15
- require 'jeweler'
16
- Jeweler::Tasks.new do |gem|
17
- # gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
18
- gem.name = "WasThreadStackProcessor"
19
- gem.homepage = "http://github.com/japaz/WasThreadStackProcessor"
20
- gem.license = "MIT"
21
- gem.summary = %Q{Utility to process Thread Stacks from a WebSphere Application Server}
22
- gem.description = %Q{This utility extracts all the Thread Stacks from a set of thread dump files of a WebSphere Application Server and generates a unique tree with all the threads}
23
- gem.email = "alberto.pazjimenez@gmail.com"
24
- gem.authors = ["Alberto Paz"]
25
- # dependencies defined in Gemfile
26
- end
27
-
28
- Jeweler::RubygemsDotOrgTasks.new
29
-
30
-
31
- require 'rspec/core'
32
- require 'rspec/core/rake_task'
33
- RSpec::Core::RakeTask.new(:spec) do |spec|
34
- spec.pattern = FileList['spec/**/*_spec.rb']
35
- end
36
-
37
- RSpec::Core::RakeTask.new(:rcov) do |spec|
38
- spec.pattern = 'spec/**/*_spec.rb'
39
- spec.rcov = true
40
- end
41
-
42
- task :default => :rspec
43
-
44
- require 'rdoc/task'
45
- Rake::RDocTask.new do |rdoc|
46
- version = File.exist?('VERSION') ? File.read('VERSION') : ""
47
-
48
- rdoc.rdoc_dir = 'rdoc'
49
- rdoc.title = "WasThreadStackProcessor #{version}"
50
- rdoc.rdoc_files.include('README*')
51
- rdoc.rdoc_files.include('lib/**/*.rb')
52
- end
53
-
54
- if ENV["RUN_CODE_RUN"] == "true"
55
- task :default => [:test, :features]
56
- else
57
- task :default => :test
58
- end
1
+ # encoding: utf-8
2
+
3
+ require 'rubygems'
4
+ require 'bundler'
5
+
6
+ begin
7
+ Bundler.setup(:default, :xzibit, :development)
8
+ rescue Bundler::BundlerError => e
9
+ $stderr.puts e.message
10
+ $stderr.puts "Run `bundle install` to install missing gems"
11
+ exit e.status_code
12
+ end
13
+
14
+ require 'rake'
15
+ require 'jeweler'
16
+ Jeweler::Tasks.new do |gem|
17
+ # gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
18
+ gem.name = "WasThreadStackProcessor"
19
+ gem.homepage = "http://github.com/japaz/WasThreadStackProcessor"
20
+ gem.license = "MIT"
21
+ gem.summary = %Q{Utility to process Thread Stacks from a WebSphere Application Server}
22
+ gem.description = %Q{This utility extracts all the Thread Stacks from a set of thread dump files of a WebSphere Application Server and generates a unique tree with all the threads}
23
+ gem.email = "alberto.pazjimenez@gmail.com"
24
+ gem.authors = ["Alberto Paz"]
25
+ # dependencies defined in Gemfile
26
+ end
27
+
28
+ Jeweler::RubygemsDotOrgTasks.new
29
+
30
+
31
+ require 'rspec/core'
32
+ require 'rspec/core/rake_task'
33
+ RSpec::Core::RakeTask.new(:spec) do |spec|
34
+ spec.pattern = FileList['spec/**/*_spec.rb']
35
+ end
36
+
37
+ #RSpec::Core::RakeTask.new(:rcov) do |spec|
38
+ # spec.pattern = 'spec/**/*_spec.rb'
39
+ # spec.rcov = true
40
+ #end
41
+
42
+ task :default => :spec
43
+
44
+ require 'rdoc/task'
45
+ Rake::RDocTask.new do |rdoc|
46
+ version = File.exist?('VERSION') ? File.read('VERSION') : ""
47
+
48
+ rdoc.rdoc_dir = 'rdoc'
49
+ rdoc.title = "WasThreadStackProcessor #{version}"
50
+ rdoc.rdoc_files.include('README*')
51
+ rdoc.rdoc_files.include('lib/**/*.rb')
52
+ end
53
+
54
+ if ENV["RUN_CODE_RUN"] == "true"
55
+ task :default => [:test, :features]
56
+ else
57
+ task :default => :test
58
+ end
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.4
1
+ 0.1.5
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "WasThreadStackProcessor"
8
- s.version = "0.1.4"
8
+ s.version = "0.1.5"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Alberto Paz"]
12
- s.date = "2012-07-12"
12
+ s.date = "2013-04-21"
13
13
  s.description = "This utility extracts all the Thread Stacks from a set of thread dump files of a WebSphere Application Server and generates a unique tree with all the threads"
14
14
  s.email = "alberto.pazjimenez@gmail.com"
15
15
  s.executables = ["WasThreadStackProcessor"]
@@ -41,34 +41,34 @@ Gem::Specification.new do |s|
41
41
  s.homepage = "http://github.com/japaz/WasThreadStackProcessor"
42
42
  s.licenses = ["MIT"]
43
43
  s.require_paths = ["lib"]
44
- s.rubygems_version = "1.8.21"
44
+ s.rubygems_version = "1.8.25"
45
45
  s.summary = "Utility to process Thread Stacks from a WebSphere Application Server"
46
46
 
47
47
  if s.respond_to? :specification_version then
48
48
  s.specification_version = 3
49
49
 
50
50
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
51
+ s.add_runtime_dependency(%q<hirb>, ["~> 0.6.2"])
51
52
  s.add_development_dependency(%q<rspec>, ["~> 2.10.0"])
52
53
  s.add_development_dependency(%q<rdoc>, ["~> 3.12"])
53
54
  s.add_development_dependency(%q<bundler>, ["~> 1.1.0"])
54
55
  s.add_development_dependency(%q<jeweler>, ["~> 1.8.3"])
55
- s.add_development_dependency(%q<rcov>, [">= 0"])
56
- s.add_development_dependency(%q<hirb>, ["~> 0.6.2"])
56
+ s.add_development_dependency(%q<simplecov>, [">= 0"])
57
57
  else
58
+ s.add_dependency(%q<hirb>, ["~> 0.6.2"])
58
59
  s.add_dependency(%q<rspec>, ["~> 2.10.0"])
59
60
  s.add_dependency(%q<rdoc>, ["~> 3.12"])
60
61
  s.add_dependency(%q<bundler>, ["~> 1.1.0"])
61
62
  s.add_dependency(%q<jeweler>, ["~> 1.8.3"])
62
- s.add_dependency(%q<rcov>, [">= 0"])
63
- s.add_dependency(%q<hirb>, ["~> 0.6.2"])
63
+ s.add_dependency(%q<simplecov>, [">= 0"])
64
64
  end
65
65
  else
66
+ s.add_dependency(%q<hirb>, ["~> 0.6.2"])
66
67
  s.add_dependency(%q<rspec>, ["~> 2.10.0"])
67
68
  s.add_dependency(%q<rdoc>, ["~> 3.12"])
68
69
  s.add_dependency(%q<bundler>, ["~> 1.1.0"])
69
70
  s.add_dependency(%q<jeweler>, ["~> 1.8.3"])
70
- s.add_dependency(%q<rcov>, [">= 0"])
71
- s.add_dependency(%q<hirb>, ["~> 0.6.2"])
71
+ s.add_dependency(%q<simplecov>, [">= 0"])
72
72
  end
73
73
  end
74
74
 
@@ -1 +1 @@
1
- Autotest.add_discovery { "rspec2" }
1
+ Autotest.add_discovery { "rspec2" }
@@ -1,17 +1,23 @@
1
- #!/usr/bin/env ruby
2
-
3
- require 'WasThreadStackProcessor'
4
-
5
- threadStackCombinator = ThreadStackCombinator.new
6
- wasThreadStackProcessor = WasThreadStackProcessor.new(threadStackCombinator)
7
-
8
- ARGV.each do |file|
9
- File.open(file, "r") do |infile|
10
- wasThreadStackProcessor.process(infile)
11
- end
12
- end
13
-
14
- extend Hirb::Console
15
- view wasThreadStackProcessor, :class=>:parent_child_tree, :type=>:basic, :value_method=>:text_count, :indent=>1, :children_method=>:children_sorted
16
-
17
- # wasThreadStackProcessor.threadStackCombinator.combinedThreadStacks.each { |combinedThreadStack| puts combinedThreadStack.call.text}
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'WasThreadStackProcessor'
4
+
5
+ unless ARGV.length > 0
6
+ puts "Dude, not any argument."
7
+ puts "Usage: WasThreadStackProcessor javacore_files\n"
8
+ exit
9
+ end
10
+
11
+ threadStackCombinator = ThreadStackCombinator.new
12
+ wasThreadStackProcessor = WasThreadStackProcessor.new(threadStackCombinator)
13
+
14
+ ARGV.each do |file|
15
+ File.open(file, "r") do |infile|
16
+ wasThreadStackProcessor.process(infile)
17
+ end
18
+ end
19
+
20
+ extend Hirb::Console
21
+ view wasThreadStackProcessor, :class=>:parent_child_tree, :type=>:basic, :value_method=>:text_count, :indent=>1, :children_method=>:children_sorted
22
+
23
+ # wasThreadStackProcessor.threadStackCombinator.combinedThreadStacks.each { |combinedThreadStack| puts combinedThreadStack.call.text}