Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Channel will be able to be added, removed and updated dynamically as the application is running.

Channel may be access controlled via the 'allow' field. This field will specify a list of users or groups that are allowed to send requests to that channel. If a channel receives a request from an un-authorised source it will return an error.

A custom router will have to be developed that can route according to these rules. The router can be build using the node.js functions provides to make HTTP request and responses can be relayed using the .pipe() function.

Code Block
titlechannels.json
[
	{
		"name": "Some Registry Channel",
		"urlPattern": "test/sample/.+",
		"allow": "*",
		"deny": [ "Mallet" ],
		"routes": [
			{
				"name": "Some Registry",
				"path": "some/other/path" // this is optional if left out original path is used
				"host": "localhost",
				"port": 8080	
			}
			
		]
	},
	{
		"name": "Some Registry Channel",
		"urlPattern": "test/sample2/.+/test2",
		"allow": [ "Alice","Bob", "PoC" ],
		"routes": [
			{
				"name": "Some Registry",
				"host": "localhost",
				"port": 8080,
				"primary": true
			},
			{
				"name": "Logger",
				"host": "log-host",
				"port": 4789	
			}
		]
	}
]

...