echi-converter 0.3.5 → 0.3.6
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +10 -2
- data/bin/echi-converter +6 -0
- data/config/application.yml +1 -1
- data/lib/echi-converter.rb +4 -2
- data/lib/echi-converter/version.rb +1 -1
- data/website/index.html +2 -2
- metadata +99 -92
data/History.txt
CHANGED
@@ -156,9 +156,17 @@
|
|
156
156
|
* Added option in config/application.yml, 'max_ftp_sessions', to allow for multiple ftp sessions to be used to increase ftp interaction performance
|
157
157
|
* Bug fix(es):
|
158
158
|
|
159
|
-
== 0.3.5 2007-12-
|
159
|
+
== 0.3.5 2007-12-03
|
160
160
|
|
161
161
|
* Major enhancement(s):
|
162
162
|
* Minor enhancement(s):
|
163
163
|
* Bug fix(es):
|
164
|
-
* Fixed a bug with the ASCII processing that left out the agent_released field in the table and data, causing a misalignment.
|
164
|
+
* Fixed a bug with the ASCII processing that left out the agent_released field in the table and data, causing a misalignment.
|
165
|
+
|
166
|
+
== 0.3.6 2007-12-20
|
167
|
+
|
168
|
+
* Major enhancement(s):
|
169
|
+
* Minor enhancement(s):
|
170
|
+
* Added a Signal.trap on interrupt to echi-converter executable for a more graceful shutdown
|
171
|
+
* Bug fix(es):
|
172
|
+
* The bit operators in the boolean fields are now processed properly for BINARY file types (found by user Chun Lim)
|
data/bin/echi-converter
CHANGED
@@ -2,8 +2,14 @@
|
|
2
2
|
require 'rubygems'
|
3
3
|
require 'daemons'
|
4
4
|
require 'fileutils'
|
5
|
+
require 'yaml'
|
5
6
|
include FileUtils
|
6
7
|
|
8
|
+
Signal.trap("INT") do
|
9
|
+
puts "Shutting down process: " + $$.to_s
|
10
|
+
Process.exit
|
11
|
+
end
|
12
|
+
|
7
13
|
usage = "Usage:
|
8
14
|
echi-converter create myproject - create the local project to run the ECHI converter from (on Windows, directory names must not have spaces)
|
9
15
|
echi-converter upgrade myproject - location of project to upgrade after a new gem version is installed"
|
data/config/application.yml
CHANGED
@@ -5,7 +5,7 @@ echi_host: localhost
|
|
5
5
|
echi_port: 21
|
6
6
|
echi_username: anonymous
|
7
7
|
echi_password:
|
8
|
-
echi_connect_type: ftp #only ftp supported now, possible for ssh in the future
|
8
|
+
echi_connect_type: ftp #only ftp supported now, possible for ssh/sftp in the future
|
9
9
|
echi_ftp_directory: #/Users/ftp/anonymous #If blank/nil, the system will not do a CD at the start
|
10
10
|
echi_ftp_retry: 10
|
11
11
|
echi_ftp_delete: Y #to not delete the files off of the FTP server set to N, Y to delete the files
|
data/lib/echi-converter.rb
CHANGED
@@ -221,6 +221,7 @@ module EchiConverter
|
|
221
221
|
#in order to commit as one atomic action upon success
|
222
222
|
EchiRecord.transaction do
|
223
223
|
bool_cnt = 0
|
224
|
+
bytearray = nil
|
224
225
|
@record_cnt = 0
|
225
226
|
while @binary_file.eof == FALSE do
|
226
227
|
@log.debug '<====================START RECORD ' + @record_cnt.to_s + ' ====================>'
|
@@ -234,8 +235,8 @@ module EchiConverter
|
|
234
235
|
#Ensure we parse the bytearray and set the appropriate flags
|
235
236
|
#We need to make sure the entire array is not nil, in order to do Y/N
|
236
237
|
#if Nil we then set all no
|
237
|
-
if bytearray !=
|
238
|
-
if bytearray.slice(bool_cnt,1) == 1
|
238
|
+
if bytearray != '00000000'
|
239
|
+
if bytearray.slice(bool_cnt,1) == '1'
|
239
240
|
value = 'Y'
|
240
241
|
else
|
241
242
|
value = 'N'
|
@@ -243,6 +244,7 @@ module EchiConverter
|
|
243
244
|
else
|
244
245
|
value = 'N'
|
245
246
|
end
|
247
|
+
@log.debug field["name"] + " { type => #{field["type"]} & length => #{field["length"]} } value => " + value.to_s
|
246
248
|
bool_cnt += 1
|
247
249
|
if bool_cnt == 8
|
248
250
|
bool_cnt = 0
|
data/website/index.html
CHANGED
@@ -33,7 +33,7 @@
|
|
33
33
|
<h1>ECHI Converter</h1>
|
34
34
|
<div id="version" class="clickable" onclick='document.location = "http://rubyforge.org/projects/echi-converter"; return false'>
|
35
35
|
<p>Get Version</p>
|
36
|
-
<a href="http://rubyforge.org/projects/echi-converter" class="numbers">0.3.
|
36
|
+
<a href="http://rubyforge.org/projects/echi-converter" class="numbers">0.3.6</a>
|
37
37
|
</div>
|
38
38
|
<h1>→ ‘echi-converter’</h1>
|
39
39
|
|
@@ -260,7 +260,7 @@
|
|
260
260
|
|
261
261
|
<p>Comments are welcome. Send an email to <a href="mailto:jason@goecke.net">jason [at] goecke.net</a>.</p>
|
262
262
|
<p class="coda">
|
263
|
-
<a href="mailto:drnicwilliams@gmail.com">Dr Nic</a>,
|
263
|
+
<a href="mailto:drnicwilliams@gmail.com">Dr Nic</a>, 4th December 2007<br>
|
264
264
|
Theme extended from <a href="http://rb2js.rubyforge.org/">Paul Battley</a>
|
265
265
|
</p>
|
266
266
|
</div>
|
metadata
CHANGED
@@ -1,100 +1,21 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
|
-
rubygems_version: 0.9.4
|
3
|
-
specification_version: 1
|
4
2
|
name: echi-converter
|
5
3
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.3.
|
7
|
-
|
8
|
-
summary: ECHI Conversion Utility - Provides a utility to fetch Avaya CMS / ECHI binary files, convert them and insert into a database table via ActiveRecord
|
9
|
-
require_paths:
|
10
|
-
- lib
|
11
|
-
email: jason [at] goecke.net
|
12
|
-
homepage: http://echi-converter.rubyforge.org
|
13
|
-
rubyforge_project: echi-converter
|
14
|
-
description: ECHI Conversion Utility - Provides a utility to fetch Avaya CMS / ECHI binary files, convert them and insert into a database table via ActiveRecord
|
15
|
-
autorequire:
|
16
|
-
default_executable:
|
17
|
-
bindir: bin
|
18
|
-
has_rdoc: true
|
19
|
-
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
20
|
-
requirements:
|
21
|
-
- - ">"
|
22
|
-
- !ruby/object:Gem::Version
|
23
|
-
version: 0.0.0
|
24
|
-
version:
|
25
|
-
platform: ruby
|
26
|
-
signing_key:
|
27
|
-
cert_chain:
|
28
|
-
post_install_message:
|
4
|
+
version: 0.3.6
|
5
|
+
platform: ""
|
29
6
|
authors:
|
30
7
|
- Jason Goecke
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
- Manifest.txt
|
35
|
-
- README.txt
|
36
|
-
- Rakefile
|
37
|
-
- lib/main.rb
|
38
|
-
- lib/echi-converter/version.rb
|
39
|
-
- lib/database.rb
|
40
|
-
- lib/database_presence.rb
|
41
|
-
- lib/main_win32.rb
|
42
|
-
- lib/echi-converter.rb
|
43
|
-
- lib/ftp_fetcher.rb
|
44
|
-
- scripts/txt2html
|
45
|
-
- setup.rb
|
46
|
-
- test/test_echi-converter.rb
|
47
|
-
- test/test_helper.rb
|
48
|
-
- website/index.html
|
49
|
-
- website/index.txt
|
50
|
-
- website/javascripts/rounded_corners_lite.inc.js
|
51
|
-
- website/stylesheets/screen.css
|
52
|
-
- website/template.rhtml
|
53
|
-
- config/application.yml
|
54
|
-
- config/database.yml
|
55
|
-
- config/extended_version12.yml
|
56
|
-
- config/extended_version13.yml
|
57
|
-
- config/standard_version12.yml
|
58
|
-
- config/standard_version13.yml
|
59
|
-
- config/install_files.yml
|
60
|
-
- db/migrate/001_create_echi_records.rb
|
61
|
-
- db/migrate/002_create_echi_logs.rb
|
62
|
-
- db/migrate/003_create_echi_agents.rb
|
63
|
-
- db/migrate/004_change_log_name_size.rb
|
64
|
-
- db/migrate/005_change_log_processedat_name.rb
|
65
|
-
- db/migrate/006_create_echi_aux_reasons.rb
|
66
|
-
- db/migrate/007_create_echi_cwcs.rb
|
67
|
-
- db/migrate/008_create_echi_vdns.rb
|
68
|
-
- bin/echi-converter
|
69
|
-
- examples/extended_version12/chr0003
|
70
|
-
- examples/extended_version12/chr0003.txt
|
71
|
-
- examples/schemas/oracle_echi.sql
|
72
|
-
- examples/ascii_csv/chr5500.123
|
73
|
-
- examples/db_connect_test.rb
|
74
|
-
test_files:
|
75
|
-
- test/test_echi-converter.rb
|
76
|
-
- test/test_helper.rb
|
77
|
-
rdoc_options:
|
78
|
-
- --main
|
79
|
-
- README.txt
|
80
|
-
extra_rdoc_files:
|
81
|
-
- History.txt
|
82
|
-
- License.txt
|
83
|
-
- Manifest.txt
|
84
|
-
- README.txt
|
85
|
-
- website/index.txt
|
86
|
-
- examples/extended_version12/chr0003.txt
|
87
|
-
executables:
|
88
|
-
- echi-converter
|
89
|
-
extensions: []
|
90
|
-
|
91
|
-
requirements: []
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
92
11
|
|
12
|
+
date: 2007-12-20 00:00:00 -08:00
|
13
|
+
default_executable:
|
93
14
|
dependencies:
|
94
15
|
- !ruby/object:Gem::Dependency
|
95
16
|
name: activerecord
|
96
17
|
version_requirement:
|
97
|
-
version_requirements: !ruby/object:Gem::
|
18
|
+
version_requirements: !ruby/object:Gem::Requirement
|
98
19
|
requirements:
|
99
20
|
- - ">="
|
100
21
|
- !ruby/object:Gem::Version
|
@@ -103,7 +24,7 @@ dependencies:
|
|
103
24
|
- !ruby/object:Gem::Dependency
|
104
25
|
name: activesupport
|
105
26
|
version_requirement:
|
106
|
-
version_requirements: !ruby/object:Gem::
|
27
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
28
|
requirements:
|
108
29
|
- - ">="
|
109
30
|
- !ruby/object:Gem::Version
|
@@ -112,7 +33,7 @@ dependencies:
|
|
112
33
|
- !ruby/object:Gem::Dependency
|
113
34
|
name: daemons
|
114
35
|
version_requirement:
|
115
|
-
version_requirements: !ruby/object:Gem::
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
116
37
|
requirements:
|
117
38
|
- - ">="
|
118
39
|
- !ruby/object:Gem::Version
|
@@ -121,7 +42,7 @@ dependencies:
|
|
121
42
|
- !ruby/object:Gem::Dependency
|
122
43
|
name: fastercsv
|
123
44
|
version_requirement:
|
124
|
-
version_requirements: !ruby/object:Gem::
|
45
|
+
version_requirements: !ruby/object:Gem::Requirement
|
125
46
|
requirements:
|
126
47
|
- - ">="
|
127
48
|
- !ruby/object:Gem::Version
|
@@ -130,7 +51,7 @@ dependencies:
|
|
130
51
|
- !ruby/object:Gem::Dependency
|
131
52
|
name: rake
|
132
53
|
version_requirement:
|
133
|
-
version_requirements: !ruby/object:Gem::
|
54
|
+
version_requirements: !ruby/object:Gem::Requirement
|
134
55
|
requirements:
|
135
56
|
- - ">="
|
136
57
|
- !ruby/object:Gem::Version
|
@@ -139,9 +60,95 @@ dependencies:
|
|
139
60
|
- !ruby/object:Gem::Dependency
|
140
61
|
name: uuidtools
|
141
62
|
version_requirement:
|
142
|
-
version_requirements: !ruby/object:Gem::
|
63
|
+
version_requirements: !ruby/object:Gem::Requirement
|
143
64
|
requirements:
|
144
65
|
- - ">="
|
145
66
|
- !ruby/object:Gem::Version
|
146
67
|
version: 1.0.1
|
147
68
|
version:
|
69
|
+
description: ECHI Conversion Utility - Provides a utility to fetch Avaya CMS / ECHI binary files, convert them and insert into a database table via ActiveRecord
|
70
|
+
email: jason [at] goecke.net
|
71
|
+
executables:
|
72
|
+
- echi-converter
|
73
|
+
extensions: []
|
74
|
+
|
75
|
+
extra_rdoc_files:
|
76
|
+
- History.txt
|
77
|
+
- License.txt
|
78
|
+
- Manifest.txt
|
79
|
+
- README.txt
|
80
|
+
- website/index.txt
|
81
|
+
- examples/extended_version12/chr0003.txt
|
82
|
+
files:
|
83
|
+
- History.txt
|
84
|
+
- License.txt
|
85
|
+
- Manifest.txt
|
86
|
+
- README.txt
|
87
|
+
- Rakefile
|
88
|
+
- lib/main.rb
|
89
|
+
- lib/echi-converter/version.rb
|
90
|
+
- lib/database.rb
|
91
|
+
- lib/database_presence.rb
|
92
|
+
- lib/main_win32.rb
|
93
|
+
- lib/echi-converter.rb
|
94
|
+
- lib/ftp_fetcher.rb
|
95
|
+
- scripts/txt2html
|
96
|
+
- setup.rb
|
97
|
+
- test/test_echi-converter.rb
|
98
|
+
- test/test_helper.rb
|
99
|
+
- website/index.html
|
100
|
+
- website/index.txt
|
101
|
+
- website/javascripts/rounded_corners_lite.inc.js
|
102
|
+
- website/stylesheets/screen.css
|
103
|
+
- website/template.rhtml
|
104
|
+
- config/application.yml
|
105
|
+
- config/database.yml
|
106
|
+
- config/extended_version12.yml
|
107
|
+
- config/extended_version13.yml
|
108
|
+
- config/standard_version12.yml
|
109
|
+
- config/standard_version13.yml
|
110
|
+
- config/install_files.yml
|
111
|
+
- db/migrate/001_create_echi_records.rb
|
112
|
+
- db/migrate/002_create_echi_logs.rb
|
113
|
+
- db/migrate/003_create_echi_agents.rb
|
114
|
+
- db/migrate/004_change_log_name_size.rb
|
115
|
+
- db/migrate/005_change_log_processedat_name.rb
|
116
|
+
- db/migrate/006_create_echi_aux_reasons.rb
|
117
|
+
- db/migrate/007_create_echi_cwcs.rb
|
118
|
+
- db/migrate/008_create_echi_vdns.rb
|
119
|
+
- bin/echi-converter
|
120
|
+
- examples/extended_version12/chr0003
|
121
|
+
- examples/extended_version12/chr0003.txt
|
122
|
+
- examples/schemas/oracle_echi.sql
|
123
|
+
- examples/ascii_csv/chr5500.123
|
124
|
+
- examples/db_connect_test.rb
|
125
|
+
has_rdoc: true
|
126
|
+
homepage: http://echi-converter.rubyforge.org
|
127
|
+
post_install_message:
|
128
|
+
rdoc_options:
|
129
|
+
- --main
|
130
|
+
- README.txt
|
131
|
+
require_paths:
|
132
|
+
- lib
|
133
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
134
|
+
requirements:
|
135
|
+
- - ">="
|
136
|
+
- !ruby/object:Gem::Version
|
137
|
+
version: "0"
|
138
|
+
version:
|
139
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
140
|
+
requirements:
|
141
|
+
- - ">="
|
142
|
+
- !ruby/object:Gem::Version
|
143
|
+
version: "0"
|
144
|
+
version:
|
145
|
+
requirements: []
|
146
|
+
|
147
|
+
rubyforge_project: echi-converter
|
148
|
+
rubygems_version: 0.9.5
|
149
|
+
signing_key:
|
150
|
+
specification_version: 2
|
151
|
+
summary: ECHI Conversion Utility - Provides a utility to fetch Avaya CMS / ECHI binary files, convert them and insert into a database table via ActiveRecord
|
152
|
+
test_files:
|
153
|
+
- test/test_echi-converter.rb
|
154
|
+
- test/test_helper.rb
|