Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: RegisterNativeDependency on directories #159

Open
kxxr opened this issue Jan 22, 2016 · 6 comments
Open

Request: RegisterNativeDependency on directories #159

kxxr opened this issue Jan 22, 2016 · 6 comments

Comments

@kxxr
Copy link

kxxr commented Jan 22, 2016

RegisterNativeDependency works well on individual files. However we also have scenarios where we need to register a whole directory structure of native files and other data. Would it be possible to make RND accept a directory as an argument, copying the whole directory structure across recursively? Or to have RND accept an optional parameter which is a target subdirectory for a file?

@eiriktsarpalis
Copy link
Member

What would be the contents for this directory? If it's just native dll's it should be straightforward to call the existing function on all enumerated contents. If there's other stuff inside, RND is not an appropriate functionality. For this type of application I usually upload all the contents as a zip archive to blob storage, then download and extract the contents on each worker on-demand; I also wrap that logic inside a DomainLocal instance to ensure that it's only being downloaded once per worker.

@dsyme
Copy link
Contributor

dsyme commented Jan 26, 2016

For the application I saw, it would be a massive mix of native DLLs, config files, data files, and goodness knows what else. Basically a situation where some native DLLs expect some data/config files in specific locations relative to their installation point.

@eiriktsarpalis
Copy link
Member

So basically the expectation would be to have those files exracted locally in a location inside PATH?

@kxxr
Copy link
Author

kxxr commented Jan 27, 2016

Thanks for your response, yes I think that's what you're saying. Say in a "bin" folder there is a loader.dll that requires upon startup that a loader.config be found at relative path "conf", it would be useful to be able to say something like
RND("bin/loader.dll")
RND("conf", "bin/conf/loader.config")
That way if "tmp" is the temp folder the .dlls are copied to by MBrace, loader.config will end up in "tmp/conf" instead of "tmp"

@dsyme
Copy link
Contributor

dsyme commented Jun 8, 2017

@kxxr I know this is sometime back but if you would like to consider submitting a PR for this it would be most welcome.

@kxxr
Copy link
Author

kxxr commented Jun 9, 2017

@dsyme I'd be glad to help on this and other issues but am currently on holiday and was also focusing on other interests for the time being... will mention this to Adam though who may well be more in the loop

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants