Local Group Docs Instance

Hi Support Team,

Im here with another Question regarding Group Docs. We have a Cloud Service for Building Management and are trying to integrate the libary as efficient as possible. To distribute the load of the viewer, we thought about a dedicated Server (Instance). I uploaded a sketch, how this might work. pnw is the name of the cloud service.Integration Group Docs.png (5.8 KB)
Thanks in advance!
Can your Demo Application support this? Ideal would be if the communication between the cloud and the server would work with a REST API.

@TWHPNW

Please take a look at the following sample application which you can use to pass the file name or file ID as a query string parameter /viewer?file=<my-file-id> and than read a file in your storage implementation

    class MyFileStorage : IFileStorage
    {
        public Task<IEnumerable<FileSystemEntry>> ListDirsAndFilesAsync(string dirPath)
        {
            //...
        }

        public Task<byte[]> ReadFileAsync(string filePath)
        {
            return File.ReadAllBytesAsync("./Storage/sample.docx");
        }

        public Task<string> WriteFileAsync(string fileName, byte[] bytes, bool rewrite)
        {
            //...
        }
    }

Hi Vladimir Litvinchik,

Thank you for your quick reply.

As we are using Java as programming language this .net sample application is hard to test for us.
Would there be also a Java example?

@TWHPNW

Please take a look at our Java Demo projects - https://github.com/groupdocs-viewer/GroupDocs.Viewer-for-Java/tree/master/Demos.