Actor Framework: Difference between revisions
No edit summary |
m Move to Category:Messaging frameworks |
||
(10 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
The '''Actor Framework''' is an Actor Model implementation that has been distributed with LabVIEW since [[LabVIEW 2012]]. | |||
* To learn more about the [https://en.wikipedia.org/wiki/Actor_model Actor Model click here for the Wikipedia article]. | |||
* To learn about other community created Actor implementations see the"Other Actor Implementation Designs" section on the [[Actor Oriented Design Patterns]] page. | |||
==Introduction== | |||
The '''Actor Framework''' introduces two main classes: | |||
# The Actor class | |||
# The Message class | |||
The basic Actor only does something only when it receives a message telling it to do something. What it is supposed to do is tied to the message that was sent. It can either execute something and be done until the next message, it can launch other Actors, or it can send more messages. In the Actor Framework it is limited to sending messages to itself, to the Actor that launched it (if it is not the root Actor), or to Actors it launched. | |||
[[File:Actor Framework Communication.png|frame|center|Actor Framework message communication (from Jon McBee's article " FUN WITH THE ACTOR FRAMEWORK: PUB/SUB")]] | |||
'' | ===The Message Class=== | ||
A basic Message Class contains only two methods: | |||
# '''Do.vi''' - calls the method that contains the code that is the action for the Actor to execute | |||
# '''Send [Name of Message].vi''' - requires the enqueuer (address) of the Actor to send the message to, which causes the message to be sent to that Actor | |||
===The Actor Class=== | |||
A basic Actor only needs to contain the methods that the messages call. However, there are some optional overrides that can extend the functionality of the Actor. They include: | |||
* Actor Core.vi | |||
* Handle Error.vi | |||
* Handle Last Ack Core.vi | |||
* Pre Launch Init.vi | |||
* Receive Message.vi | |||
* Stop Core.vi | |||
* Substitute Actor.vi | |||
More to come on when and why one might want to override these methods. | |||
== External Links == | == External Links == | ||
*[https://www.youtube.com/watch?v=2k3ZDwJolbA&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth "Complete LabVIEW Actor Framework Tutorial Series"] by [https://www.linkedin.com/in/thomasmcquillan/ Tom McQuillan], [https://www.youtube.com/tomslabviewadventure Tom's LabVIEW Adventure] | |||
** [https://www.youtube.com/watch?v=2k3ZDwJolbA&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=1 "1. Recap of Modular Applications in LabVIEW"] | |||
** [https://www.youtube.com/watch?v=dxLAR7mMyA8&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=2 "2. Deriving the Actor Core in Actor Framework (The Command Pattern)"] | |||
** [https://www.youtube.com/watch?v=110rGrrJ3yc&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=3 "3. Creating Your First Actor - Hello World!"] | |||
** [https://www.youtube.com/watch?v=mqJqHGGTwbk&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=4 "4. User Interface Basics with Actor Core Override"] | |||
** [https://www.youtube.com/watch?v=2u-MukJ-Heg&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=5 "5. User Events in Actor Framework (+ Chat Window Project Intro)"] | |||
** [https://www.youtube.com/watch?v=e2z4YTvH5zU&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=6 "6. Actor System Design and Messaging"] | |||
** [https://www.youtube.com/watch?v=PYGo3bEEEPk&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=7 "7. How Actor Systems Stop and What Happens When an Error Occurs"] | |||
** [https://www.youtube.com/watch?v=p--8oUMsZDE&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=8 "8. User Interfaces in Actor Framework and User Event Scripting"] | |||
** [https://www.youtube.com/watch?v=eTaufgA7Lkc&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=9 "9. Abstract Messages in LabVIEW Actor Framework"] | |||
** [https://www.youtube.com/watch?v=AJUQQtoQSGA&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=10 "10. Top Five Actor Framework Overrides"] | |||
** [https://www.youtube.com/watch?v=uUopETUSAJw&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=11 "11. Using Subpanels with the LabVIEW Actor Framework"] | |||
** [https://www.youtube.com/watch?v=wnyG-59U6pw&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=12 "12. LabVIEW Maps (feat. Actor Framework)"] | |||
** New for LabVIEW 2020! [https://www.youtube.com/watch?v=oYUow2c-nCE&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=13 "Interface Messages in Actor Framework - Never create an Abstract Message again!"] | |||
**New in LabVIEW NXG (> 4.0)[https://www.youtube.com/watch?v=48oaT4r90oE&list=PLmF-6jvwRvVNFzBjzh4bQDjFbv6lShcth&index=14 "Trying out Actor Framework in LabVIEW NXG 4.0..."] | |||
*Actor Framework Basics by [https://www.linkedin.com/in/derek-trepanier/ Derek E. Trepanier], Moore Good Ideas | |||
** [http://www.mooregoodideas.com/actor-framework/basics/AF-basics-part-1/ "Actor Framework Basics: Part 1 - the Basics"] | |||
** [http://www.mooregoodideas.com/actor-framework/basics/AF-basics-part-2/ "Actor Framework Basics: Part 2 - the Actor"] | |||
** [http://www.mooregoodideas.com/actor-framework/basics/AF-basics-part-3/ "Actor Framework Basics: Part 3 - Launching and Communicating"] | |||
** [http://www.mooregoodideas.com/actor-framework/basics/AF-basics-part-4/ "Actor Framework Basics: Part 4 - Being Productive With Actors"] | |||
** [http://www.mooregoodideas.com/actor-framework/basics/AF-basics-walkthrough/ "Actor Framework Basics: Walkthrough - Creating a Logger Actor"] | |||
*[http://forums.ni.com/t5/Labvolution/LabVIEW-Actor-Framework-Basics/ba-p/3476654 "Actor Framework Basics"] by Greg Payne, Labvolution. | |||
*[http://www.labviewcraftsmen.com/blog/fun-with-the-actor-framework-pubsub "Fun with the Actor Framework: PUB/SUB"] by [https://www.linkedin.com/in/jon-mcbee/ Jon McBee], LabVIEW Craftsmen Blog | |||
*[[Convert Queued Message Handler (QMH) to Actor Framework (AF)|"Actor Framework is not as hard as you think and here is why…"]] by Quentin "Q" Alldredge, Q Software Innovations, LLC | |||
*[https://forums.ni.com/t5/Actor-Framework/ct-p/7001 NI Community]. | *[https://forums.ni.com/t5/Actor-Framework/ct-p/7001 NI Community]. | ||
*[https://forums.ni.com/t5/Actor-Framework-Documents/READ-THIS-FIRST-to-get-started-with-Actor-Framework/ta-p/3493762 NI Introduction]. | *[https://forums.ni.com/t5/Actor-Framework-Documents/READ-THIS-FIRST-to-get-started-with-Actor-Framework/ta-p/3493762 NI Introduction]. | ||
*[ | *[https://learn.ni.com/center-of-excellence/resources/863/choosing-a-framework Comparison of AF and DQMH] by [[Samuel_Taggart_(LabVIEW_Champion)|Sam Taggart]], [https://automatedenver.com System Automation Solutions] | ||
[[Category:Actor Framework]] | [[Category:Actor Framework]] | ||
[[Category: | [[Category:Messaging frameworks]] |
Latest revision as of 13:15, 1 September 2024
The Actor Framework is an Actor Model implementation that has been distributed with LabVIEW since LabVIEW 2012.
- To learn more about the Actor Model click here for the Wikipedia article.
- To learn about other community created Actor implementations see the"Other Actor Implementation Designs" section on the Actor Oriented Design Patterns page.
Introduction
The Actor Framework introduces two main classes:
- The Actor class
- The Message class
The basic Actor only does something only when it receives a message telling it to do something. What it is supposed to do is tied to the message that was sent. It can either execute something and be done until the next message, it can launch other Actors, or it can send more messages. In the Actor Framework it is limited to sending messages to itself, to the Actor that launched it (if it is not the root Actor), or to Actors it launched.
The Message Class
A basic Message Class contains only two methods:
- Do.vi - calls the method that contains the code that is the action for the Actor to execute
- Send [Name of Message].vi - requires the enqueuer (address) of the Actor to send the message to, which causes the message to be sent to that Actor
The Actor Class
A basic Actor only needs to contain the methods that the messages call. However, there are some optional overrides that can extend the functionality of the Actor. They include:
- Actor Core.vi
- Handle Error.vi
- Handle Last Ack Core.vi
- Pre Launch Init.vi
- Receive Message.vi
- Stop Core.vi
- Substitute Actor.vi
More to come on when and why one might want to override these methods.
External Links
- "Complete LabVIEW Actor Framework Tutorial Series" by Tom McQuillan, Tom's LabVIEW Adventure
- "1. Recap of Modular Applications in LabVIEW"
- "2. Deriving the Actor Core in Actor Framework (The Command Pattern)"
- "3. Creating Your First Actor - Hello World!"
- "4. User Interface Basics with Actor Core Override"
- "5. User Events in Actor Framework (+ Chat Window Project Intro)"
- "6. Actor System Design and Messaging"
- "7. How Actor Systems Stop and What Happens When an Error Occurs"
- "8. User Interfaces in Actor Framework and User Event Scripting"
- "9. Abstract Messages in LabVIEW Actor Framework"
- "10. Top Five Actor Framework Overrides"
- "11. Using Subpanels with the LabVIEW Actor Framework"
- "12. LabVIEW Maps (feat. Actor Framework)"
- New for LabVIEW 2020! "Interface Messages in Actor Framework - Never create an Abstract Message again!"
- New in LabVIEW NXG (> 4.0)"Trying out Actor Framework in LabVIEW NXG 4.0..."
- Actor Framework Basics by Derek E. Trepanier, Moore Good Ideas
- "Actor Framework Basics" by Greg Payne, Labvolution.
- "Fun with the Actor Framework: PUB/SUB" by Jon McBee, LabVIEW Craftsmen Blog
- "Actor Framework is not as hard as you think and here is why…" by Quentin "Q" Alldredge, Q Software Innovations, LLC
- NI Community.
- NI Introduction.
- Comparison of AF and DQMH by Sam Taggart, System Automation Solutions