The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

FusqlFS::Backend::PgSQL::Role::Owned - FusqlFS module to aggregate all PostgreSQL artifacts owned by a role into single place

SYNOPSIS

    package FusqlFS::Backend::PgSQL::Roles;
    use base 'FusqlFS::Artifact';

    use FusqlFS::Backend::PgSQL::Role::Owned;

    sub init
    {
        my $self = shift;

        # initialize instance and class

        $self->{owned} = FusqlFS::Backend::PgSQL::Role::Owned->new();
    }

    sub get
    {
        my $class = shift;
        my ($role) = @_;
        my $result = {};

        # get data about $role into $result

        $result->{owned} = $self->{owned};

        return $result;
    }

DESCRIPTION

This module gathers all database artifacts owned by single role into one single place. It does it by providing symlinks to artifacts sorted by type (`tables', `functions' etc., see "EXPOSED STRUCTURE" for details).

This module is not to be plugged in any place of tree, it is actually to be used in "FusqlFS::Backend::PgSQL::Roles" module.

EXPOSED STRUCTURE

./tables, ./functions, ./indices, ./sequences, ./languages

This is the first level of hierarchy to sort owned artifacts by type and provide separate namespaces for different objects in database.

There are symlinks to artifacts of correspondent type in each of these subdirectories, e.g. if a role owns table sometable and stored procedure someproc there will be symlinks in ./tables/sometable and ./functions/someproc pointing to /tables/sometable and /functions/someproc.