Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VUU83: Layout management documentation #98

Closed
Show file tree
Hide file tree
Changes from 3 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
76 changes: 54 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,17 @@

Welcome. We maintain a docusaurus site containing all the details of the project. Why not get started there:

https://vuu.finos.org/docs/introduction/intro
<https://vuu.finos.org/docs/introduction/intro>

## Installation - Server

### Prerequisites
### Vuu Server

#### Prerequisites

See the [Docs](https://vuu.finos.org/docs/getting_started/developing) for Java versions and install dependencies you need to have.

OS X & Linux:
#### OS X & Linux

```sh
#In your favourite code directory...
Expand All @@ -29,40 +31,41 @@ cd vuu
mvn exec:exec
```

Windows:
#### Windows

```sh
this should be the same as Linux & macos just with windows adjusted paths
```

## Installation - Client
### Layout Server

The UI scripts all run from the vuu/vuu-ui directory.
Layout management requires persisting layouts. Layouts can either be persisted locally or remotely. The remote implementation requires spinning up a Springboot server instance, but is more robust and reflective of a real-world application.

```sh
#from top-level vuu repo (not vuu child directory in repo)
cd vuu-ui
npm install
npm run build
npm run build:app
```
#### Choosing local or remote

You can now open the demo app in your browser at https://127.0.0.1:8443/index.html
Changing whether local/remote is used is configured with the following flag:

Alternatively, you may choose to run the demo app in Electron. First install Electron in the tools/electron folder:
1. Open `finos-vuu\vuu-ui\showcase\vite.config.js`
2. Set `"process.env.LOCAL"` flag to `true` for local, or `false` for remote

The local implementation is default. It uses browser local storage. If you have chosen the remote implementation, ensure you are running the remote server.

#### Running the remote server

You can run the remote server from IntelliJ or via CLI. Once running, use `http://localhost:8081/api/swagger` to review endpoints and contracts. It uses an in-memory H2 database, and can be accessed at `http://localhost:8081/api/h2-console`.

##### CLI

```sh
#from top-level vuu repo (not vuu child directory in repo)
cd vuu-ui/tools/electron
npm install
cd layout-server
mvn spring-boot:run
```

Then, back in vuu-ui, run the launch script"
##### From IntelliJ

```sh
#from vuu/vuu-ui
npm run launch:demo:electron
```
1. Follow steps 3-5 outlined in 'Configuring IntelliJ' below
2. Select 'LayoutServer' config and click run

## Configuring IntelliJ

Expand All @@ -89,6 +92,35 @@ npm run build
8. In IntelliJ, select 'SimulMain' config and click run
9. If you get a 'certificate-unknown' error, set 'Allow invalid certificates for resources loaded from localhost' to 'Enabled' in your chrome settings

## Installation - Client

The UI scripts all run from the vuu/vuu-ui directory.

```sh
#from top-level vuu repo (not vuu child directory in repo)
cd vuu-ui
npm install
npm run build
npm run build:app
```

You can now open the demo app in your browser at <https://127.0.0.1:8443/index.html>

Alternatively, you may choose to run the demo app in Electron. First install Electron in the tools/electron folder:

```sh
#from top-level vuu repo (not vuu child directory in repo)
cd vuu-ui/tools/electron
npm install
```

Then, back in vuu-ui, run the launch script"

```sh
#from vuu/vuu-ui
npm run launch:demo:electron
```

## Usage example

```
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="LayoutServerApplication" type="Application"
factoryName="Application" nameIsGenerated="true">
<option name="MAIN_CLASS_NAME" value="org.finos.vuu.layoutserver.LayoutServerApplication"/>
<module name="layout-server"/>
<extension name="coverage">
<pattern>
<option name="PATTERN" value="org.finos.vuu.layoutserver.*"/>
<option name="ENABLED" value="true"/>
</pattern>
</extension>
<method v="2">
<option name="Make" enabled="true"/>
</method>
</configuration>
</component>
Loading