44
55namespace Nest
66{
7+ /// <summary>
8+ /// A snapshot repository that uses a shared file system to store snapshot data.
9+ /// The path specified in the location parameter should point to the same location in the shared
10+ /// filesystem and be accessible on all data and master nodes.
11+ /// </summary>
712 public interface IFileSystemRepository : IRepository < IFileSystemRepositorySettings > { }
813
14+ /// <inheritdoc />
915 public class FileSystemRepository : IFileSystemRepository
1016 {
1117 public FileSystemRepository ( FileSystemRepositorySettings settings ) => Settings = settings ;
@@ -15,29 +21,53 @@ public class FileSystemRepository : IFileSystemRepository
1521 public string Type { get ; } = "fs" ;
1622 }
1723
24+ /// <summary>
25+ /// Repository settings for <see cref="IFileSystemRepository"/>
26+ /// </summary>
1827 public interface IFileSystemRepositorySettings : IRepositorySettings
1928 {
29+ /// <summary>
30+ /// Big files can be broken down into chunks during the snapshot process, if needed.
31+ /// The chunk size can be specified in bytes or by using size value notation, i.e. 1g, 10m, 5k.
32+ /// Defaults to null (unlimited chunk size).
33+ /// </summary>
2034 [ DataMember ( Name = "chunk_size" ) ]
2135 string ChunkSize { get ; set ; }
2236
37+ /// <summary>
38+ /// Turns on compression of the snapshot files. Defaults to true.
39+ /// </summary>
2340 [ DataMember ( Name = "compress" ) ]
2441 [ JsonFormatter ( typeof ( NullableStringBooleanFormatter ) ) ]
2542 bool ? Compress { get ; set ; }
2643
44+ /// <summary>
45+ /// Throttles the number of streams (per node) preforming snapshot operation. Defaults to 5
46+ /// </summary>
2747 [ DataMember ( Name = "concurrent_streams" ) ]
2848 [ JsonFormatter ( typeof ( NullableStringIntFormatter ) ) ]
2949 int ? ConcurrentStreams { get ; set ; }
3050
51+ /// <summary>
52+ /// Location of the snapshots. Mandatory.
53+ /// </summary>
3154 [ DataMember ( Name = "location" ) ]
3255 string Location { get ; set ; }
3356
57+ /// <summary>
58+ /// Throttles per node restore rate. Defaults to 20mb per second.
59+ /// </summary>
3460 [ DataMember ( Name = "max_restore_bytes_per_second" ) ]
3561 string RestoreBytesPerSecondMaximum { get ; set ; }
3662
63+ /// <summary>
64+ /// Throttles per node snapshot rate. Defaults to 20mb per second.
65+ /// </summary>
3766 [ DataMember ( Name = "max_snapshot_bytes_per_second" ) ]
3867 string SnapshotBytesPerSecondMaximum { get ; set ; }
3968 }
4069
70+ /// <inheritdoc cref="IFileSystemRepositorySettings"/>
4171 public class FileSystemRepositorySettings : IFileSystemRepositorySettings
4272 {
4373 internal FileSystemRepositorySettings ( ) { }
@@ -57,6 +87,7 @@ internal FileSystemRepositorySettings() { }
5787 public string SnapshotBytesPerSecondMaximum { get ; set ; }
5888 }
5989
90+ /// <inheritdoc cref="IFileSystemRepositorySettings"/>
6091 public class FileSystemRepositorySettingsDescriptor
6192 : DescriptorBase < FileSystemRepositorySettingsDescriptor , IFileSystemRepositorySettings > , IFileSystemRepositorySettings
6293 {
@@ -67,55 +98,37 @@ public class FileSystemRepositorySettingsDescriptor
6798 string IFileSystemRepositorySettings . RestoreBytesPerSecondMaximum { get ; set ; }
6899 string IFileSystemRepositorySettings . SnapshotBytesPerSecondMaximum { get ; set ; }
69100
70- /// <summary>
71- /// Location of the snapshots. Mandatory.
72- /// </summary>
73- /// <param name="location"></param>
101+ /// <inheritdoc cref="IFileSystemRepositorySettings.Location"/>
74102 public FileSystemRepositorySettingsDescriptor Location ( string location ) => Assign ( location , ( a , v ) => a . Location = v ) ;
75103
76- /// <summary>
77- /// Turns on compression of the snapshot files. Defaults to true.
78- /// </summary>
79- /// <param name="compress"></param>
104+ /// <inheritdoc cref="IFileSystemRepositorySettings.Compress"/>
80105 public FileSystemRepositorySettingsDescriptor Compress ( bool ? compress = true ) => Assign ( compress , ( a , v ) => a . Compress = v ) ;
81106
82- /// <summary>
83- /// Throttles the number of streams (per node) preforming snapshot operation. Defaults to 5
84- /// </summary>
85- /// <param name="concurrentStreams"></param>
107+ /// <inheritdoc cref="IFileSystemRepositorySettings.ConcurrentStreams"/>
86108 public FileSystemRepositorySettingsDescriptor ConcurrentStreams ( int ? concurrentStreams ) =>
87109 Assign ( concurrentStreams , ( a , v ) => a . ConcurrentStreams = v ) ;
88110
89- /// <summary>
90- /// Big files can be broken down into chunks during snapshotting if needed.
91- /// The chunk size can be specified in bytes or by using size value notation, i.e. 1g, 10m, 5k.
92- /// Defaults to null (unlimited chunk size).
93- /// </summary>
94- /// <param name="chunkSize"></param>
111+ /// <inheritdoc cref="IFileSystemRepositorySettings.ChunkSize"/>
95112 public FileSystemRepositorySettingsDescriptor ChunkSize ( string chunkSize ) => Assign ( chunkSize , ( a , v ) => a . ChunkSize = v ) ;
96113
97- /// <summary>
98- /// Throttles per node restore rate. Defaults to 20mb per second.
99- /// </summary>
100- /// <param name="maximumBytesPerSecond"></param>
114+ /// <inheritdoc cref="IFileSystemRepositorySettings.RestoreBytesPerSecondMaximum"/>
101115 public FileSystemRepositorySettingsDescriptor RestoreBytesPerSecondMaximum ( string maximumBytesPerSecond ) =>
102116 Assign ( maximumBytesPerSecond , ( a , v ) => a . RestoreBytesPerSecondMaximum = v ) ;
103117
104- /// <summary>
105- /// Throttles per node snapshot rate. Defaults to 20mb per second.
106- /// </summary>
107- /// <param name="maximumBytesPerSecond"></param>
118+ /// <inheritdoc cref="IFileSystemRepositorySettings.SnapshotBytesPerSecondMaximum"/>
108119 public FileSystemRepositorySettingsDescriptor SnapshotBytesPerSecondMaximum ( string maximumBytesPerSecond ) =>
109120 Assign ( maximumBytesPerSecond , ( a , v ) => a . SnapshotBytesPerSecondMaximum = v ) ;
110121 }
111122
123+ /// <inheritdoc cref="IFileSystemRepository"/>
112124 public class FileSystemRepositoryDescriptor
113125 : DescriptorBase < FileSystemRepositoryDescriptor , IFileSystemRepository > , IFileSystemRepository
114126 {
115127 IFileSystemRepositorySettings IRepository < IFileSystemRepositorySettings > . Settings { get ; set ; }
116128 object IRepositoryWithSettings . DelegateSettings => Self . Settings ;
117129 string ISnapshotRepository . Type { get ; } = "fs" ;
118130
131+ /// <inheritdoc cref="IFileSystemRepositorySettings"/>
119132 public FileSystemRepositoryDescriptor Settings ( string location ,
120133 Func < FileSystemRepositorySettingsDescriptor , IFileSystemRepositorySettings > settingsSelector = null
121134 ) =>
0 commit comments