@@ -33,29 +33,6 @@ func newTransferPipelines(params *validatedParameters) ([]pipeline.SourcePipelin
33
33
34
34
}
35
35
36
- /*
37
- const openFileLimitForLinux = 1024
38
-
39
- //validates if the number of readers needs to be adjusted to accommodate max filehandle limits in Debian systems
40
- func adjustReaders(numOfSources int) error {
41
- if runtime.GOOS != "linux" {
42
- return nil
43
- }
44
-
45
- if (numOfSources * numberOfHandlesPerFile) > openFileLimitForLinux {
46
- numberOfHandlesPerFile = openFileLimitForLinux / (numOfSources * numberOfHandlesPerFile)
47
-
48
- if numberOfHandlesPerFile == 0 {
49
- return fmt.Errorf("The number of files will cause the process to exceed the limit of open files allowed by the OS. Reduce the number of files to be transferred")
50
- }
51
-
52
- fmt.Printf("Warning! Adjusting the number of handles per file (-h) to %v\n", numberOfHandlesPerFile)
53
-
54
- }
55
-
56
- return nil
57
- }
58
- */
59
36
type pipelinesFactory struct {
60
37
source transfer.TransferSegment
61
38
target transfer.TransferSegment
@@ -133,7 +110,7 @@ func (p *pipelinesFactory) newSourceParams() (interface{}, error) {
133
110
NumOfPartitions : p .valParams .numberOfReaders , //TODO make this more explicit by numofpartitions as param..
134
111
MD5 : p .valParams .calculateMD5 ,
135
112
KeepDirStructure : p .valParams .keepDirStructure ,
136
- FilesPerPipeline : p .valParams .numberOfIlesInBatch }, nil
113
+ FilesPerPipeline : p .valParams .numberOfFilesInBatch }, nil
137
114
case transfer .HTTP :
138
115
return sources.HTTPSourceParams {
139
116
SourceURIs : p .valParams .sourceURIs ,
@@ -151,7 +128,7 @@ func (p *pipelinesFactory) newSourceParams() (interface{}, error) {
151
128
SourceParams : sources.SourceParams {
152
129
CalculateMD5 : p .valParams .calculateMD5 ,
153
130
UseExactNameMatch : p .valParams .useExactMatch ,
154
- FilesPerPipeline : p .valParams .numberOfIlesInBatch ,
131
+ FilesPerPipeline : p .valParams .numberOfFilesInBatch ,
155
132
//default to always true so blob names are kept
156
133
KeepDirStructure : p .valParams .keepDirStructure }}, nil
157
134
case transfer .Blob :
@@ -164,10 +141,11 @@ func (p *pipelinesFactory) newSourceParams() (interface{}, error) {
164
141
SourceParams : sources.SourceParams {
165
142
CalculateMD5 : p .valParams .calculateMD5 ,
166
143
UseExactNameMatch : p .valParams .useExactMatch ,
167
- FilesPerPipeline : p .valParams .numberOfIlesInBatch ,
144
+ FilesPerPipeline : p .valParams .numberOfFilesInBatch ,
168
145
KeepDirStructure : p .valParams .keepDirStructure }}, nil
169
146
case transfer .Perf :
170
147
return sources.PerfSourceParams {
148
+ BlockSize : p .valParams .blockSize ,
171
149
Definitions : p .valParams .perfSourceDefinitions ,
172
150
SourceParams : sources.SourceParams {
173
151
CalculateMD5 : p .valParams .calculateMD5 }}, nil
0 commit comments