Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [milo-dev] Subscription execution interval

This is intentional because fixed rate executions can "stack" when execution of the task takes longer than the period it's scheduled for. 

This can lead to:

1) simultaneous execution of the fixed rate tasks
and/or 
2) eventual OutOfMemory exception as the number of outstanding tasks grows unbounded

I'm not sure if the spec has anything to say about how the implementation handles regular publishing, but maybe it's possible that Milo can measure how long it takes to run the publish logic and then account for that when it schedules the next ::onPublishingTimer.

On Mon, Oct 30, 2017 at 7:29 AM, Tomoaki Matsuda <thoimroe@xxxxxxxxx> wrote:
Eclipse milo team members

Hello, I am doing the work of investigating and verifying the software.
I had the opportunity to use Eclipse milo and found it to be great software.
Your work is wonderful.

Well, I have a question.
I tried the prepared example of this project,
I encountered that SubscriptionExample execution delayed.
It seems to be related to the Subscription class.

1.startPublilshingTimer
        subscriptionManager.getServer (). getScheduledExecutorService (). schedule (
            this :: onPublishingTimer,
            interval,
            TimeUnit.MILLISECONDS
        );

2.onPublishingTimer
        timerHandler.whenNormal ();

3.whenNormal, whenLate, whenKeepAlive
        startPublishingTimer ();

Assuming that the interval is 1000 ms and the execution time of onPublishingTimer and whenNormal is 1 ms,
One publish becomes 1001 ms.

Trial, when I described the startPublishingTimer as follows, the delay ceased.

        subscriptionManager.getServer (). getScheduledExecutorService (). scheduleAtFixedRate (
                this :: onPublishingTimer,
                0,
                interval,
                TimeUnit.MILLISECONDS
        );

However, it is impossible to monitor the state of Publish.

Is this delay specification OPC-UA, or Eclipse milo?

I am sorry for my poor English.

thanks.

_______________________________________________
milo-dev mailing list
milo-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/milo-dev



Back to the top