2. microservices architecture
microservice architectural style is:
“an approach to developing a single application as a suite of small services,
each running in its own process and communicating with lightweight
mechanisms, often an HTTP resource API. These services are built
around business capabilities and independently deployable by fully
automated deployment machinery. There is a bare minimum of
centralized management of these services, which may be written in
different programming languages and use different data storage
technologies. “
Source: http://martinfowler.com/articles/microservices.html
4. thinking serverless
The phrase “serverless” doesn’t mean servers are no longer involved. It simply
means that developers no longer have to think that much about them.
And
Going serverless lets developers shift their focus from the server level to the
task level.
By: KEN FROMM
Source: http://readwrite.com/2012/10/15/why-the-future-of-software-and-apps-is-serverless/
8. ironworker features
◻ Containerized Environment
◻ Flexible Scheduling
◻ Detailed Monitoring & Configuration
◻ High Scale Processing
◻ Multiple Language Support
(Ruby, Python, PHP, Node, Java, Scala, and Go)
9. top 10 uses of a worker system
1. Image Processing
2. Web Crawling | Data Extraction
3. Sending Push Notifications
4. Mobile Compute Cloud
5. Data Processing
6. Sending and Receiving SMS | Making Phone Calls
7. Sending Emails (SendGrid, Mailgun, Mandrill)
8. Replacing CRON with a More Reliable Cloud Scheduler
9. Processing Webhook Events
10.Adopting a Service Architecture
Source:https://www.iron.io/top-10-uses-of-ironworker/
11. getting started
◻ Iron.json
⬜ Configuration that store Iron worker token for “authentication” &
iron project id reference
◻ Node js code (.js)
⬜ Code that will be processed as iron worker task
◻Config.json (not must)
⬜ Configuration that will be passed to worker on upload step
14. steps
◻ Write worker code
◻ Create Code Package
⬜ Zip it and include all dependencies
◻ Upload Code Package
⬜ Use command line tool/iron CLI
⬜ Use Task API (Iron.io REST API)
⬜ Use wercker/3rd party integration tool
◻ Run the Worker
15. how to run iron worker
◻ Command Line using iron CLI
◻ Queue via Iron.io Dashboard
◻ Schedule via Iron.io Dashboard
◻ Programmatically using Iron Client library
◻ REST API/Webhook
16. payload
We can pass parameter or custom input dynamically to the worker via payload.
◻ Via Iron.io Queue/Schedule Form in Dashboard
⬜ Fill the payload form field with json string
◻ Via Command line
⬜ iron worker queue --payload-file payload.json
◻ Programmatically
⬜ ironWorkerClient.tasksCreate(taskName, payload)
◻ REST API/Webhook
⬜ Call API/Webhook with json payload
17. demo
1. Zip/Package the worker code
⬜ zip -r hello_fm.zip .
2. Upload Worker Code
⬜ iron worker upload --config-file config.json --zip hello_fm.zip --name hello_fm iron/node node
hello_world.js
3. Run/Queue IronWorker from command line
⬜ iron worker queue hello_fm
⬜ iron worker queue --payload-file payload.json