NIFI-232:

- Adding a note in the UI that the Event Driven scheduling strategy is experimental.
This commit is contained in:
Matt Gilman 2015-01-07 14:08:13 -05:00
parent 9531219293
commit edaa191d37
3 changed files with 34 additions and 9 deletions

View File

@ -102,6 +102,10 @@
<div type="text" id="scheduling-strategy-combo"></div> <div type="text" id="scheduling-strategy-combo"></div>
</div> </div>
</div> </div>
<div id="event-driven-warning" class="hidden">
<div id="event-driven-warning-icon"></div>
This strategy is experimental
</div>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<div id="timer-driven-options" class="setting"> <div id="timer-driven-options" class="setting">

View File

@ -111,6 +111,21 @@ div.processor-enabled-container {
line-height: 18px; line-height: 18px;
} }
#event-driven-warning {
padding-top: 22px;
color: #f00;
}
#event-driven-warning-icon {
float: left;
margin-top: -2px;
margin-right: 5px;
margin-left: 5px;
width: 18px;
height: 16px;
background-image: url(../images/iconAlert.png);
}
#auto-terminate-relationship-names { #auto-terminate-relationship-names {
border: 0 solid #CCCCCC; border: 0 solid #CCCCCC;
height: 280px; height: 280px;

View File

@ -37,14 +37,14 @@ nf.ProcessorConfiguration = (function () {
strategies.push({ strategies.push({
text: 'Event driven', text: 'Event driven',
value: 'EVENT_DRIVEN', value: 'EVENT_DRIVEN',
description: 'Processor will be scheduled to run when triggered by an event (e.g. a FlowFile enters an incoming queue).' description: 'Processor will be scheduled to run when triggered by an event (e.g. a FlowFile enters an incoming queue). This scheduling strategy is experimental.'
}); });
} else if (processor.config['schedulingStrategy'] === 'EVENT_DRIVEN') { } else if (processor.config['schedulingStrategy'] === 'EVENT_DRIVEN') {
// the processor was once configured for event driven but no longer supports it // the processor was once configured for event driven but no longer supports it
strategies.push({ strategies.push({
text: 'Event driven', text: 'Event driven',
value: 'EVENT_DRIVEN', value: 'EVENT_DRIVEN',
description: 'Processor will be scheduled to run when triggered by an event (e.g. a FlowFile enters an incoming queue).', description: 'Processor will be scheduled to run when triggered by an event (e.g. a FlowFile enters an incoming queue). This scheduling strategy is experimental.',
disabled: true disabled: true
}); });
} }
@ -506,17 +506,23 @@ nf.ProcessorConfiguration = (function () {
select: function (selectedOption) { select: function (selectedOption) {
// show the appropriate panel // show the appropriate panel
if (selectedOption.value === 'EVENT_DRIVEN') { if (selectedOption.value === 'EVENT_DRIVEN') {
$('#event-driven-warning').show();
$('#timer-driven-options').hide(); $('#timer-driven-options').hide();
$('#event-driven-options').show(); $('#event-driven-options').show();
$('#cron-driven-options').hide(); $('#cron-driven-options').hide();
} else if (selectedOption.value === 'CRON_DRIVEN') {
$('#timer-driven-options').hide();
$('#event-driven-options').hide();
$('#cron-driven-options').show();
} else { } else {
$('#timer-driven-options').show(); $('#event-driven-warning').hide();
$('#event-driven-options').hide();
$('#cron-driven-options').hide(); if (selectedOption.value === 'CRON_DRIVEN') {
$('#timer-driven-options').hide();
$('#event-driven-options').hide();
$('#cron-driven-options').show();
} else {
$('#timer-driven-options').show();
$('#event-driven-options').hide();
$('#cron-driven-options').hide();
}
} }
} }
}); });