Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
147 changes: 147 additions & 0 deletions QEWD.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
# qewd-baseline: Minimal QEWD Set-up on which to start Application Development

Rob Tweed <rtweed@mgateway.com>
4 December 2019, M/Gateway Developments Ltd [http://www.mgateway.com](http://www.mgateway.com)

Twitter: @rtweed

Google Group for discussions, support, advice etc: [http://groups.google.co.uk/group/enterprise-web-developer-community](http://groups.google.co.uk/group/enterprise-web-developer-community)


# About this Repository

This repository provides a pre-configured, minimal set-up on which you can begin
developing your APIs and/or back-end logic/message handlers for your interactive applications.

It supports two modes of operation:

1) A Dockerised version of QEWD that will run on any Linux system or on a Raspberry Pi

2) A version that will run on the InterSystems
[AWS Community Edition of IRIS](https://aws.amazon.com/marketplace/pp/B07MSHYLF1?qid=1575041206953&sr=0-1&ref_=srh_res_product_title)

This repository also contains in-depth tutorials that will teach you how to build QEWD-based:

- [REST APIs](./REST.md)
- [interactive WebSocket-based applications](./INTERACTIVE.md)

# What is QEWD?

QEWD is a 100% Node.js-based, integrated system on which you can build the back-end logic for
both REST APIs and interactive, browser-based or Native applications. The pre-installated
and pre-configured components that constitute QEWD include:

- the [Express](https://www.npmjs.com/package/express) web server
- the [socket.io](https://www.npmjs.com/package/socket.io) nodule for WebSocket support
- the [ewd-qoper8](https://www.npmjs.com/package/ewd-qoper8) Queue/Worker Pool management system
- [QEWD-jsdb](https://github.com/robtweed/qewd-jsdb): an in-process multi-model database
- the [QEWD-transform-json](https://github.com/robtweed/qewd-transform-json) JSON transformation module

QEWD provides and supports Session management using either server-side Session storage (using
QEWD-JSdb) or JSON Web Tokens (JWT).

QEWD can be run either natively or as a [Dockerised version](https://hub.docker.com/repository/docker/rtweed/qewd-server)
and can be configured to support either single monolithic applications or
applications built as MicroServices (each of which will run on its own QEWD instance).

QEWD also includes [ewd-client](https://github.com/robtweed/ewd-client), a client JavaScript library
which allows browser or Native front-ends to communicate securely over WebSockets with
QEWD's *socket-io* interface. *ewd-client* can be used and easily integrated with any
JavaScript framework.

# Getting Started

For the IRIS / AWS Version, see [these instructions](./IRIS.md).

Otherwise, the simplest way to work with QEWD is to use the pre-built Docker version which will run on
any Linux system or even on a Raspberry Pi.

Just type these commands in a Linux system or Raspberry Pi:

cd ~
git clone https://github.com/robtweed/qewd-baseline
cd qewd-baseline
source install.sh

Simply answer the questions and within a few minutes you'll have it all ready to run.

Don't worry if you don't have Docker installed (which is the only dependency) - the installer
will also install Docker if necessary (though you'll need to start a new process and re-run
the installer after it installs Docker).

When the installer has completed you have two options for starting the QEWD Docker container:

- without database persistence between Container restarts:

cd ~/qewd-baseline
./start

- with database persistence between Container restarts:


cd ~/qewd-baseline
./start_p


To stop the Docker Container, you should always use the command:

cd ~/qewd-baseline
./stop

This cleanly and safely shuts down the database-connected QEWD Worker Processes


The QEWD-baseline Folder Structure

You'll see the following folders in your QEWD-baseline directory:

- apis: used for your REST API handler logic
- configuration: this is where your QEWD system is configured, and where your REST API routes are defined
- qewd-apps: used for your interactive applications' message handlers
- utils: used for any of your utility modules on which your REST or interactive application handler are
dependent
- www: used as the QEWD Express web Server root path, and therefore the home for the front-end
markup, JavaScript and CSS resources of your applications

If you're running the Containerised version of QEWD, you'll also see a folder named
*yottadb*. If you run the QEWD Container in persistent mode, this folder contains
the host files for the YottaDB database. They are mapped for use by YottaDB within the
Container. You should not change or move this folder or its contents, but you should back them
up regularly.

You'll also see a folder named *iris-aws*. This contains versions of key files which
are used if you are running on IRIS


# Developing REST APIs

[Click here](./REST.md) to learn how to create REST APIs on your QEWD system


# Developing Interactive Applications

[Click here](./INTERACTIVE.md) to learn how to create interactive applications, the
back-end of which will run on your QEWD system


## License

Copyright (c) 2019 M/Gateway Developments Ltd,
Redhill, Surrey UK.
All rights reserved.

http://www.mgateway.com
Email: rtweed@mgateway.com


Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
107 changes: 46 additions & 61 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
# PTWQ - Open Source Telehealth Solution by the Ripple Foundation

Open Source Telehealth Solution developed by the the Ripple Foundation - featuring PulseTile, Qewd, YottaDB and Jitsi open source technologies.
For any related code/information/discussion/questions/issues please visit this related discussion forum which is open to all;

[Visit Discussion](https://gitter.im/Ripple-Foundation/Open-Source-TeleHealth)
=======
# Open Source Telehealth Solution

## Global Table of Contents

- [Quick Readme](/README.md)
- [Installation Guide](/docs/installation.md)
- [PT-WC-Q Components](/docs/components.md)
- [How To / Recipe](/docs/how-to.md)
- [QEWD Main Documentation](/QEWD.md)
- [REST scope](/REST.md)


Building on open source technologies;
Expand Down Expand Up @@ -30,28 +45,18 @@ Further collaboration is encouraged via the discussion forum above

Funded by the Ripple Foundation in 2020


... /// ...

This solution is served as a dockerised service via the Qewd- Baseline repo - documented here https://github.com/robtweed/qewd-baseline




# qewd-baseline: Minimal QEWD Set-up on which to start Application Development

Rob Tweed <rtweed@mgateway.com>
4 December 2019, M/Gateway Developments Ltd [http://www.mgateway.com](http://www.mgateway.com)
### Contributors

Twitter: @rtweed
[![](https://github.com/tony-shannon.png?size=50)](https://github.com/tony-shannon) [![](https://github.com/yudin-s.png?size=50)](https://github.com/yudin-s)

Google Group for discussions, support, advice etc: [http://groups.google.co.uk/group/enterprise-web-developer-community](http://groups.google.co.uk/group/enterprise-web-developer-community)


# About this Repository

This repository provides a pre-configured, minimal set-up on which you can begin
developing your APIs and/or back-end logic/message handlers for your interactive applications.
This repository provides a Open Source Telehealth app based on QEWD framework that allow dynamically extending and modifying

It supports two modes of operation:

Expand All @@ -62,32 +67,10 @@ It supports two modes of operation:

This repository also contains in-depth tutorials that will teach you how to build QEWD-based:

- [QEWD](./QEWD.md)
- [REST APIs](./REST.md)
- [interactive WebSocket-based applications](./INTERACTIVE.md)

# What is QEWD?

QEWD is a 100% Node.js-based, integrated system on which you can build the back-end logic for
both REST APIs and interactive, browser-based or Native applications. The pre-installated
and pre-configured components that constitute QEWD include:

- the [Express](https://www.npmjs.com/package/express) web server
- the [socket.io](https://www.npmjs.com/package/socket.io) nodule for WebSocket support
- the [ewd-qoper8](https://www.npmjs.com/package/ewd-qoper8) Queue/Worker Pool management system
- [QEWD-jsdb](https://github.com/robtweed/qewd-jsdb): an in-process multi-model database
- the [QEWD-transform-json](https://github.com/robtweed/qewd-transform-json) JSON transformation module

QEWD provides and supports Session management using either server-side Session storage (using
QEWD-JSdb) or JSON Web Tokens (JWT).

QEWD can be run either natively or as a [Dockerised version](https://hub.docker.com/repository/docker/rtweed/qewd-server)
and can be configured to support either single monolithic applications or
applications built as MicroServices (each of which will run on its own QEWD instance).

QEWD also includes [ewd-client](https://github.com/robtweed/ewd-client), a client JavaScript library
which allows browser or Native front-ends to communicate securely over WebSockets with
QEWD's *socket-io* interface. *ewd-client* can be used and easily integrated with any
JavaScript framework.

# Getting Started

Expand All @@ -99,8 +82,8 @@ any Linux system or even on a Raspberry Pi.
Just type these commands in a Linux system or Raspberry Pi:

cd ~
git clone https://github.com/robtweed/qewd-baseline
cd qewd-baseline
git clone https://github.com/RippleOSI/OS-TeleHealth
cd OS-TeleHealth
source install.sh

Simply answer the questions and within a few minutes you'll have it all ready to run.
Expand All @@ -113,13 +96,13 @@ When the installer has completed you have two options for starting the QEWD Dock

- without database persistence between Container restarts:

cd ~/qewd-baseline
cd ~/OS-TeleHealth
./start

- with database persistence between Container restarts:


cd ~/qewd-baseline
cd ~/OS-TeleHealth
./start_p


Expand All @@ -131,38 +114,39 @@ To stop the Docker Container, you should always use the command:
This cleanly and safely shuts down the database-connected QEWD Worker Processes


The QEWD-baseline Folder Structure
## The OS-TeleHealth Folder and File Structure

You'll see the following folders in your QEWD-baseline directory:
Website Structure

- apis: used for your REST API handler logic
- configuration: this is where your QEWD system is configured, and where your REST API routes are defined
- qewd-apps: used for your interactive applications' message handlers
- utils: used for any of your utility modules on which your REST or interactive application handler are
dependent
- www: used as the QEWD Express web Server root path, and therefore the home for the front-end
markup, JavaScript and CSS resources of your applications
- www/pt-wc-q/ : Main Folder with website pages and components structure.
- www/pt-wc-q/app.js : Entity point of project building and execution
- www/pt-wc-q/css : Global Stylesheet files. We are using https://startbootstrap.com/themes/sb-admin-2/ as main template.

If you're running the Containerised version of QEWD, you'll also see a folder named
*yottadb*. If you run the QEWD Container in persistent mode, this folder contains
the host files for the YottaDB database. They are mapped for use by YottaDB within the
Container. You should not change or move this folder or its contents, but you should back them
up regularly.
#### Inside www/pt-wc-q/js

You'll also see a folder named *iris-aws*. This contains versions of key files which
are used if you are running on IRIS
- utils - Helper functions and classes
- researching - Examples and samples of the component building processes
- pages - static pages mgWebComponents object

#### File naming rules

`[page name]-page.js ` File with custom mgWebComponents page structure
`[page name]_page_state.js ` File with schema for CRUD page builder (see adminui/components/adminui-crud.js to understand how building is happens)
`[page name]_modal.js ` File that is uses adminui-modal.js from adminui component section

# Developing REST APIs

[Click here](./REST.md) to learn how to create REST APIs on your QEWD system
### About core framework

[Click Here](QEWD.md) to learn about QEWD

# Developing Interactive Applications
### Developing REST APIs

[Click here](./INTERACTIVE.md) to learn how to create interactive applications, the
back-end of which will run on your QEWD system
[Click here](./REST.md) to learn how to create REST APIs on your QEWD system

### Developing Interactive Applications

[Click here](./INTERACTIVE.md) to learn how to create interactive applications, the
back-end of which will run on your QEWD system for got better understanding how project was builded.

## License

Expand All @@ -185,3 +169,4 @@ back-end of which will run on your QEWD system
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Loading