Skip to content

folio-org/mod-notes

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

mod-notes

Copyright (C) 2017-2022 The Open Library Foundation

This software is distributed under the terms of the Apache License, Version 2.0. See the file "LICENSE" for more information.

Introduction

Notes on all types of objects.

The notes module implements a simple CRUD interface where users can post notes, small comment texts that refer to other objects in the system, for example users or items.

API

See API Guide

Permissions

The module declares the usual permission bits for the CRUD operations, but it also makes use of the DesiredPermissions feature, using one wildcard pattern 'notes.domains.*' for all endpoints. The idea is that each UI module that makes use of notes, will have to decide on a name for its domain (for example 'items') and use that on all notes they operate on. They should also define a permission set that includes the 'notes.domains.items' permission in some permission set, and enable that for the users who will have access to the permissions on that domain, together with the CRUD permissions telling what kind of operations the user is allowed to perform.

There is also an overall permission 'notes.domains.all' that grants permission to all possible domains.

The way this is designed, the notes module does not need to know or care about which domains we end up having in the system. Unfortunately it requires mod-permissions to support wildcards in the DesiredPermissions, which it does not quite do yet.

Installing and deployment

Compiling

Compile with

mvn clean install

Running it

Run locally on listening port 8081 (default listening port):

Using Docker to run the local stand-alone instance:

DB_HOST=localhost DB_PORT=5432 DB_DATABASE=okapi_modules DB_USERNAME=folio_admin DB_PASSWORD=folio_admin \
   java -Dserver.port=8081 -jar target/mod-notes-*.jar

Docker

Build the docker container with:

docker build -t dev.folio/mod-notes .

ModuleDescriptor

See the built target/ModuleDescriptor.json for the interfaces that this module requires and provides, the permissions, and the additional module metadata.

Additional information

Other documentation

Other modules are described, with further FOLIO Developer documentation at dev.folio.org

Issue tracker

See project MODNOTES at the FOLIO issue tracker.

API documentation

This module's API documentation.

Code analysis

SonarQube analysis.

Download and configuration

The built artifacts for this module are available. See configuration for repository access, and the Docker image.