Change space folder location impact

Hello,

Today I'm cleaning our server folders and files, and making a new folder structure.
So I changed the location of our EasyMorph spaces.
I put the modification on each space settings in EasyMorph Server, and that's great.

But some things are a little mess, and we have not a lot of tasks (30) and projects.
So in the future, if we make a modification on our folder structure, it will be harder with more elements.

Tell me if I'm not clear !

First thing : all the tasks on EasyMorph Server needs to be remap with the new project location.
Why it's not in relative location from the EasyMorph space location ?
Like this :
Space location : D:\BI\EasyMorph\Spaces\00 - Default
Task location : 00 - Default\MyProjectLocation

Actually, that's exactly what I can see inside my task on the server :
image
But if I change the space location to 00 - Default1, with the exact same location of projects inside, it shows the previous full path in the task :
image

Why the relative path is not used, from the space location ? Like if the space was 00 - Default and now 00 - Default1, why the space location is not used in the tasks ?

Maybe that's not something you have done, but I think it could be helpful to have a feature like this.

Second thing : we are using several call another project in EasyMorph Desktop.
With this location modification, all are broken, we need to remap them with their new location.
1- When we remap a project, all the parameters are removed :
Here before the remapping

Here after the remapping, just after the selection of the project path

Sometimes the parameters are columns from specific errors or treatments, so we need to rerun all scenarios to put them in parameter, that's hard to do in all our projects, but actually doable.

2- Like the location for the tasks on the Server, maybe you can add a little thing to make the path relative when the project to call is in the server space.
Like a little check box "Is a project in the space", if checked, the selection is allowed only on projects inside the space, to make a relative path from the space location.
With this, it do not depend on the user access to server folder (from the user computer, here the user is me), and if the location is moved, the path stay the same, relative to the space path.
Edit : And make the same for the file import/export, like this which is for datasets :

If you need further explanation or illustration, don't hesitate to ask.

Do you have something to deal with this case, or do I need to make all the modifications one by one ?

Thank you :slight_smile:

The idea is to keep your tasks working even if you change the space folder. That's why project paths are saved as absolute paths. They are shown as relative when the project path lies within the public folder, and as absolute when it's outside.

You can modify file paths in the XML files with task definitions using text search and replace in any plain text editor, and even using an EasyMorph workflow (with the import/export plain text actions.

I understand that using shared projects when switching back and forth between Desktop and Server can be inconvenient. Consider running Server tasks, instead of shared projects. Instead of using "Call another project", use "EasyMorph Server command: Run task".

Pros:

  • You can still pass parameters, just like in the "Call" action
  • You can call a Server task no matter if a workflow is executed on Desktop or on Server

Cons:

  • It's not yet possible to pass a dataset or return a dataset when calling a task
1 Like

I searched some files in folders, I don't know how I didn't see the XML Files.
And I don't know why the idea of using a call server command instead of a call another project never come to my mind. Maybe because it was working well !

Thank you a lot Dmitry !

Dmitry,

About the task trigger with a server command.
Before, I was doing a call another project, and in the other project I was using system('callerfilename') to get the source project.
Do I need to add a parameter to my task, and then pass the project name in each of my project using this task ?
Is there an other way ?

Now, event when the project is waiting for the completion :
image
I have some errors due to "simultaneous runs" :
image

I use this task a lot, because it's to create logs, and error handling.
I know that I can in the task options add numbers to "simultaneous runs" option, but I would like to know more things about it.
How does it works ?
Is it "just" starting the task like if we press "Run all actions" on 2 same projects, one after the other ?
And if it need to write in a file (it could be another thing), but the file is currently used by the last run, does it wait or something ?

That's just regular questions, I don't have a lot of time to test what it does in which case (currently we don't have multiple use cases), so I prefer ask to have a clear answer.

Thank you !

The EasyMorph Server command "Run task" works via the public API of EasyMorph Server and therefore it's not possible to retrieve the name of the calling project. As a workaround, as you suggested, you can pass the caller project name using a task parameter.

By default, a Server task can only be executed once at a time. To enable multiple parallel runs, edit the "Simultaneous runs" property in the task settings:

It runs multiple "copies" of the task concurrently, i.e., in parallel. If it needs to write in a file, then you may have a concurrency conflict (which you would have with the "Call" action as well) because two workflows, no matter how they are called, would attempt to write into the same file.

To resolve concurrency conflicts, use the "Start/stop exclusive access" action. It allows locking a resource and making another workflow wait until the resource is released.

1 Like

Thank you !