storazzo 0.6.1 → 0.7.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -20,174 +20,169 @@
20
20
 
21
21
  module Storazzo
22
22
  module Media
23
- module Storazzo
24
- module Media
25
- class AbstractRicDisk
26
- # include Storazzo::Common
27
- extend Storazzo::Common
28
-
29
- # DefaultStatsFilename = Storazzo::RicDiskStatsFile.default_name
30
-
31
- # looks like there's not Abstract Class in Ruby, but also SO says he best
32
- # way to do this is this:
33
-
34
- # attr_accessor :name, :description, :ricdisk_file, :local_mountpoint, :wr, :path, :ricdisk_file_empty, :size, :active_dirs
35
- attr_accessor :description
36
-
37
- ########################
38
- # Abstract methods START
39
- ########################
40
- def initialize(_local_mount)
41
- deb "[AbstractRicDisk.init()] Some child of AbstractRicDisk (#{self}) called me! Yummie." # disable when you dont need me anymore..
42
- @description ||= 'Not provided'
43
- # validate
44
- end
45
-
46
- def self.list_all
47
- raise "[AbstractRicDiskc::self.list_all] You should override this, says StackOverflow and Riccardo. Class=#{self.class}. Self=#{self}"
48
- end
49
-
50
- def self.list_all_with_type
51
- raise "[AbstractRicDisk::self.list_all_with_type] You should override this, says StackOverflow and Riccardo. Class=#{self.class}. Self=#{self}"
52
- end
53
-
54
- def self.super_duper_list_all_with_type
55
- deb 'Would be cool to be able to enumerate them all..'
56
- GcsBucket.list_all_with_type +
57
- MountPoint.list_all_with_type +
58
- LocalFolder.list_all_with_type
59
- end
60
-
61
- def parse(_opts = {})
62
- raise "[AbstractRicDiskc::parse] You should override this, says StackOverflow and Riccardo. Class=#{self.class}."
63
- end
64
-
65
- def writeable?
66
- raise "[AbstractRicDiskc::writeable] You should override this in class=#{self.class}, says StackOverflow and Riccardo"
67
- end
68
-
69
- def get_local_mountpoint
70
- # raise "[AbstractRicDiskc::get_local_mountpoint] You should override this, says StackOverflow and Riccardo"
71
- raise 'You forgot to set local_mountpoint in the constructor for your class, you cheeky little one!' if local_mountpoint.nil?
72
-
73
- local_mountpoint
74
- end
75
-
76
- def check_implemented_correctly
77
- # raise "[AbstractRicDiskc] You should override this, says StackOverflow and Riccardo"
78
- raise 'no @local_mountpoint' unless exists?(@local_mountpoint)
79
- end
80
- ########################
81
- # Abstract methods END
82
- ########################
83
-
84
- ########################
85
- # Automated methods now...
86
- ########################
87
- # stats_file_default_location()
88
- def stats_file_smart_fullpath
89
- # if its writeable... if not we'll think about it later.
90
- if writeable?
91
- "#{get_local_mountpoint}/#{default_stats_filename}"
92
- else
93
- # if not writeable, I will:
94
- # 1. create a dir based on its unique format.
95
- # 2. create a file of same look and feel (alternative - used a DASH)
96
- "TODO FIXME {get_local_folder}/#{unique_id}::#{default_stats_filename}"
97
- # "{get_local_folder}"/#{unique_id}/#{Storazzo::RicDiskStatsFile.default_name}"
98
- end
99
- end
100
-
101
- # Needs to be some unique id based on its thingy, but might change in the future:
102
- # Solutions:
103
- # {PHILOSOPHY}::{ID}
104
- def unique_id
105
- # Expand path to make it as unique as possible...
106
- hash = Digest::MD5.hexdigest(File.expand_path(get_local_mountpoint))
107
- "MD5::v1::#{hash}"
108
- end
109
-
110
- def to_s(verbose = false)
111
- return to_verbose_s if verbose
112
-
113
- readable_class = self.class.to_s.split('::').last # Storazzo::Media::LocalFolder => LocalFolder
114
- my_keys = instance_variables # wow!
115
- "S:M:#{readable_class}(path=#{path}, r/w=#{wr}, keys=#{my_keys})"
116
- end
117
-
118
- def to_verbose_s
119
- h = {}
120
- h[:class] = self.class
121
- h[:unique_id] = unique_id
122
- h[:inspect] = inspect
123
- h[:to_s] = to_s
124
- h[:local_mountpoint] = local_mountpoint
125
- h[:writeable] = writeable?
126
- h[:stats_file_smart_fullpath] = stats_file_smart_fullpath
127
- h
128
- end
129
-
130
- # # Todo check on instances these 3 methods exist
131
- def self.abstract_class_mandatory_methods
132
- %w[
133
- self.list_all
134
- self.list_all_with_type
135
- local_mountpoint
136
- parse
137
- writeable?
138
- ]
139
- end
140
-
141
- # Putting here since its same code for MountPoint or generic folder.
142
- def parse_block_storage_folder(opts = {})
143
- # Storazzo::RicDiskUgly.calculate_stats_files(get_local_mountpoint)
144
- rd = Storazzo::RicDisk.new(self)
145
- # Storazzo::RicDisk
146
- rd.compute_stats_files(opts)
147
- # return "42"
148
- end
149
-
150
- def self.default_stats_filename
151
- raise 'Unknown Storazzo::RicDiskStatsFile.default_name 1!!' if Storazzo::RicDiskStatsFile.default_name.nil?
152
-
153
- Storazzo::RicDiskStatsFile.default_name
154
- end
155
-
156
- # if not writeable we need to pick another from stats_file_smart_fullpath()
157
- def stats_filename_default_fullpath
158
- # REDUNDANT, should use stats_file_smart_fullpath instead except on the writeable? part since it would go recursive otherwise.
159
- my_stats_filename = default_stats_filename
160
- # raise "Unknown Storazzo::RicDiskStatsFile.default_name 2 !!" if Storazzo::RicDiskStatsFile.default_name.nil?
161
- "#{local_mountpoint}/#{my_stats_filename}"
162
- end
163
-
164
- def validate(opts = {})
165
- opt_verbose = opts.fetch :verbose, false
166
- pverbose opt_verbose,
167
- "validate(): [BROKEN] We're trying to see if your object is valid, across 3 possible sub-classes."
168
- # 1. check for
169
- raise 'Unknown local mount ' unless local_mount.is_a?(String)
170
-
171
- # 2. check thaty writeable? is true or false
172
- my_writeable = wr
173
- raise 'Writeable is not boolean' unless my_writeable.is_a?(TrueClass) || my_writeable.is_a?(FalseClass)
174
- end
175
-
176
- # TODO: use a proper Factory pattern.
177
- def self.DirFactory(path)
178
- raise "I need a path/directory string: #{path}" unless path.is_a?(String)
179
-
180
- deb 'TODO: if coincides with MountPoint, instance THAT'
181
- # if path in Storazzo::Media::MountPoint.list_all_mount_points
182
- # then return ...
183
- if path =~ %r{^gs://}
184
- deb 'Smells like GCS'
185
- return GcsBucket.new(path)
186
- end
187
- deb 'Smells like LocalFolder :)'
188
- LocalFolder.new(path)
189
- end
23
+ class AbstractRicDisk
24
+ extend ::Storazzo::Common
25
+
26
+ # DefaultStatsFilename = Storazzo::RicDiskStatsFile.default_name
27
+
28
+ # looks like there's not Abstract Class in Ruby, but also SO says he best
29
+ # way to do this is this:
30
+
31
+ # attr_accessor :name, :description, :ricdisk_file, :local_mountpoint, :wr, :path, :ricdisk_file_empty, :size, :active_dirs
32
+ attr_accessor :description
33
+
34
+ ########################
35
+ # Abstract methods START
36
+ ########################
37
+ def initialize(_local_mount)
38
+ deb "[AbstractRicDisk.init()] Some child of AbstractRicDisk (#{self}) called me! Yummie." # disable when you dont need me anymore..
39
+ @description ||= 'Not provided'
40
+ # validate
41
+ end
42
+
43
+ def self.list_all
44
+ raise "[AbstractRicDiskc::self.list_all] You should override this, says StackOverflow and Riccardo. Class=#{self.class}. Self=#{self}"
45
+ end
46
+
47
+ def self.list_all_with_type
48
+ raise "[AbstractRicDisk::self.list_all_with_type] You should override this, says StackOverflow and Riccardo. Class=#{self.class}. Self=#{self}"
49
+ end
50
+
51
+ def self.super_duper_list_all_with_type
52
+ deb 'Would be cool to be able to enumerate them all..'
53
+ GcsBucket.list_all_with_type +
54
+ MountPoint.list_all_with_type +
55
+ LocalFolder.list_all_with_type
56
+ end
57
+
58
+ def parse(_opts = {})
59
+ raise "[AbstractRicDiskc::parse] You should override this, says StackOverflow and Riccardo. Class=#{self.class}."
60
+ end
61
+
62
+ def writeable?
63
+ raise "[AbstractRicDiskc::writeable] You should override this in class=#{self.class}, says StackOverflow and Riccardo"
64
+ end
65
+
66
+ def get_local_mountpoint
67
+ # raise "[AbstractRicDiskc::get_local_mountpoint] You should override this, says StackOverflow and Riccardo"
68
+ raise 'You forgot to set local_mountpoint in the constructor for your class, you cheeky little one!' if local_mountpoint.nil?
69
+
70
+ local_mountpoint
71
+ end
72
+
73
+ def check_implemented_correctly
74
+ # raise "[AbstractRicDiskc] You should override this, says StackOverflow and Riccardo"
75
+ raise 'no @local_mountpoint' unless exists?(@local_mountpoint)
76
+ end
77
+ ########################
78
+ # Abstract methods END
79
+ ########################
80
+
81
+ ########################
82
+ # Automated methods now...
83
+ ########################
84
+ # stats_file_default_location()
85
+ def stats_file_smart_fullpath
86
+ # if its writeable... if not we'll think about it later.
87
+ if writeable?
88
+ "#{get_local_mountpoint}/#{default_stats_filename}"
89
+ else
90
+ # if not writeable, I will:
91
+ # 1. create a dir based on its unique format.
92
+ # 2. create a file of same look and feel (alternative - used a DASH)
93
+ "TODO FIXME {get_local_folder}/#{unique_id}::#{default_stats_filename}"
94
+ # "{get_local_folder}"/#{unique_id}/#{Storazzo::RicDiskStatsFile.default_name}"
95
+ end
96
+ end
97
+
98
+ # Needs to be some unique id based on its thingy, but might change in the future:
99
+ # Solutions:
100
+ # {PHILOSOPHY}::{ID}
101
+ def unique_id
102
+ # Expand path to make it as unique as possible...
103
+ hash = Digest::MD5.hexdigest(File.expand_path(get_local_mountpoint))
104
+ "MD5::v1::#{hash}"
105
+ end
106
+
107
+ def to_s(verbose = false)
108
+ return to_verbose_s if verbose
109
+
110
+ readable_class = self.class.to_s.split('::').last # Storazzo::Media::LocalFolder => LocalFolder
111
+ my_keys = instance_variables # wow!
112
+ "S:M:#{readable_class}(path=#{path}, r/w=#{wr}, keys=#{my_keys})"
113
+ end
114
+
115
+ def to_verbose_s
116
+ h = {}
117
+ h[:class] = self.class
118
+ h[:unique_id] = unique_id
119
+ h[:inspect] = inspect
120
+ h[:to_s] = to_s
121
+ h[:local_mountpoint] = local_mountpoint
122
+ h[:writeable] = writeable?
123
+ h[:stats_file_smart_fullpath] = stats_file_smart_fullpath
124
+ h
125
+ end
126
+
127
+ # # Todo check on instances these 3 methods exist
128
+ def self.abstract_class_mandatory_methods
129
+ %w[
130
+ self.list_all
131
+ self.list_all_with_type
132
+ local_mountpoint
133
+ parse
134
+ writeable?
135
+ ]
136
+ end
137
+
138
+ # Putting here since its same code for MountPoint or generic folder.
139
+ def parse_block_storage_folder(opts = {})
140
+ # Storazzo::RicDiskUgly.calculate_stats_files(get_local_mountpoint)
141
+ rd = Storazzo::RicDisk.new(self)
142
+ # Storazzo::RicDisk
143
+ rd.compute_stats_files(opts)
144
+ # return "42"
145
+ end
146
+
147
+ def self.default_stats_filename
148
+ raise 'Unknown Storazzo::RicDiskStatsFile.default_name 1!!' if Storazzo::RicDiskStatsFile.default_name.nil?
149
+
150
+ Storazzo::RicDiskStatsFile.default_name
151
+ end
152
+
153
+ # if not writeable we need to pick another from stats_file_smart_fullpath()
154
+ def stats_filename_default_fullpath
155
+ # REDUNDANT, should use stats_file_smart_fullpath instead except on the writeable? part since it would go recursive otherwise.
156
+ my_stats_filename = default_stats_filename
157
+ # raise "Unknown Storazzo::RicDiskStatsFile.default_name 2 !!" if Storazzo::RicDiskStatsFile.default_name.nil?
158
+ "#{local_mountpoint}/#{my_stats_filename}"
159
+ end
160
+
161
+ def validate(opts = {})
162
+ opt_verbose = opts.fetch :verbose, false
163
+ pverbose opt_verbose,
164
+ "validate(): [BROKEN] We're trying to see if your object is valid, across 3 possible sub-classes."
165
+ # 1. check for
166
+ raise 'Unknown local mount ' unless local_mount.is_a?(String)
167
+
168
+ # 2. check thaty writeable? is true or false
169
+ my_writeable = wr
170
+ raise 'Writeable is not boolean' unless my_writeable.is_a?(TrueClass) || my_writeable.is_a?(FalseClass)
171
+ end
172
+
173
+ # TODO: use a proper Factory pattern.
174
+ def self.DirFactory(path)
175
+ raise "I need a path/directory string: #{path}" unless path.is_a?(String)
176
+
177
+ deb 'TODO: if coincides with MountPoint, instance THAT'
178
+ # if path in Storazzo::Media::MountPoint.list_all_mount_points
179
+ # then return ...
180
+ if path =~ %r{^gs://}
181
+ deb 'Smells like GCS'
182
+ return GcsBucket.new(path)
190
183
  end
184
+ deb 'Smells like LocalFolder :)'
185
+ LocalFolder.new(path)
191
186
  end
192
187
  end
193
188
  end
@@ -4,85 +4,80 @@ require 'English'
4
4
 
5
5
  module Storazzo
6
6
  module Media
7
- # class Storazzo::Media::AbstractRicDisk
8
- module Storazzo
9
- module Media
10
- class GcsBucket < Storazzo::Media::AbstractRicDisk
11
- extend Storazzo::Common
7
+ class GcsBucket < Storazzo::Media::AbstractRicDisk
8
+ extend ::Storazzo::Common
12
9
 
13
- attr_accessor :project_id
10
+ attr_accessor :project_id
14
11
 
15
- def initialize(local_mount, project_id = nil)
16
- deb '[Storazzo::Media::GcsBucket] initialize'
12
+ def initialize(local_mount, project_id = nil)
13
+ deb '[Storazzo::Media::GcsBucket] initialize'
17
14
 
18
- @local_mountpoint = File.expand_path(local_mount)
19
- @description = "MountPoint in '#{local_mount}' pointing at TODO with mount options = TODO"
20
- project_id ||= _autodetect_project_id
21
- @project_id = project_id
22
- raise 'Sorry local mount doesnt exist!' unless File.exist?(@local_mountpoint)
15
+ @local_mountpoint = File.expand_path(local_mount)
16
+ @description = "MountPoint in '#{local_mount}' pointing at TODO with mount options = TODO"
17
+ project_id ||= _autodetect_project_id
18
+ @project_id = project_id
19
+ raise 'Sorry local mount doesnt exist!' unless File.exist?(@local_mountpoint)
23
20
 
24
- @wr = writeable? # File.writable?(stats_filename_default_fullpath) # .writeable? stats_file_smart_fullpath
25
- begin
26
- super(local_mount)
27
- rescue StandardError
28
- "SUPER_ERROR(#{local_mount}): #{$ERROR_INFO}"
29
- end
30
- end
31
-
32
- def _autodetect_project_id
33
- 'todo-my-project-id-123' # TODO: fix
34
- end
35
-
36
- # (config = nil)
37
- def self.list_all
38
- # get lisrts from Config singletone
39
- # puts " self.list_all: loading config "
40
- config ||= Storazzo::RicDiskConfig.instance # # ).get_config
21
+ @wr = writeable? # File.writable?(stats_filename_default_fullpath) # .writeable? stats_file_smart_fullpath
22
+ begin
23
+ super(local_mount)
24
+ rescue StandardError
25
+ "SUPER_ERROR(#{local_mount}): #{$ERROR_INFO}"
26
+ end
27
+ end
41
28
 
42
- config.load # in case I need to load it for the first time
43
- # puts config['Config']['AdditionalMountDirs']
44
- # puts "TODO see config: #{config}"
45
- # [42, 43]
46
- # deb config.get_local_folders
47
- # TODO
48
- pverbose true,
49
- "TODO(ricc): also add gsutil ls. For that please use the new 'list_all_with_type' (Id refactor it but Im afraid of leaving bad code dangling so before a proper refactor lets implement both side by side"
50
- config.get_bucket_paths
51
- end
29
+ def _autodetect_project_id
30
+ 'todo-my-project-id-123' # TODO: fix
31
+ end
52
32
 
53
- # (config = nil)
54
- def self.list_all_with_type
55
- deb 'GCS::list_all_with_type() -- pull config'
56
- config ||= Storazzo::RicDiskConfig.instance
57
- config.load # in case I need to load it for the first time
58
- # puts "GCS::list_all_with_type() -- TODO(ricc): also add gsutil ls"
59
- # getFromConfig
60
- deb "I'm now returning a 'complex' array to tell the caller what kind of element they're getting, eg: GCS from Config Yaml, vs GCS from gsutil ls "
61
- list_from_config_with_type = config.get_bucket_paths.map do |path|
62
- [:config_gcs_bucket, path]
63
- end
64
- ret_list = list_from_config_with_type
65
- if config.gcs_enabled? # should be if GCS enabled :) project_id
66
- # so I concatenate Apples with Bananas with names
67
- # ret_list += list_available_buckets(config.project_id).map { |path|
68
- ret_list += list_available_buckets.map do |path|
69
- [:gsutil_ls_gcs_bucket, path]
70
- end
71
- else
72
- deb 'list_all_with_type(): empty project id. Skipping'
73
- end
33
+ # (config = nil)
34
+ def self.list_all
35
+ # get lisrts from Config singletone
36
+ # puts " self.list_all: loading config "
37
+ config ||= Storazzo::RicDiskConfig.instance # # ).get_config
74
38
 
75
- ret_list
76
- end
39
+ config.load # in case I need to load it for the first time
40
+ # puts config['Config']['AdditionalMountDirs']
41
+ # puts "TODO see config: #{config}"
42
+ # [42, 43]
43
+ # deb config.get_local_folders
44
+ # TODO
45
+ pverbose true,
46
+ "TODO(ricc): also add gsutil ls. For that please use the new 'list_all_with_type' (Id refactor it but Im afraid of leaving bad code dangling so before a proper refactor lets implement both side by side"
47
+ config.get_bucket_paths
48
+ end
77
49
 
78
- def self.list_available_buckets(_opts = {})
79
- # project_id = opts.fetch :project_id, nil
80
- # list_of_buckets = `gsutil ls --project '#{project_id}'`.chomp.split("\n")
81
- list_of_buckets = `gsutil ls`.chomp.split("\n")
82
- deb "list_of_buckets: #{list_of_buckets}"
83
- list_of_buckets
50
+ # (config = nil)
51
+ def self.list_all_with_type
52
+ deb 'GCS::list_all_with_type() -- pull config'
53
+ config ||= Storazzo::RicDiskConfig.instance
54
+ config.load # in case I need to load it for the first time
55
+ # puts "GCS::list_all_with_type() -- TODO(ricc): also add gsutil ls"
56
+ # getFromConfig
57
+ deb "I'm now returning a 'complex' array to tell the caller what kind of element they're getting, eg: GCS from Config Yaml, vs GCS from gsutil ls "
58
+ list_from_config_with_type = config.get_bucket_paths.map do |path|
59
+ [:config_gcs_bucket, path]
60
+ end
61
+ ret_list = list_from_config_with_type
62
+ if config.gcs_enabled? # should be if GCS enabled :) project_id
63
+ # so I concatenate Apples with Bananas with names
64
+ # ret_list += list_available_buckets(config.project_id).map { |path|
65
+ ret_list += list_available_buckets.map do |path|
66
+ [:gsutil_ls_gcs_bucket, path]
84
67
  end
68
+ else
69
+ deb 'list_all_with_type(): empty project id. Skipping'
85
70
  end
71
+
72
+ ret_list
73
+ end
74
+
75
+ def self.list_available_buckets(_opts = {})
76
+ # project_id = opts.fetch :project_id, nil
77
+ # list_of_buckets = `gsutil ls --project '#{project_id}'`.chomp.split("\n")
78
+ list_of_buckets = `gsutil ls`.chomp.split("\n")
79
+ deb "list_of_buckets: #{list_of_buckets}"
80
+ list_of_buckets
86
81
  end
87
82
  end
88
83
  end
@@ -6,57 +6,53 @@
6
6
  require 'English'
7
7
  module Storazzo
8
8
  module Media
9
- module Storazzo
10
- module Media
11
- class LocalFolder < Storazzo::Media::AbstractRicDisk
12
- # extend Storazzo::Common
13
- include Storazzo::Common
14
-
15
- attr_accessor :local_mountpoint, :wr
16
-
17
- def initialize(local_mount)
18
- deb '[Storazzo::Media::LocalFolder] initialize'
19
-
20
- @local_mountpoint = File.expand_path(local_mount)
21
- @description = "Local Folder originally in '#{local_mount}'"
22
- raise 'Sorry local mount doesnt exist!' unless File.exist?(@local_mountpoint)
23
-
24
- @wr = writeable? # File.writable?(stats_filename_default_fullpath) # .writeable? stats_file_smart_fullpath
25
- # super.initialize(local_mount) rescue "SUPER_ERROR: #{$!}"
26
- begin
27
- super(local_mount)
28
- rescue StandardError
29
- "SUPER_ERROR(#{local_mount}): #{$ERROR_INFO}"
30
- end
31
- end
32
-
33
- # WRONG: config = nil
34
- def self.list_all
35
- # get lists from Config singleton
36
- config = Storazzo::RicDiskConfig.instance # # ).get_config
37
- config.load
38
- config.get_local_folders
39
- end
40
-
41
- def parse(opts = {})
42
- puts "LF.parse(#{opts}): TODO Sbrodola inside the dir: #{local_mountpoint}"
43
- parse_block_storage_folder
44
- end
45
-
46
- def path
47
- @local_mountpoint
48
- end
49
-
50
- def writeable?
51
- File.writable?(@local_mountpoint)
52
- end
53
-
54
- def default_stats_filename
55
- # '42'
56
- Storazzo::RicDiskStatsFile.default_name
57
- end
9
+ class LocalFolder < Storazzo::Media::AbstractRicDisk
10
+ # extend ::Storazzo::Common
11
+ include ::Storazzo::Common
12
+
13
+ attr_accessor :local_mountpoint, :wr
14
+
15
+ def initialize(local_mount)
16
+ deb '[Storazzo::Media::LocalFolder] initialize'
17
+
18
+ @local_mountpoint = File.expand_path(local_mount)
19
+ @description = "Local Folder originally in '#{local_mount}'"
20
+ raise 'Sorry local mount doesnt exist!' unless File.exist?(@local_mountpoint)
21
+
22
+ @wr = writeable? # File.writable?(stats_filename_default_fullpath) # .writeable? stats_file_smart_fullpath
23
+ # super.initialize(local_mount) rescue "SUPER_ERROR: #{$!}"
24
+ begin
25
+ super(local_mount)
26
+ rescue StandardError
27
+ "SUPER_ERROR(#{local_mount}): #{$ERROR_INFO}"
58
28
  end
59
29
  end
30
+
31
+ # WRONG: config = nil
32
+ def self.list_all
33
+ # get lists from Config singleton
34
+ config = Storazzo::RicDiskConfig.instance # # ).get_config
35
+ config.load
36
+ config.get_local_folders
37
+ end
38
+
39
+ def parse(opts = {})
40
+ puts "LF.parse(#{opts}): TODO Sbrodola inside the dir: #{local_mountpoint}"
41
+ parse_block_storage_folder
42
+ end
43
+
44
+ def path
45
+ @local_mountpoint
46
+ end
47
+
48
+ def writeable?
49
+ File.writable?(@local_mountpoint)
50
+ end
51
+
52
+ def default_stats_filename
53
+ # '42'
54
+ Storazzo::RicDiskStatsFile.default_name
55
+ end
60
56
  end
61
57
  end
62
58
  end
@@ -3,24 +3,20 @@
3
3
  # TODO
4
4
  module Storazzo
5
5
  module Media
6
- module Storazzo
7
- module Media
8
- class MountPoint < Storazzo::Media::AbstractRicDisk
9
- # puts "[REMOVEME] Storazzo::Media::MountPoint being read. REMOVEME when you see this :)"
6
+ class MountPoint < AbstractRicDisk
7
+ # puts "[REMOVEME] Storazzo::Media::MountPoint being read. REMOVEME when you see this :)"
10
8
 
11
- def self.list_local_mount_points
12
- deb 'Maybe its abuot time you refactor that method here :)'
13
- RicDisk.interesting_mount_points
14
- end
9
+ def self.list_local_mount_points
10
+ deb 'Maybe its abuot time you refactor that method here :)'
11
+ RicDisk.interesting_mount_points
12
+ end
15
13
 
16
- def self.list_all
17
- RicDisk.interesting_mount_points
18
- end
14
+ def self.list_all
15
+ RicDisk.interesting_mount_points
16
+ end
19
17
 
20
- def self.list_all_with_type
21
- list_all.map { |x| [:mount_point_todo_less_generic, x] }
22
- end
23
- end
18
+ def self.list_all_with_type
19
+ list_all.map { |x| [:mount_point_todo_less_generic, x] }
24
20
  end
25
21
  end
26
22
  end