win32-service 0.8.6 → 0.8.7

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9eb593fe954a9ad9baa295314a6deba834e416f5
4
- data.tar.gz: b8ddb7267b81ea05bcf0c211ab684d07571a2d5b
3
+ metadata.gz: 9c2d9406b19292d6d66131600aa2e18a15d193da
4
+ data.tar.gz: cf2ba8abfcfe003ad3f00e44887ab195b0439115
5
5
  SHA512:
6
- metadata.gz: 59a97083e2ff8900d2f80244a6313452e8479f8d577abee74b6af9bc1a397979d28d043537d6b22c49a90d8d287b1423e53f8349cc2d4ae76022df3c58285bd0
7
- data.tar.gz: cd0285acd389d078041dd27252c0da1880044b5100f8f848d323b05bbacf9c86d541f2d0c3dd696f70f075745f1949dcafebdf677ca330c8dfdb7c701ae36962
6
+ metadata.gz: 13bb69b43beacc04a54bdc387b4fa78604bd48c147be9ead2c50958216d26ebac91161f64a62fc19262e01d409c2523969437439f4c676ccd5b68acc27f46f10
7
+ data.tar.gz: f08fc1b91207ae51e1399580b54b275ad36baf048b66ccf93009568e4f18072593c7acb3b008d76a528a77e79959cd2523b9122438cc4bbb32dfbd2b7f076cd1
data/CHANGES CHANGED
@@ -1,301 +1,306 @@
1
- == 0.8.6 - 21-Aug-2014
2
- * Some internal changes that make stopping a service more robust. Thanks go
3
- to Ethan J. Brown for the patches.
4
- * Renamed the constants module to avoid name clashes. Thanks go to Michael
5
- Smith for the spot.
6
-
7
- == 0.8.5 - 2-Jul-2014
8
- * The service type for Service.new no longer defaults to being an interactive
9
- process. This could cause process credential issues and wasn't very
10
- useful in practice anyway. Thanks go to Pierre Ynard for the report.
11
- * More tests skipped unless run with admin privileges.
12
- * Use relative_require instead of doing things manually.
13
- * Minor memory efficieny improvements.
14
- * Skip errors on ERROR_RESOURCE_TYPE_NOT_FOUND when getting service config info.
15
- Thanks go to Rob Reynolds for the patch.
16
-
17
- == 0.8.4 - 23-Jan-2014
18
- * Added support for the delayed start startup type. Thanks go to Jim Arnold
19
- for the patch.
20
- * Fixed the service test that ensures that trying to start an already running
21
- service will raise an error. Thanks again to Jim Arnold for the patch.
22
-
23
- == 0.8.3 - 1-Nov-2013
24
- * Fixed a bug where a service's state could be changed when merely
25
- interrogating the service. Thanks go to Glenn Sarti / Puppet Labs
26
- for the spot.
27
- * Fixed a bug where attempting to get the description of a service that
28
- has no description could raise an error. Now an empty string is returned.
29
-
30
- == 0.8.2 - 13-Aug-2013
31
- * Fixed a bug in the Service.start method where it was not handling arguments
32
- properly. Thanks go to Sean Karlage for the spot.
33
-
34
- == 0.8.1 - 2-Aug-2013
35
- * Fixed the failure actions code for the Service#configure method
36
- so that it is also using FFI.
37
- * An internal fix for the Daemon class was added. In short, you no longer
38
- need to, nor should you, call exit! in a service_stop method. Thanks go
39
- to Adrian Candaten for pointing out the issue in general.
40
- * Made FFI functions private.
41
- * Added Rake as a development dependency.
42
- * Removed an internal helper function that was no longer being used.
43
-
44
- == 0.8.0 - 19-Jun-2013
45
- * Converted all code to use FFI. This includes the Daemon code, which means
46
- that it also now works with JRuby.
47
-
48
- == 0.7.2 - 7-Sep-2011
49
- * Now works with mingw compiler by skipping __try and __finally if using
50
- mingw, or using them with mingw if the seh.h header is found.
51
- * The binary gem now contains binaries for both Ruby 1.8.7 and 1.9.2 using
52
- a simple wrapper.
53
- * Updated some Rake tasks.
54
-
55
- == 0.7.1 - 9-Feb-2010
56
- * Compatibility fixes for 1.9.x.
57
- * Fixed a bug where the controls_accepted struct member was always nil. This
58
- has been fixed and now always returns an array.
59
- * Added 'pre-shutdown' as possible values for the list of controls accepted.
60
- * Changed test-unit from a runtime dependency to a development dependency.
61
- * Some tests were refactored to be more reliable.
62
- * Refactored the Rakefile and gemspec.
63
-
64
- == 0.7.0 - 30-Jun-2009
65
- * INTERFACE CHANGE: The Service.new and Service.configure methods now accept
66
- a single hash argument only. The :service_name key is mandatory, while the
67
- :host key is optional.
68
- * Fixed a bug in the Service.services method where a segfault would occur if
69
- the binary_path_name was greater than 260 characters. The buffer size has
70
- been increased to 1024 characters. Thanks go to Dan Daniels for the spot.
71
- * Altered the Daemon class so that the Ruby interpreter was not invoked within
72
- the Service_Main function. The functions that close stdin, stdout and stderr
73
- are now called within the mainloop method. Thanks go to Tim Hanson for the
74
- spot and the patch.
75
- * Eliminated a minor build warning in daemon.c
76
- * License changed to Artistic 2.0, with corresponding gemspec update.
77
- * Added an uninstall rake task.
78
- * Updated the service_stop method in the demo_daemon.rb file, and added some
79
- additional comments.
80
- * The test files were renamed.
81
- * Several tests were updated and refactored to use Test::Unit 2.x. That
82
- library is now a dependency.
83
- * The 'uninstall' Rakefile task is now more verbose.
84
-
85
- == 0.6.1 - 1-Jan-2008
86
- * The Service.services method now handles the scenario where a particular
87
- service may still exist, but its underlying registry entry has been deleted.
88
- In this case, most ServiceInfo struct members are set to nil and a warning
89
- is issued.
90
- * RDoc updates.
91
-
92
- == 0.6.0 - 25-Nov-2007
93
- * The Service control class is now pure Ruby. The Daemon class is still C,
94
- however. That may change in the future. This means the windows-pr
95
- library is now a prerequisite.
96
- * The Service.new method has been altered in a way that is not backwards
97
- compatible. It is now the same as Service.create.
98
- * The Service.start method now properly handles arguments to the
99
- Daemon#service_main method.
100
- * The Daemon source code is now separate from the Service control class
101
- source code. That means you must require them separately, as needed.
102
- * The Daemon class should be much more responsive to service events now,
103
- especially service_stop. Many thanks go to Kevin Burge for the patch.
104
- * Added the Daemon.mainloop method as a shortcut for Daemon.new.mainloop.
105
- * The Daemon class now redirects STDIN, STDOUT and STDERR to the NUL device
106
- if they're still associated with a terminal when the service starts. This
107
- should help prevent Errno::EBADF errors.
108
- * The Service.services class method now supports the group parameter for
109
- versions of Ruby built with older compilers, i.e. it will now work with
110
- the one-click Ruby installer.
111
- * The Service.getdisplayname method was changed to Service.get_display_name.
112
- An alias has been provided for backwards compatibility.
113
- * The Service.getservicename method was changed to Service.get_service_name.
114
- An alias has been provided for backwards compatibility.
115
- * Added the Service.config_info method.
116
- * The Service.create and Service.configure methods now allow you to set
117
- failure actions, failure commands, and reset/retry periods.
118
- * Improved test suite.
119
- * Changed 'tdaemon.rb', 'tdaemon_ctl.rb' and 'service_test.rb' to
120
- 'demo_daemon.rb', 'demo_daemon_ctl.rb' and 'demo_services.rb', respectively.
121
- * Some refactoring and updates to the demo daemon and demo daemon controller
122
- examples.
123
- * The Win32Service struct is now ServiceInfo.
124
- * ServiceError is now Service::Error.
125
- * DaemonError is now Daemon::Error.
126
- * Some documentation improvements, corrections and updates.
127
-
128
- == 0.5.2 - 25-Nov-2006
129
- * Fixed a bug in the Daemon class where the service event handling methods
130
- (most notably service_stop) did not work properly due to thread blocking
131
- issues. Many thanks go to Patrick Hurley for the patch.
132
- * Added the Daemon#running? method as helper method for your service_main
133
- method.
134
- * The 'interactive?' struct member is now just 'interactive'. This was
135
- supposed to have been in the last release but was somehow missed. Sorry.
136
- * Scrapped the old daemon_test.rb file and split it into two new files -
137
- tdaemon.rb and tdaemon_ctl.rb. In the process a few bugs were fixed.
138
- * Added a gemspec.
139
- * Documentation and test suite updates.
140
-
141
- == 0.5.1 - 18-Jun-2006
142
- * Added the Service.open method.
143
- * The Service.new method now accepts a block, and automatically closes itself
144
- at the end of the block.
145
- * Fixed in a bug in the Service.create method where setting dependencies
146
- was not working properly. Thanks go to Scott Harper for the spot.
147
- * The 'interactive?' struct member is now just 'interactive' since Ruby no
148
- longer supports question marks in struct member names. UGH.
149
- * The block for Service#configure_service is no longer optional.
150
- * Replaced ClipSrv with W32Time for most of the test methods in tc_service.rb
151
- because it had a dependency that is disabled on most systems.
152
- * Added a tweak to the extconf.rb file to help with the test suite.
153
- * Some documentation updates and corrections.
154
-
155
- == 0.5.0 - 26-Nov-2005
156
- * Added a service_init hook, and (internally) altered the way the service
157
- starts. This was done to deal with services that need to perform any
158
- initialization in the Daemon itself before the service starts. Previously
159
- this would result in the service timing out during startup.
160
-
161
- Thanks go to Jamey Cribbs for spotting the problem.
162
-
163
- * Modified the Daemon example, adding a service_init hook that does about 10
164
- seconds worth of initialization before finally starting. See the comments
165
- in examples\daemon_test.rb for more information.
166
- * Minor test and README changes.
167
-
168
- == 0.4.6 - 24-May-2005
169
- * Fixed an initialization bug that could cause Daemons to fail unless the
170
- win32-service package was the last package require'd.
171
- * Altered the Service.start method. It now takes any number of arguments
172
- (after the service and host name). These arguments are passed to the
173
- service's Service_Main() function.
174
- * The Service.services method now returns an Array of ServiceStruct's in
175
- non-block form.
176
- * The Service.start, Service.pause, Service.resume, Service.stop and
177
- Service.delete methods now return the class (self), not 'true'.
178
- * Added the ability to add or configure the service description in
179
- Service#create_service or Service#configure, respectively.
180
- * Fixed a bug in the Service.start method where false positives could result.
181
- * Updated the ServiceStatus struct to include pid and service_flags on Win2k
182
- or later.
183
- * Unicode is now the default setting as far as internal string handling. It
184
- will still work fine with 'regular' text.
185
- * Added safe string handling for string input values.
186
- * Added rdoc comments into the C source.
187
- * Made the service.txt and daemon.txt files rdoc friendly.
188
- * Removed the service.rd and daemon.rd files. If you want html documentation,
189
- run rdoc over the service.txt and daemon.txt files.
190
- * The dreaded "code cleanup".
191
-
192
- == 0.4.5 - 28-Feb-2005
193
- * Fixed an accessor bug in Service#create. Thanks go to Nathaniel Talbott
194
- for the spot.
195
- * Eliminated a warning that appeared starting in Ruby 1.8.2 regarding Struct
196
- redefinitions.
197
- * Moved 'examples' directory to toplevel directory.
198
- * Deleted the 'test2.rb' example. This was supplanted by the 'daemon_test.rb'
199
- script.
200
- * Renamed the 'test.rb' file to 'services_test.rb'.
201
- * Made this document rdoc friendly.
202
-
203
- == 0.4.4 - 27-Aug-2004
204
- * Modified the Service class to use the newer allocation framework. The
205
- Daemon class already used this, hence no major version bump.
206
- * Fixed in a bug in the create_service() method with regards to the
207
- 'dependencies' option and null arguments (you no longer need to specify
208
- an empty array).
209
-
210
- == 0.4.3 - 14-Aug-2004
211
- * Fixed the Daemon class by adding back the constants it needed in order to
212
- run. I accidentally broke this when I changed the Daemon class from being
213
- a subclass of Service to being its own class.
214
- * Added a separate test suite for the Daemon class, tc_daemon.rb, to help
215
- me from making that mistake ever again. :)
216
- * Updated the daemon_test.rb script a bit to report error messages should
217
- any occur.
218
- * Minor doc updates
219
-
220
- == 0.4.2 - 10-Jul-2004
221
- * The Daemon class is no longer a subclass of Service.
222
- * Added the 'pid' and 'service_flags' struct members to the Win32Service
223
- struct. These members are only available to folks using Windows 2000 or
224
- later and who compile with VC++ 7.0 or later (including the .NET SDK).
225
- * The Service.services method now accepts a group name as an optional third
226
- argument. Again, you must be using Windows 2000 or later and compile with
227
- VC++ 7.0 or later (including the .NET SDK).
228
- * The deprecated STR2CSTR() functions were replaced with StringValuePtr().
229
- This also means that as of this version, win32-service requires Ruby
230
- 1.8.0 or greater.
231
- * Moved the sample programs to doc/examples
232
- * Removed the .html files under /doc. You can generate that on your own if
233
- you like.
234
-
235
- == 0.4.1 - 14-Mar-2004
236
- * Added the exists? class method and corresponding test suite additions.
237
- * Pushed the ServiceError and DaemonError classes under the Win32 module.
238
- * Normalized tc_service.rb so that it can be run outside of the test directory
239
- more easily.
240
-
241
- == 0.4.0 - 9-Feb-2004
242
- * Changed "worker" method to "service_main" method.
243
- * Added event hooks for stop, pause, resume, etc. See the documentation for
244
- further details. (Thanks Park Heesob)
245
- * Some of the Daemon functions were raising ServiceError. They have been
246
- changed to DaemonError.
247
- * Updated the daemon_test.rb file to use the new event hooks.
248
- * Documentation additions and updates.
249
-
250
- == 0.3.0 - 31-Jan-2004
251
- * Added a Daemon subclass. This allows you to run Ruby programs as a service.
252
- Please see the documentation for more details. (Thanks Park Heesob). This
253
- should be considered an ALPHA release.
254
- * The Win32ServiceError class has been renamed to just ServiceError. I felt
255
- the "Win32" was redundant, given that it's already under the Win32 module.
256
- * In some cases a bogus error description was being returned because the
257
- GetLastError() function was being called too late. This has been fixed.
258
- (Thanks Park Heesob).
259
- * The explicit garbage collection has been removed because what I thought was
260
- a memory leak was not, in fact, a memory leak. In addition, it was hurting
261
- performance badly.
262
- * The "\r\n" is now automatically stripped from error messages. This was
263
- causing slightly garbled error messages. (Thanks Park Heesob).
264
- * Added explicit closing of the Service Control Manager handle in the
265
- services() function for those rare cases where it may fail while reading
266
- service information.
267
- * Made some of the error strings a bit more descriptive.
268
- * Test suite and documentation additions, including a sample daemon program
269
- in the test directory called "daemon_test.rb".
270
-
271
- == 0.2.2 - 15-Jan-2004
272
- * Fixed a mistake in the service_init declaration within Init_service().
273
- * Fixed bug in the service_init function with regards to desired access.
274
- * Modified service_free() function to explicitly set the hSCManager handle
275
- to NULL and modified the service_close() method to test hSCManager handle
276
- for NULL value. This should eliminate accidentally trying to close an
277
- already closed handle, which may have happened as the result of a free()
278
- call. (Thanks Park Heesob).
279
- * Added explicit garbage collection in Service.services() method.
280
- * More explicit about closing open HANDLE's when error conditions arise.
281
-
282
- == 0.2.1 - 2-Nov-2003
283
- * Made the exported less redundant and less verbose, e.g.
284
- Service::SERVICE_DISABLED is now just Service::DISABLED. The same is true
285
- for the service control constants, i.e. the 'SC_' has been removed.
286
- * Corresponding test suite changes.
287
-
288
- == 0.2.0 - 16-Oct-2003
289
- * The constructor has been changed. It now only takes a machine name and a
290
- desired access for arguments. The keyword arguments are now part of the
291
- create_service method() and only in block form. See the documentation for
292
- more details.
293
- * Added a configure_service() and close() instance methods.
294
- * Added several new constants to allow finer control over created and
295
- configured services.
296
- * Added Win32ServiceError as an exception. All failures now raise this
297
- error instead of a vanilla StandardError.
298
- * Moved some common code into the service.h file.
299
-
300
- == 0.1.0 - 10-Oct-2003
301
- - Initial release
1
+ == 0.8.7 - 14-Jul-2014
2
+ * Fixed a bug in the SERVICE_DELAYED_AUTO_START_INFO struct. It now returns 0
3
+ or 1, though it still accepts true or false as arguments. Thanks go to
4
+ Kartik Null Cating-Subramanian for the spot.
5
+
6
+ == 0.8.6 - 21-Aug-2014
7
+ * Some internal changes that make stopping a service more robust. Thanks go
8
+ to Ethan J. Brown for the patches.
9
+ * Renamed the constants module to avoid name clashes. Thanks go to Michael
10
+ Smith for the spot.
11
+
12
+ == 0.8.5 - 2-Jul-2014
13
+ * The service type for Service.new no longer defaults to being an interactive
14
+ process. This could cause process credential issues and wasn't very
15
+ useful in practice anyway. Thanks go to Pierre Ynard for the report.
16
+ * More tests skipped unless run with admin privileges.
17
+ * Use relative_require instead of doing things manually.
18
+ * Minor memory efficieny improvements.
19
+ * Skip errors on ERROR_RESOURCE_TYPE_NOT_FOUND when getting service config info.
20
+ Thanks go to Rob Reynolds for the patch.
21
+
22
+ == 0.8.4 - 23-Jan-2014
23
+ * Added support for the delayed start startup type. Thanks go to Jim Arnold
24
+ for the patch.
25
+ * Fixed the service test that ensures that trying to start an already running
26
+ service will raise an error. Thanks again to Jim Arnold for the patch.
27
+
28
+ == 0.8.3 - 1-Nov-2013
29
+ * Fixed a bug where a service's state could be changed when merely
30
+ interrogating the service. Thanks go to Glenn Sarti / Puppet Labs
31
+ for the spot.
32
+ * Fixed a bug where attempting to get the description of a service that
33
+ has no description could raise an error. Now an empty string is returned.
34
+
35
+ == 0.8.2 - 13-Aug-2013
36
+ * Fixed a bug in the Service.start method where it was not handling arguments
37
+ properly. Thanks go to Sean Karlage for the spot.
38
+
39
+ == 0.8.1 - 2-Aug-2013
40
+ * Fixed the failure actions code for the Service#configure method
41
+ so that it is also using FFI.
42
+ * An internal fix for the Daemon class was added. In short, you no longer
43
+ need to, nor should you, call exit! in a service_stop method. Thanks go
44
+ to Adrian Candaten for pointing out the issue in general.
45
+ * Made FFI functions private.
46
+ * Added Rake as a development dependency.
47
+ * Removed an internal helper function that was no longer being used.
48
+
49
+ == 0.8.0 - 19-Jun-2013
50
+ * Converted all code to use FFI. This includes the Daemon code, which means
51
+ that it also now works with JRuby.
52
+
53
+ == 0.7.2 - 7-Sep-2011
54
+ * Now works with mingw compiler by skipping __try and __finally if using
55
+ mingw, or using them with mingw if the seh.h header is found.
56
+ * The binary gem now contains binaries for both Ruby 1.8.7 and 1.9.2 using
57
+ a simple wrapper.
58
+ * Updated some Rake tasks.
59
+
60
+ == 0.7.1 - 9-Feb-2010
61
+ * Compatibility fixes for 1.9.x.
62
+ * Fixed a bug where the controls_accepted struct member was always nil. This
63
+ has been fixed and now always returns an array.
64
+ * Added 'pre-shutdown' as possible values for the list of controls accepted.
65
+ * Changed test-unit from a runtime dependency to a development dependency.
66
+ * Some tests were refactored to be more reliable.
67
+ * Refactored the Rakefile and gemspec.
68
+
69
+ == 0.7.0 - 30-Jun-2009
70
+ * INTERFACE CHANGE: The Service.new and Service.configure methods now accept
71
+ a single hash argument only. The :service_name key is mandatory, while the
72
+ :host key is optional.
73
+ * Fixed a bug in the Service.services method where a segfault would occur if
74
+ the binary_path_name was greater than 260 characters. The buffer size has
75
+ been increased to 1024 characters. Thanks go to Dan Daniels for the spot.
76
+ * Altered the Daemon class so that the Ruby interpreter was not invoked within
77
+ the Service_Main function. The functions that close stdin, stdout and stderr
78
+ are now called within the mainloop method. Thanks go to Tim Hanson for the
79
+ spot and the patch.
80
+ * Eliminated a minor build warning in daemon.c
81
+ * License changed to Artistic 2.0, with corresponding gemspec update.
82
+ * Added an uninstall rake task.
83
+ * Updated the service_stop method in the demo_daemon.rb file, and added some
84
+ additional comments.
85
+ * The test files were renamed.
86
+ * Several tests were updated and refactored to use Test::Unit 2.x. That
87
+ library is now a dependency.
88
+ * The 'uninstall' Rakefile task is now more verbose.
89
+
90
+ == 0.6.1 - 1-Jan-2008
91
+ * The Service.services method now handles the scenario where a particular
92
+ service may still exist, but its underlying registry entry has been deleted.
93
+ In this case, most ServiceInfo struct members are set to nil and a warning
94
+ is issued.
95
+ * RDoc updates.
96
+
97
+ == 0.6.0 - 25-Nov-2007
98
+ * The Service control class is now pure Ruby. The Daemon class is still C,
99
+ however. That may change in the future. This means the windows-pr
100
+ library is now a prerequisite.
101
+ * The Service.new method has been altered in a way that is not backwards
102
+ compatible. It is now the same as Service.create.
103
+ * The Service.start method now properly handles arguments to the
104
+ Daemon#service_main method.
105
+ * The Daemon source code is now separate from the Service control class
106
+ source code. That means you must require them separately, as needed.
107
+ * The Daemon class should be much more responsive to service events now,
108
+ especially service_stop. Many thanks go to Kevin Burge for the patch.
109
+ * Added the Daemon.mainloop method as a shortcut for Daemon.new.mainloop.
110
+ * The Daemon class now redirects STDIN, STDOUT and STDERR to the NUL device
111
+ if they're still associated with a terminal when the service starts. This
112
+ should help prevent Errno::EBADF errors.
113
+ * The Service.services class method now supports the group parameter for
114
+ versions of Ruby built with older compilers, i.e. it will now work with
115
+ the one-click Ruby installer.
116
+ * The Service.getdisplayname method was changed to Service.get_display_name.
117
+ An alias has been provided for backwards compatibility.
118
+ * The Service.getservicename method was changed to Service.get_service_name.
119
+ An alias has been provided for backwards compatibility.
120
+ * Added the Service.config_info method.
121
+ * The Service.create and Service.configure methods now allow you to set
122
+ failure actions, failure commands, and reset/retry periods.
123
+ * Improved test suite.
124
+ * Changed 'tdaemon.rb', 'tdaemon_ctl.rb' and 'service_test.rb' to
125
+ 'demo_daemon.rb', 'demo_daemon_ctl.rb' and 'demo_services.rb', respectively.
126
+ * Some refactoring and updates to the demo daemon and demo daemon controller
127
+ examples.
128
+ * The Win32Service struct is now ServiceInfo.
129
+ * ServiceError is now Service::Error.
130
+ * DaemonError is now Daemon::Error.
131
+ * Some documentation improvements, corrections and updates.
132
+
133
+ == 0.5.2 - 25-Nov-2006
134
+ * Fixed a bug in the Daemon class where the service event handling methods
135
+ (most notably service_stop) did not work properly due to thread blocking
136
+ issues. Many thanks go to Patrick Hurley for the patch.
137
+ * Added the Daemon#running? method as helper method for your service_main
138
+ method.
139
+ * The 'interactive?' struct member is now just 'interactive'. This was
140
+ supposed to have been in the last release but was somehow missed. Sorry.
141
+ * Scrapped the old daemon_test.rb file and split it into two new files -
142
+ tdaemon.rb and tdaemon_ctl.rb. In the process a few bugs were fixed.
143
+ * Added a gemspec.
144
+ * Documentation and test suite updates.
145
+
146
+ == 0.5.1 - 18-Jun-2006
147
+ * Added the Service.open method.
148
+ * The Service.new method now accepts a block, and automatically closes itself
149
+ at the end of the block.
150
+ * Fixed in a bug in the Service.create method where setting dependencies
151
+ was not working properly. Thanks go to Scott Harper for the spot.
152
+ * The 'interactive?' struct member is now just 'interactive' since Ruby no
153
+ longer supports question marks in struct member names. UGH.
154
+ * The block for Service#configure_service is no longer optional.
155
+ * Replaced ClipSrv with W32Time for most of the test methods in tc_service.rb
156
+ because it had a dependency that is disabled on most systems.
157
+ * Added a tweak to the extconf.rb file to help with the test suite.
158
+ * Some documentation updates and corrections.
159
+
160
+ == 0.5.0 - 26-Nov-2005
161
+ * Added a service_init hook, and (internally) altered the way the service
162
+ starts. This was done to deal with services that need to perform any
163
+ initialization in the Daemon itself before the service starts. Previously
164
+ this would result in the service timing out during startup.
165
+
166
+ Thanks go to Jamey Cribbs for spotting the problem.
167
+
168
+ * Modified the Daemon example, adding a service_init hook that does about 10
169
+ seconds worth of initialization before finally starting. See the comments
170
+ in examples\daemon_test.rb for more information.
171
+ * Minor test and README changes.
172
+
173
+ == 0.4.6 - 24-May-2005
174
+ * Fixed an initialization bug that could cause Daemons to fail unless the
175
+ win32-service package was the last package require'd.
176
+ * Altered the Service.start method. It now takes any number of arguments
177
+ (after the service and host name). These arguments are passed to the
178
+ service's Service_Main() function.
179
+ * The Service.services method now returns an Array of ServiceStruct's in
180
+ non-block form.
181
+ * The Service.start, Service.pause, Service.resume, Service.stop and
182
+ Service.delete methods now return the class (self), not 'true'.
183
+ * Added the ability to add or configure the service description in
184
+ Service#create_service or Service#configure, respectively.
185
+ * Fixed a bug in the Service.start method where false positives could result.
186
+ * Updated the ServiceStatus struct to include pid and service_flags on Win2k
187
+ or later.
188
+ * Unicode is now the default setting as far as internal string handling. It
189
+ will still work fine with 'regular' text.
190
+ * Added safe string handling for string input values.
191
+ * Added rdoc comments into the C source.
192
+ * Made the service.txt and daemon.txt files rdoc friendly.
193
+ * Removed the service.rd and daemon.rd files. If you want html documentation,
194
+ run rdoc over the service.txt and daemon.txt files.
195
+ * The dreaded "code cleanup".
196
+
197
+ == 0.4.5 - 28-Feb-2005
198
+ * Fixed an accessor bug in Service#create. Thanks go to Nathaniel Talbott
199
+ for the spot.
200
+ * Eliminated a warning that appeared starting in Ruby 1.8.2 regarding Struct
201
+ redefinitions.
202
+ * Moved 'examples' directory to toplevel directory.
203
+ * Deleted the 'test2.rb' example. This was supplanted by the 'daemon_test.rb'
204
+ script.
205
+ * Renamed the 'test.rb' file to 'services_test.rb'.
206
+ * Made this document rdoc friendly.
207
+
208
+ == 0.4.4 - 27-Aug-2004
209
+ * Modified the Service class to use the newer allocation framework. The
210
+ Daemon class already used this, hence no major version bump.
211
+ * Fixed in a bug in the create_service() method with regards to the
212
+ 'dependencies' option and null arguments (you no longer need to specify
213
+ an empty array).
214
+
215
+ == 0.4.3 - 14-Aug-2004
216
+ * Fixed the Daemon class by adding back the constants it needed in order to
217
+ run. I accidentally broke this when I changed the Daemon class from being
218
+ a subclass of Service to being its own class.
219
+ * Added a separate test suite for the Daemon class, tc_daemon.rb, to help
220
+ me from making that mistake ever again. :)
221
+ * Updated the daemon_test.rb script a bit to report error messages should
222
+ any occur.
223
+ * Minor doc updates
224
+
225
+ == 0.4.2 - 10-Jul-2004
226
+ * The Daemon class is no longer a subclass of Service.
227
+ * Added the 'pid' and 'service_flags' struct members to the Win32Service
228
+ struct. These members are only available to folks using Windows 2000 or
229
+ later and who compile with VC++ 7.0 or later (including the .NET SDK).
230
+ * The Service.services method now accepts a group name as an optional third
231
+ argument. Again, you must be using Windows 2000 or later and compile with
232
+ VC++ 7.0 or later (including the .NET SDK).
233
+ * The deprecated STR2CSTR() functions were replaced with StringValuePtr().
234
+ This also means that as of this version, win32-service requires Ruby
235
+ 1.8.0 or greater.
236
+ * Moved the sample programs to doc/examples
237
+ * Removed the .html files under /doc. You can generate that on your own if
238
+ you like.
239
+
240
+ == 0.4.1 - 14-Mar-2004
241
+ * Added the exists? class method and corresponding test suite additions.
242
+ * Pushed the ServiceError and DaemonError classes under the Win32 module.
243
+ * Normalized tc_service.rb so that it can be run outside of the test directory
244
+ more easily.
245
+
246
+ == 0.4.0 - 9-Feb-2004
247
+ * Changed "worker" method to "service_main" method.
248
+ * Added event hooks for stop, pause, resume, etc. See the documentation for
249
+ further details. (Thanks Park Heesob)
250
+ * Some of the Daemon functions were raising ServiceError. They have been
251
+ changed to DaemonError.
252
+ * Updated the daemon_test.rb file to use the new event hooks.
253
+ * Documentation additions and updates.
254
+
255
+ == 0.3.0 - 31-Jan-2004
256
+ * Added a Daemon subclass. This allows you to run Ruby programs as a service.
257
+ Please see the documentation for more details. (Thanks Park Heesob). This
258
+ should be considered an ALPHA release.
259
+ * The Win32ServiceError class has been renamed to just ServiceError. I felt
260
+ the "Win32" was redundant, given that it's already under the Win32 module.
261
+ * In some cases a bogus error description was being returned because the
262
+ GetLastError() function was being called too late. This has been fixed.
263
+ (Thanks Park Heesob).
264
+ * The explicit garbage collection has been removed because what I thought was
265
+ a memory leak was not, in fact, a memory leak. In addition, it was hurting
266
+ performance badly.
267
+ * The "\r\n" is now automatically stripped from error messages. This was
268
+ causing slightly garbled error messages. (Thanks Park Heesob).
269
+ * Added explicit closing of the Service Control Manager handle in the
270
+ services() function for those rare cases where it may fail while reading
271
+ service information.
272
+ * Made some of the error strings a bit more descriptive.
273
+ * Test suite and documentation additions, including a sample daemon program
274
+ in the test directory called "daemon_test.rb".
275
+
276
+ == 0.2.2 - 15-Jan-2004
277
+ * Fixed a mistake in the service_init declaration within Init_service().
278
+ * Fixed bug in the service_init function with regards to desired access.
279
+ * Modified service_free() function to explicitly set the hSCManager handle
280
+ to NULL and modified the service_close() method to test hSCManager handle
281
+ for NULL value. This should eliminate accidentally trying to close an
282
+ already closed handle, which may have happened as the result of a free()
283
+ call. (Thanks Park Heesob).
284
+ * Added explicit garbage collection in Service.services() method.
285
+ * More explicit about closing open HANDLE's when error conditions arise.
286
+
287
+ == 0.2.1 - 2-Nov-2003
288
+ * Made the exported less redundant and less verbose, e.g.
289
+ Service::SERVICE_DISABLED is now just Service::DISABLED. The same is true
290
+ for the service control constants, i.e. the 'SC_' has been removed.
291
+ * Corresponding test suite changes.
292
+
293
+ == 0.2.0 - 16-Oct-2003
294
+ * The constructor has been changed. It now only takes a machine name and a
295
+ desired access for arguments. The keyword arguments are now part of the
296
+ create_service method() and only in block form. See the documentation for
297
+ more details.
298
+ * Added a configure_service() and close() instance methods.
299
+ * Added several new constants to allow finer control over created and
300
+ configured services.
301
+ * Added Win32ServiceError as an exception. All failures now raise this
302
+ error instead of a vanilla StandardError.
303
+ * Moved some common code into the service.h file.
304
+
305
+ == 0.1.0 - 10-Oct-2003
306
+ - Initial release