Skip to content
This repository was archived by the owner on Jan 17, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
010a069
Using conductor support in core
tardieu Nov 6, 2017
2bb6c5c
No redis
tardieu Nov 30, 2017
30ee041
Update naming convention
tardieu Nov 30, 2017
4fc37b3
Tweak
tardieu Nov 30, 2017
f543223
Hybrid composer/conductor
tardieu Jan 3, 2018
242b36b
Update openwhisk dependency
tardieu Jan 3, 2018
2d5bee7
Fixes and tests
tardieu Jan 3, 2018
4860412
Cleanup
tardieu Jan 3, 2018
316957a
No redis dependency
tardieu Jan 3, 2018
405d565
Fixes and tweaks
tardieu Jan 8, 2018
5e0c411
Check array size and element type
tardieu Jan 23, 2018
686b737
Merge branch 'master' into hybrid
tardieu Jan 23, 2018
89a9aad
Handle helper tags like other options
tardieu Jan 24, 2018
278b375
Fold taskFromFile as an option
tardieu Jan 24, 2018
d2a54c6
Implement pre and postprocessing
tardieu Jan 26, 2018
7641d23
Major rewrite
tardieu Jan 30, 2018
bf26ae1
Simplify finally implementation
tardieu Jan 30, 2018
03d18a8
Option to not retain parameters in if and while
tardieu Jan 30, 2018
6ea5138
Use objects for all options
tardieu Jan 30, 2018
d8bafd1
Many more tests
tardieu Jan 30, 2018
b3044b3
Bug fix and more tests
tardieu Jan 30, 2018
f3c0a9b
Update README.md
tardieu Jan 31, 2018
e6bd1dc
Forbid native function capture
tardieu Jan 31, 2018
caf984f
Enable defining and deploying native sequences
tardieu Jan 31, 2018
5e2c947
Pass options to composer module
tardieu Feb 1, 2018
ccac792
Restore distinction between push/pop and enter/exit state pairs
tardieu Feb 1, 2018
987ab50
Delete state labels after use
tardieu Feb 1, 2018
9473751
Fix error handling bug in while composition
tardieu Feb 1, 2018
160d135
Collapse consecutive pass states. Encode empty task with pass state.
tardieu Feb 1, 2018
77de231
Compiler tweaks
tardieu Feb 1, 2018
5130fce
New IR
tardieu Feb 3, 2018
ff44bde
Simplify FSM
tardieu Feb 3, 2018
38c6ad3
Replace FSM with simple array
tardieu Feb 3, 2018
cda8118
Generate position-independent code
tardieu Feb 3, 2018
0bbf1d5
Cleanup
tardieu Feb 3, 2018
b9ef812
Further cleanup
tardieu Feb 3, 2018
fd47337
Remove dependency
tardieu Feb 3, 2018
6ebf822
Logging
tardieu Feb 3, 2018
7f407a2
dowhile
tardieu Feb 3, 2018
d823741
Use dowhile for retry implementation
tardieu Feb 3, 2018
98ae04c
Uglify
tardieu Feb 4, 2018
a4f0e91
Compositions are always arrays
tardieu Feb 5, 2018
5c1a3c3
Add compose binary
tardieu Feb 19, 2018
0267518
Add Composition.encode method
tardieu Feb 20, 2018
a946abe
Non-destructive encode
tardieu Feb 20, 2018
3441a68
Fully qualify an action name. (#1)
rabbah Feb 21, 2018
d29ea81
add Composer.deserialize and add support for INSECURE_SSL in wskprops…
starpit Feb 22, 2018
ec0ffda
Tweaks
tardieu Feb 22, 2018
f206b70
Avoid options field with undefined value
tardieu Feb 22, 2018
82857d5
Bug fix
tardieu Feb 22, 2018
f6c9cdc
Add optional name argument to composition.encode and deploy
tardieu Feb 22, 2018
d42567a
Test tweak
tardieu Feb 22, 2018
beb3c7f
Parse composition name
tardieu Feb 26, 2018
0596da5
Improve compose command
tardieu Feb 26, 2018
6c59de4
Tweaks and doc
tardieu Feb 27, 2018
8bbda55
Fix links
tardieu Feb 27, 2018
4c39676
Add deployment of openwhisk to Travis. (#4)
rabbah Feb 27, 2018
925e231
Travis
tardieu Feb 27, 2018
a2fb508
Travis self-signed certificate fix
tardieu Feb 27, 2018
6223921
Travis tweak
tardieu Feb 27, 2018
13b409b
Travis fix again
tardieu Feb 27, 2018
a47b0ae
README tweak
tardieu Feb 27, 2018
f8526fc
Merge branch 'master' into ir
tardieu Feb 27, 2018
aed6ac4
Bad merge fix
tardieu Feb 27, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 17 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,26 @@
Composer is a new programming model from [IBM
Research](https://ibm.biz/serverless-research) for composing [IBM
Cloud Functions](https://ibm.biz/openwhisk), built on [Apache
OpenWhisk](https://github.com/apache/incubator-openwhisk). Composer
extends Functions and sequences with more powerful control flow and
automatic state management. With it, developers can build even more
OpenWhisk](https://github.com/apache/incubator-openwhisk).
With composer, developers can build even more
serverless applications including using it for IoT, with workflow
orchestration, conversation services, and devops automation, to name a
few examples.

Composer helps you express cloud-native apps that are serverless by
construction: scale automatically, and pay as you go and not for idle
time. Programming compositions for IBM Cloud Functions is done via the
[functions shell](https://github.com/ibm-functions/shell), which
Composer extends Functions and sequences with more powerful control
flow and automatic state management.
Composer helps express cloud-native apps that are serverless by
construction: scale automatically, pay as you go and not for idle time.

The [IBM Cloud functions shell](https://github.com/ibm-functions/shell)
offers a CLI and graphical interface for fast, incremental, iterative,
and local development of serverless apps. Some additional highlights
of the shell include:

* Edit your code and program using your favorite text editor, rather than using a drag-n-drop UI
* Validate your compositions with readily accessible visualizations, without switching tools or using a browser
* Deploy and invoke compositions using familiar CLI commands
* Debug your invocations with either familiar CLI commands or readily accessible visualizations
* Edit your code and program using your favorite text editor, rather than using a drag-n-drop UI.
* Validate compositions with readily accessible visualizations, without switching tools or using a browser.
* Deploy and invoke compositions using familiar CLI commands.
* Debug invocations with either familiar CLI commands or readily accessible visualizations.

Composer and shell are currently available as IBM Research
previews. We are excited about both and are looking forward to what
Expand All @@ -39,11 +40,9 @@ you to [join us on slack](http://ibm.biz/composer-users).

This repository includes:

* [tutorial](docs) for getting started with Composer in the [docs](docs) folder,
* [composer](composer.js) node.js module to author compositions using JavaScript,
* [conductor](conductor.js) action code to orchestrate the execution of compositions,
* [manager](manager.js) node.js module to query the state of compositions,
* [test-harness](test-harness.js) helper module for testing composer,
* [redis-promise](redis-promise.js) helper module that implements a promisified redis client for node.js,
* a [composer](composer.js) node.js module to author compositions using JavaScript,
* a [compose](bin/compose) shell script for deploying compositions,
* a [tutorial](docs/README.md),
* a [reference manual](docs/COMPOSER.md),
* example compositions in the [samples](samples) folder,
* unit tests in the [test](test) folder.
* tests in the [test](test) folder.
27 changes: 27 additions & 0 deletions bin/compose
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
#!/usr/bin/env node

'use strict'

const fs = require('fs')
const vm = require('vm')
const minimist = require('minimist')
const composer = require('../composer')

const argv = minimist(process.argv.slice(2), { string: ['apihost', 'auth', 'deploy'], boolean: 'insecure', alias: { auth: 'u', insecure: 'i' } })

if (argv._.length !== 1) {
console.error('Usage: compose <composition.js[on]> [--deploy <name>] [--apihost <host>] [--auth <key>] [--insecure]')
return
}

const filename = argv._[0]
const source = fs.readFileSync(filename, { encoding: 'utf8' })
const composition = filename.slice(filename.lastIndexOf('.')) === '.js' ? vm.runInNewContext(source, { composer, require, console, process }) : composer.deserialize(JSON.parse(source))
if (argv.deploy) {
const options = { ignore_certs: argv.insecure }
if (argv.apihost) options.apihost = argv.apihost
if (argv.auth) options.api_key = argv.auth
composer.openwhisk(options).compositions.deploy(composition,argv.deploy).catch(console.error)
} else {
console.log(JSON.stringify(composition, null, 4))
}
Loading