18 #ifndef MCONFIGURATION_H
19 #define MCONFIGURATION_H
23 #ifdef MCLIENTLIB_EXPORTS
24 #define MCLIENTLIB_API __declspec(dllexport)
26 #define MCLIENTLIB_API __declspec(dllimport)
30 #ifndef MCLIENTLIB_EXPORTS
32 #define MCLIENTLIB_API
34 #define MCLIENTLIB_API
37 #define MCLIENTLIB_API
42 #pragma warning(disable: 4251)
47 namespace MClientLib {
58 bool getEngineStartup();
59 bool getEnableWebServer();
61 void setEngineStartup(
bool);
62 void setEnableWebServer(
bool);
75 std::string historyDbName;
79 void setUsername(
const std::string&);
80 void setPassword(
const std::string&);
81 void setAddress(
const std::string&);
82 void setEngine(
const std::string&);
83 void setDbName(
const std::string&);
84 void setHistoryDbName(
const std::string&);
86 std::string getUsername();
87 std::string getPassword();
88 std::string getAddress();
89 std::string getEngine();
90 std::string getDbName();
91 std::string getHistoryDbName();
99 bool removeOrphanedInstances;
100 int instancesDistinguish;
101 bool requeueOnDisconnection;
102 bool requeueOnTimeout;
103 int requeueOnTimeoutTimer;
104 bool requeueKillActiveRenders;
105 int maximumChunksRequeue;
106 bool submitPausedJobs;
108 bool enableNTAutomapping;
109 bool subchunksCalculateProgress;
110 bool parallelRendering;
111 bool ignorePrioritiesAtFolderLevel;
112 std::vector<MDriveMap*> driveMappings;
113 int NTAutomappingDisconnectionPolicy;
114 bool buildStatusArray;
115 bool substitutionIsCaseSensitive;
116 bool makeTemplatesSnapshots;
117 bool flagCompletedJobsAsArchived;
118 bool flagJobsAsArchived;
119 int flagJobAsArchivedAmount;
120 int flagJobsAsArchivedCounterType;
121 bool prefilterParentPool;
122 std::string impersonationUsername;
123 std::string impersonationPassword;
128 bool getRemoveOrphanedInstances();
129 int getInstancesDistinguish();
130 bool getRequeueOnDisconnection();
131 bool getRequeueOnTimeout();
132 int getRequeueOnTimeoutTimer();
133 bool getRequeueKillActiveRenders();
134 int getOverrideMaximumChunksRequeueValue();
135 bool getSubmitPausedJobs();
136 int getMaximumThreads();
137 bool getEnableNTAutomapping();
138 bool getSubchunksCalculateProgress();
139 bool getParallelRendering();
140 bool getIgnorePrioritiesAtFolderLevel();
141 std::vector<MClientLib::MDriveMap> getDriveMappings();
143 int getNTAutomappingDisconnectionPolicy();
144 bool getBuildStatusArray();
145 bool getSubstitutionIsCaseSensitive();
146 bool getMakeTemplatesSnapshots();
147 bool getFlagCompletedJobsAsArchived();
148 bool getFlagJobsAsArchived();
149 int getFlagJobAsArchivedAmount();
150 int getFlagJobsAsArchivedCounterType();
151 bool getPrefilterParentPool();
152 std::string getImpersonationUsername();
153 std::string getImpersonationPassword();
155 void setRemoveOrphanedInstances(
bool);
156 void setInstancesDistinguish(
int);
157 void setRequeueOnDisconnection(
bool);
158 void setRequeueOnTimeout(
bool);
159 void setRequeueOnTimeoutTimer(
int);
160 void setRequeueKillActiveRenders(
bool);
161 void setOverrideMaximumChunksRequeueValue(
int);
162 void setSubmitPausedJobs(
bool);
163 void setMaximumThreads(
int);
164 void setEnableNTAutomapping(
bool);
165 void setSubchunksCalculateProgress(
bool);
166 void setParallelRendering(
bool);
167 void setIgnorePrioritiesAtFolderLevel(
bool);
168 void setDriveMappings(std::vector<MClientLib::MDriveMap>);
169 void setNTAutomappingDisconnectionPolicy(
int);
170 void setBuildStatusArray(
bool);
171 void setSubstitutionIsCaseSensitive(
bool);
172 void setMakeTemplatesSnapshots(
bool);
173 void setFlagCompletedJobsAsArchived(
bool);
174 void setFlagJobsAsArchived(
bool);
175 void setFlagJobAsArchivedAmount(
int);
176 void setFlagJobsAsArchivedCounterType(
int);
177 void setPrefilterParentPool(
bool);
178 void setImpersonationUsername(
const std::string&);
179 void setImpersonationPassword(
const std::string&);
190 int sendMailLogResolution;
191 bool logSystemEvents;
193 bool logClientsEvents;
194 bool logClientsErrorsEvents;
198 std::string activityLogsFolder;
199 bool clearActivityLogsOlderThan;
200 int clearActivityLogsOlderThanDays;
201 bool clearActivityLogsExceeds;
202 int clearActivityLogsExceedsMB;
203 int activityLogsSeverity;
205 std::string actionsLogsFolder;
206 bool clearActionsLogsOlderThan;
207 int clearActionsLogsOlderThanDays;
208 bool clearActionsLogsExceeds;
209 int clearActionsLogsExceedsMB;
215 int getAutoClearLimit();
216 bool getSendMailLog();
217 int getSendMailLogResolution();
218 bool getLogSystemEvents();
219 bool getLogUsersEvents();
220 bool getLogClientsEvents();
221 bool getLogClientsErrorsEvents();
222 bool getLogCommandLine();
223 bool getLogReturnCodes();
225 std::string getActivityLogsFolder();
226 bool getClearActivityLogsOlderThan();
227 int getClearActivityLogsOlderThanDays();
228 bool getClearActivityLogsExceeds();
229 int getClearActivityLogsExceedsMB();
230 int getActivityLogsSeverity();
232 std::string getActionsLogsFolder();
233 bool getClearActionsLogsOlderThan();
234 int getClearActionsLogsOlderThanDays();
235 bool getClearActionsLogsExceeds();
236 int getClearActionsLogsExceedsMB();
238 void setAutoClear(
bool);
239 void setAutoClearLimit(
int);
240 void setSendMailLog(
bool);
241 void setSendMailLogResolution(
int);
242 void setLogSystemEvents(
bool);
243 void setLogUsersEvents(
bool);
244 void setLogClientsEvents(
bool);
245 void setLogClientsErrorsEvents(
bool);
246 void setLogCommandLine(
bool);
247 void setLogReturnCodes(
bool);
249 void setActivityLogsFolder(
const std::string&);
250 void setClearActivityLogsOlderThan(
bool);
251 void setClearActivityLogsOlderThanDays(
int);
252 void setClearActivityLogsExceeds(
bool);
253 void setClearActivityLogsExceedsMB(
int);
254 void setActivityLogsSeverity(
int);
256 void setActionsLogsFolder(
const std::string&);
257 void setClearActionsLogsOlderThan(
bool);
258 void setClearActionsLogsOlderThanDays(
int);
259 void setClearActionsLogsExceeds(
bool);
260 void setClearActionsLogsExceedsMB(
int);
268 bool notifyEngineStatusChanges;
269 bool notifySoftRestarts;
270 bool notifyConfigsChanges;
271 bool notifyExclusions;
272 bool notifyJobsStarts;
273 bool notifyJobsCompletion;
277 bool getNotifyEngineStatusChanges();
278 bool getNotifySoftRestarts();
279 bool getNotifyConfigsChanges();
280 bool getNotifyExclusions();
281 bool getNotifyJobsStarts();
282 bool getNotifyJobsCompletion();
284 void setNotifyEngineStatusChanges(
bool);
285 void setNotifySoftRestarts(
bool);
286 void setNotifyConfigsChanges(
bool);
287 void setNotifyExclusions(
bool);
288 void setNotifyJobsStarts(
bool);
289 void setNotifyJobsCompletion(
bool);
298 std::string smtpServer;
299 std::string smtpAccount;
301 std::string smtpAuthLogin;
302 std::string smtpAuthPassword;
303 std::string smtpDestination;
304 bool enableMailOnJobCompletion;
305 std::string jobCompletionType;
306 bool enableMailOnChunkCompletion;
307 std::string chunkCompletionType;
309 std::string templateJobSuccess;
310 std::string templateJobError;
311 std::string templateJobRequeue;
312 std::string templateChunkSuccess;
313 std::string templateChunkError;
314 std::string templateLog;
315 std::string templateLogEntry;
320 std::string getSmtpServer();
321 std::string getSmtpAccount();
323 std::string getSmtpAuthLogin();
324 std::string getSmtpAuthPassword();
325 std::string getSmtpDestination();
326 bool getEnableMailOnJobCompletion();
327 std::string getJobCompletionType();
328 bool getEnableMailOnChunkCompletion();
329 std::string getChunkCompletionType();
331 std::string getTemplateJobSuccess();
332 std::string getTemplateJobError();
333 std::string getTemplateJobRequeue();
334 std::string getTemplateChunkSuccess();
335 std::string getTemplateChunkError();
336 std::string getTemplateLog();
337 std::string getTemplateLogEntry();
339 void setSmtpServer(
const std::string&);
340 void setSmtpAccount(
const std::string&);
341 void setSmtpAuth(
bool);
342 void setSmtpAuthLogin(
const std::string&);
343 void setSmtpAuthPassword(
const std::string&);
344 void setSmtpDestination(
const std::string&);
345 void setEnableMailOnJobCompletion(
bool);
346 void setJobCompletionType(
const std::string&);
347 void setEnableMailOnChunkCompletion(
bool);
348 void setChunkCompletionType(
const std::string&);
350 void setTemplateJobSuccess(
const std::string&);
351 void setTemplateJobError(
const std::string&);
352 void setTemplateJobRequeue(
const std::string&);
353 void setTemplateChunkSuccess(
const std::string&);
354 void setTemplateChunkError(
const std::string&);
355 void setTemplateLog(
const std::string&g);
356 void setTemplateLogEntry(
const std::string&);
368 bool enableKeepAlive;
369 int keepAliveResolution;
371 int controlIncomingBuffer;
372 int controlOutgoingBuffer;
373 int clientIncomingBuffer;
374 int clientOutgoingBuffer;
375 int notificatorOutgoingBuffer;
377 bool broadcastStatistics;
378 int broadcastStatisticsResolution;
379 int statisticsSampleResolution;
381 int wakeupOnLanDelay;
382 int wakeupOnLanMaximumAttempts;
383 int wakeupOnLanWarmup;
389 int getControlPort();
391 bool getEnableKeepAlive();
392 int getKeepAliveResolution();
393 int getControlIncomingBuffer();
394 int getControlOutgoingBuffer();
395 int getClientIncomingBuffer();
396 int getClientOutgoingBuffer();
397 int getNotificatorOutgoingBuffer();
398 bool getBroadcastStatistics();
399 int getBroadcastStatisticsResolution();
400 int getStatisticsSampleResolution();
401 int getWakeupOnLanDelay();
402 int getWakeupOnLanMaximumAttempts();
403 int getWakeupOnLanWarmup();
405 void setClientPort(
int);
406 void setControlPort(
int);
407 void setNotifyPort(
int);
408 void setEnableKeepAlive(
bool);
409 void setKeepAliveResolution(
int);
410 void setControlIncomingBuffer(
int);
411 void setControlOutgoingBuffer(
int);
412 void setClientIncomingBuffer(
int);
413 void setClientOutgoingBuffer(
int);
414 void setNotificatorOutgoingBuffer(
int);
415 void setBroadcastStatistics(
bool);
416 void setBroadcastStatisticsResolution(
int);
417 void setStatisticsSampleResolution(
int);
418 void setWakeupOnLanDelay(
int);
419 void setWakeupOnLanMaximumAttempts(
int);
420 void setWakeupOnLanWarmup(
int);
430 int maximumBandwidth;
432 int defaultServingThreads;
433 int maximumServingThreads;
434 int maximumPendingConnections;
435 bool enableCompression;
441 int getMaximumBandwidth();
442 int getSocketTimeout();
443 int getDefaultServingThreads();
444 int getMaximumServingThreads();
445 int getMaximumPendingConnections();
446 bool getEnableCompression();
448 void setHttpPort(
int);
449 void setHttpsPort(
int);
450 void setMaximumBandwidth(
int);
451 void setSocketTimeout(
int);
452 void setDefaultServingThreads(
int);
453 void setMaximumServingThreads(
int);
454 void setMaximumPendingConnections(
int);
455 void setEnableCompression(
bool);
463 bool enableLogWarning;
464 bool logWarningPauseJob;
465 bool logWarningPauseNode;
466 bool logWarningAddTemplateToExclusion;
467 bool logWarningAddJobToExclusion;
468 bool logWarningRequeueChunk;
471 bool logErrorPauseJob;
472 bool logErrorPauseNode;
473 bool logErrorAddTemplateToExclusion;
474 bool logErrorAddJobToExclusion;
475 bool logErrorRequeueChunk;
477 bool enableExitCodeWarning;
478 bool exitCodeWarningPauseJob;
479 bool exitCodeWarningPauseNode;
480 bool exitCodeWarningAddTemplateToExclusion;
481 bool exitCodeWarningAddJobToExclusion;
482 bool exitCodeWarningRequeueChunk;
484 bool enableExitCodeError;
485 bool exitCodeErrorPauseJob;
486 bool exitCodeErrorPauseNode;
487 bool exitCodeErrorAddTemplateToExclusion;
488 bool exitCodeErrorAddJobToExclusion;
489 bool exitCodeErrorRequeueChunk;
491 bool processPauseJob;
492 bool processPauseNode;
493 bool processAddTemplateToExclusion;
494 bool processAddJobToExclusion;
495 bool processRequeueChunk;
497 bool timeoutPauseJob;
498 bool timeoutPauseNode;
499 bool timeoutAddTemplateToExclusion;
500 bool timeoutAddJobToExclusion;
501 bool timeoutKillAnyClient;
506 bool getEnableLogWarning();
507 bool getLogWarningPauseJob();
508 bool getLogWarningPauseNode();
509 bool getLogWarningAddTemplateToExclusion();
510 bool getLogWarningAddJobToExclusion();
511 bool getLogWarningRequeueChunk();
513 bool getEnableLogError();
514 bool getLogErrorPauseJob();
515 bool getLogErrorPauseNode();
516 bool getLogErrorAddTemplateToExclusion();
517 bool getLogErrorAddJobToExclusion();
518 bool getLogErrorRequeueChunk();
520 bool getEnableExitCodeWarning();
521 bool getExitCodeWarningPauseJob();
522 bool getExitCodeWarningPauseNode();
523 bool getExitCodeWarningAddTemplateToExclusion();
524 bool getExitCodeWarningAddJobToExclusion();
525 bool getExitCodeWarningRequeueChunk();
527 bool getEnableExitCodeError();
528 bool getExitCodeErrorPauseJob();
529 bool getExitCodeErrorPauseNode();
530 bool getExitCodeErrorAddTemplateToExclusion();
531 bool getExitCodeErrorAddJobToExclusion();
532 bool getExitCodeErrorRequeueChunk();
534 bool getProcessPauseJob();
535 bool getProcessPauseNode();
536 bool getProcessAddTemplateToExclusion();
537 bool getProcessAddJobToExclusion();
538 bool getProcessRequeueChunk();
540 bool getTimeoutPauseJob();
541 bool getTimeoutPauseNode();
542 bool getTimeoutAddTemplateToExclusion();
543 bool getTimeoutAddJobToExclusion();
544 bool getTimeoutKillAnyClient();
546 void setEnableLogWarning(
bool);
547 void setLogWarningPauseJob(
bool);
548 void setLogWarningPauseNode(
bool);
549 void setLogWarningAddTemplateToExclusion(
bool);
550 void setLogWarningAddJobToExclusion(
bool);
551 void setLogWarningRequeueChunk(
bool);
553 void setEnableLogError(
bool);
554 void setLogErrorPauseJob(
bool);
555 void setLogErrorPauseNode(
bool);
556 void setLogErrorAddTemplateToExclusion(
bool);
557 void setLogErrorAddJobToExclusion(
bool);
558 void setLogErrorRequeueChunk(
bool);
560 void setEnableExitCodeWarning(
bool);
561 void setExitCodeWarningPauseJob(
bool);
562 void setExitCodeWarningPauseNode(
bool);
563 void setExitCodeWarningAddTemplateToExclusion(
bool);
564 void setExitCodeWarningAddJobToExclusion(
bool);
565 void setExitCodeWarningRequeueChunk(
bool);
567 void setEnableExitCodeError(
bool);
568 void setExitCodeErrorPauseJob(
bool);
569 void setExitCodeErrorPauseNode(
bool);
570 void setExitCodeErrorAddTemplateToExclusion(
bool);
571 void setExitCodeErrorAddJobToExclusion(
bool);
572 void setExitCodeErrorRequeueChunk(
bool);
574 void setProcessPauseJob(
bool);
575 void setProcessPauseNode(
bool);
576 void setProcessAddTemplateToExclusion(
bool);
577 void setProcessAddJobToExclusion(
bool);
578 void setProcessRequeueChunk(
bool);
580 void setTimeoutPauseJob(
bool);
581 void setTimeoutPauseNode(
bool);
582 void setTimeoutAddTemplateToExclusion(
bool);
583 void setTimeoutAddJobToExclusion(
bool);
584 void setTimeoutKillAnyClient(
bool);
594 bool jobFailurePauseJob;
595 bool jobFailureLockJob;
596 bool chunkFailureAddJobToExclusion;
597 bool chunkFailureAddTemplateToExclusion;
598 bool chunkFailureRequeueChunk;
599 bool chunkFailureAbortProcessing;
601 bool preJobActionEnabled;
602 std::string preJobAction;
603 bool preJobActionCheckReturnCode;
604 int preJobActionReturnCode;
605 bool preJobActionOverrideTimeout;
606 int preJobActionTimeout;
608 bool postJobActionEnabled;
609 std::string postJobAction;
610 bool postJobActionCheckReturnCode;
611 int postJobActionReturnCode;
612 bool postJobActionOverrideTimeout;
613 int postJobActionTimeout;
615 bool preChunkActionEnabled;
616 std::string preChunkAction;
617 bool preChunkActionCheckReturnCode;
618 int preChunkActionReturnCode;
619 bool preChunkActionOverrideTimeout;
620 int preChunkActionTimeout;
622 bool postChunkActionEnabled;
623 std::string postChunkAction;
624 bool postChunkActionCheckReturnCode;
625 int postChunkActionReturnCode;
626 bool postChunkActionOverrideTimeout;
627 int postChunkActionTimeout;
632 int getActionTimeout();
633 bool getJobFailurePauseJob();
634 bool getJobFailureLockJob();
635 bool getChunkFailureAddJobToExclusion();
636 bool getChunkFailureAddTemplateToExclusion();
637 bool getChunkFailureRequeueChunk();
638 bool getChunkFailureAbortProcessing();
640 bool getPreJobActionEnabled();
641 std::string getPreJobAction();
642 bool getPreJobActionCheckReturnCode();
643 int getPreJobActionReturnCode();
644 bool getPreJobActionOverrideTimeout();
645 int getPreJobActionTimeout();
647 bool getPostJobActionEnabled();
648 std::string getPostJobAction();
649 bool getPostJobActionCheckReturnCode();
650 int getPostJobActionReturnCode();
651 bool getPostJobActionOverrideTimeout();
652 int getPostJobActionTimeout();
654 bool getPreChunkActionEnabled();
655 std::string getPreChunkAction();
656 bool getPreChunkActionCheckReturnCode();
657 int getPreChunkActionReturnCode();
658 bool getPreChunkActionOverrideTimeout();
659 int getPreChunkActionTimeout();
661 bool getPostChunkActionEnabled();
662 std::string getPostChunkAction();
663 bool getPostChunkActionCheckReturnCode();
664 int getPostChunkActionReturnCode();
665 bool getPostChunkActionOverrideTimeout();
666 int getPostChunkActionTimeout();
668 void setActionTimeout(
int);
669 void setJobFailurePauseJob(
bool);
670 void setJobFailureLockJob(
bool);
671 void setChunkFailureAddJobToExclusion(
bool);
672 void setChunkFailureAddTemplateToExclusion(
bool);
673 void setChunkFailureRequeueChunk(
bool);
674 void setChunkFailureAbortProcessing(
bool);
676 void setPreJobActionEnabled(
bool);
677 void setPreJobAction(std::string);
678 void setPreJobActionCheckReturnCode(
bool);
679 void setPreJobActionReturnCode(
int);
680 void setPreJobActionOverrideTimeout(
bool);
681 void setPreJobActionTimeout(
int);
683 void setPostJobActionEnabled(
bool);
684 void setPostJobAction(std::string);
685 void setPostJobActionCheckReturnCode(
bool);
686 void setPostJobActionReturnCode(
int);
687 void setPostJobActionOverrideTimeout(
bool);
688 void setPostJobActionTimeout(
int);
690 void setPreChunkActionEnabled(
bool);
691 void setPreChunkAction(std::string);
692 void setPreChunkActionCheckReturnCode(
bool);
693 void setPreChunkActionReturnCode(
int);
694 void setPreChunkActionOverrideTimeout(
bool);
695 void setPreChunkActionTimeout(
int);
697 void setPostChunkActionEnabled(
bool);
698 void setPostChunkAction(std::string);
699 void setPostChunkActionCheckReturnCode(
bool);
700 void setPostChunkActionReturnCode(
int);
701 void setPostChunkActionOverrideTimeout(
bool);
702 void setPostChunkActionTimeout(
int);
722 bool Unmarshall(std::vector<std::string>& items);
723 std::string Marshall();
735 std::string serverAddress;
738 std::string groupsBaseDN;
740 std::string bindUsername;
741 std::string bindPassword;
742 bool updateAutomatically;
743 int updateResolution;
745 std::string userLDAPAttribute;
746 std::string userLDAPFilter;
747 std::string userADAttribute;
748 std::string userADFilter;
749 std::string groupLDAPAttribute;
750 std::string groupLDAPFilter;
751 std::string groupADAttribute;
752 std::string groupADFilter;
753 std::string userADGroupAttribute;
754 std::string userLDAPGroupAttribute;
755 std::string userADEmailAttribute;
756 std::string userLDAPEmailAttribute;
760 bool getEnableBindings();
762 int getEncryptionType();
763 std::string getServerAddress();
765 std::string getBaseDN();
766 std::string getGroupsBaseDN();
767 std::string getBindDN();
768 std::string getBindUsername();
769 std::string getBindPassword();
770 bool getUpdateAutomatically();
771 int getUpdateResolution();
773 std::string getUserLDAPAttribute();
774 std::string getUserLDAPFilter();
775 std::string getUserADAttribute();
776 std::string getUserADFilter();
777 std::string getGroupLDAPAttribute();
778 std::string getGroupLDAPFilter();
779 std::string getGroupADAttribute();
780 std::string getGroupADFilter();
781 std::string getUserADGroupAttribute();
782 std::string getUserLDAPGroupAttribute();
783 std::string getUserADEmailAttribute();
784 std::string getUserLDAPEmailAttribute();
786 void setEnableBindings(
bool);
787 void setServerType(
int);
788 void setEncryptionType(
int);
789 void setServerAddress(
const std::string&);
790 void setServerPort(
int);
791 void setBaseDN(
const std::string&);
792 void setGroupsBaseDN(
const std::string&);
793 void setBindDN(
const std::string&);
794 void setBindUsername(
const std::string&);
795 void setBindPassword(
const std::string&);
796 void setUpdateAutomatically(
bool);
797 void setUpdateResolution(
int);
799 void setUserLDAPAttribute(
const std::string&);
800 void setUserLDAPFilter(
const std::string&);
801 void setUserADAttribute(
const std::string&);
802 void setUserADFilter(
const std::string&);
803 void setGroupLDAPAttribute(
const std::string&);
804 void setGroupLDAPFilter(
const std::string&);
805 void setGroupADAttribute(
const std::string&);
806 void setGroupADFilter(
const std::string&);
807 void setUserADGroupAttribute(
const std::string&);
808 void setUserLDAPGroupAttribute(
const std::string&);
809 void setUserADEmailAttribute(
const std::string&);
810 void setUserLDAPEmailAttribute(
const std::string&);
812 bool Unmarshall(std::vector<std::string>& items);
813 std::string Marshall();