Setting a maximum size on libraries 

Use FilesLibraryService commands to assign a policies to libraries. A library is a set of files owned by a person or community. A policy sets a maximum size for a library.


Before starting

To use administrative commands, use the wsadmin client. See Starting the wsadmin client for details.

Many commands ask for IDs as input parameters, such as library IDs, user IDs, policy IDs, and file IDs. You can use commands that take parameters you do know to return data including the ID you are looking for. For example, run FilesMemberService.getByEmail(string email) providing a user's email address and among the data returned is the user's ID. You can also find IDs using feeds. See the Lotus Connections API documentation for information on getting ID information using feeds.


Procedure

  1. Start the wsadmin client.

  2. Start the Files Jython script interpreter using the following command:

      execfile("filesAdmin.py")

  3. Create a policy to specify the library size, using steps in the topic Work with policies.

  4. Run the following commands to set maximum sizes on libraries:

      FilesLibraryService.assignPolicy(string libraryId, string policyId)

        Assigns a policy to a library. A library is a set of files owned by a person or community. It includes all versions of the files, but does not include metadata such as comments. A policy sets a maximum size for a library.

        No message is printed if the task succeeds.

        Parameters:

        libraryId

          The library ID in the following standard Universally Unique Identifier (UUID) format: 00000000-0000-0000-0000-000000000000.

        policyId

          The policy ID in the following standard Universally Unique Identifier (UUID) format: 00000000-0000-0000-0000-000000000000.

        For example:

        FilesLibraryService.assignPolicy("f0d01111-9b21-4dd8-b8be-8825631cb84b", "2d93497d-065a-4022ae25-a4b52598d11a")

      FilesLibraryService.assignPolicyBatch(string filePath)

        Assigns policies to libraries as specified in a text file. The file must contain a list of library-policy ID pairs, one pair per line, values separated by a comma. For example: libraryId, policyId. Extra whitespace is ignored. You must create this text file and save it in a directory local to the server where you are running the wsadmin processor.

        A library is a set of files owned by a person or community. It includes all versions of the files, but does not include metadata such as comments. A policy sets a maximum size for a library.

        Parameters:

        filePath

          The full path to the text file, as a string.

        For example:

        FilesLibraryService.assignPolicyBatch("C:/connections/assign_policies.txt")


Parent topic

Administer Files

Related concepts
Configure media galleries


Related tasks


Setting a maximum size on files
Starting the wsadmin client
Work with Files policies

+

Search Tips   |   Advanced Search