Icon View Thread

The following is the text of the current message along with any replies.
Messages 11 to 16 of 16 total
Thread Backup using Client/Server
Thu, Nov 1 2018 12:43 AMPermanent Link

Lance Rasmussen

CDE Software

Avatar

Team Elevate Team Elevate

No web server. I use on consumer/ business machines that normally would be installed on same computer as the client. However, I have situations where customers will install additional clients or the one client on a computer different than the server.

I use Remobjects Remote SDK on my spinoff of the EDB server.  It dies a couple functions and procedures needed where I need to use the client for non-db related things.  So I spent the day and used one of Remobjects examples of file transfer from a client and server, hacking that into the server and client.

I'm now successfully able to tell the server to backup to a particular folder using the store and then using the remote SDK addons to transfer that file from the server to the client's temp folder, to the copy to where the customer points to with the savedialog.

This is something that would nice to be able to do natively. Using an Indy or similar TCP transport that can transfer the file across the server port or admin port.  Or at worst add a third port used for file transport.


Raul wrote:

On 10/31/2018 1:50 PM, Lance Rasmussen wrote:
> I'm wondering if I may have to look at something like Remobject Remoting SDK (I have license) to transfer file over network streaming, not caring about UNC,  Then do the backup on the server, then use the SDK to transfer the file after creation.
>

Are you running any kind of a web server on the server side ?

it does introduce some security issues but assuming your web server does
not allow file browsing and you use a complex URL (like GUID in folder
name) you could do
1. have a file store pointing to a folder that is web server published
(with guid name or such to make it hard to guess/scan for)
2. once backup is done you launch a browser from app to download file
(or simple to download from delphi app once you know what the url looks
like)

Raul
Thu, Nov 1 2018 12:51 AMPermanent Link

Lance Rasmussen

CDE Software

Avatar

Team Elevate Team Elevate

Thinking aloud. What if an administrative table was able to hold the file temporarily and then be able to stream the result, much like a CLOB, in a SQL results which then could be file stream saved locally to the client.
It should take Tim 5 minutes, because I know excel and anything in excel can be programmed in 5 minutes.  Wink  
Thu, Nov 1 2018 5:32 PMPermanent Link

Raul

Team Elevate Team Elevate

On 11/1/2018 12:51 AM, Lance Rasmussen wrote:
> Thinking aloud. What if an administrative table was able to hold the file temporarily and then be able to stream the result, much like a CLOB, in a SQL results which then could be file stream saved locally to the client.

Actually this is a nice idea and writing a small custom module that does
this sounds straightforward.

One would need to have a table with appropriate schema ready and specify
all that when calling function whic then just dumps the backup file into
a blob.

Raul
Wed, Nov 7 2018 1:42 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Lance,

<< I'm wondering if I may have to look at something like Remobject Remoting SDK (I have license) to transfer file over network streaming, not caring about UNC,  Then do the backup on the server, then use the SDK to transfer the file after creation. >>

Is the EDB Server exposed to the public on an open port ?  If so, then you can use this method:

https://www.elevatesoft.com/manual?action=viewmethod&id=edb2&product=rsdelphiwin32&version=10T&comp=TEDBSession&method=SaveStoreFileToStream

to save a store file to a local stream (TFileStream, for instance).

Tim Young
Elevate Software
www.elevatesoft.com
Thu, Nov 8 2018 8:47 PMPermanent Link

Lance Rasmussen

CDE Software

Avatar

Team Elevate Team Elevate

Tim,

The server is basically public somewhere on the network, but potentially could be hosted and would need a public IP.

I tested the stream/store functions and now have it working perfectly.  

A couple things.

1. Is there a session function that returns what the server sees as the temporary path?  I didn't see one, though could just be blind. Wink

2. I would recommend making changes to the Elevate Manager to reflect the backup and restore functions.  I don't believe they are using the stream/store functions, so if you use the Elevate Manager to restore a backup or make a backup when the session is a remote session and the server is not on the same IP as the Elevate Manager, then these would fail.

Thanks for the help all!

Lance





Tim Young [Elevate Software] wrote:

Lance,

<< I'm wondering if I may have to look at something like Remobject Remoting SDK (I have license) to transfer file over network streaming, not caring about UNC,  Then do the backup on the server, then use the SDK to transfer the file after creation. >>

Is the EDB Server exposed to the public on an open port ?  If so, then you can use this method:

https://www.elevatesoft.com/manual?action=viewmethod&id=edb2&product=rsdelphiwin32&version=10T&comp=TEDBSession&method=SaveStoreFileToStream

to save a store file to a local stream (TFileStream, for instance).

Tim Young
Elevate Software
www.elevatesoft.com
Fri, Nov 16 2018 12:47 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Lance,

<< 1. Is there a session function that returns what the server sees as the temporary path?  I didn't see one, though could just be blind. Wink>>

You can always get the path from here:

https://www.elevatesoft.com/manual?action=viewtopic&id=edb2sql&topic=Stores_Table

However, in order to actually see the Path column, you must be logged in as an Administrator.  Normal users see a NULL there in order to avoid any information leakage about the server machine.

<< 2. I would recommend making changes to the Elevate Manager to reflect the backup and restore functions.  I don't believe they are using the stream/store functions, so if you use the Elevate Manager to restore a backup or make a backup when the session is a remote session and the server is not on the same IP as the Elevate Manager, then these would fail. >>

This is done on purpose - I don't make any assumptions about what the developer wants to do with the backup after the operation has completed.  If you want to move a backup to a local drive, you can just create a local store and remote store, and then perform a copy (COPY FILE...) from the remote store to the local store.  Interactively, you can do this by opening the remote store, right-clicking, and then selecting the Copy File option.

Tim Young
Elevate Software
www.elevatesoft.com
« Previous PagePage 2 of 2
Jump to Page:  1 2
Image