Skip to content

Commit 7fa0165

Browse files
committed
Deprecate the Slurm functionality in this package (and point users to SlurmClusterManager.jl instead)
1 parent 59ee855 commit 7fa0165

File tree

2 files changed

+13
-5
lines changed

2 files changed

+13
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Implemented in this package (the `ClusterManagers.jl` package):
2121
| PBS (Portable Batch System) | `addprocs_pbs(np::Integer; qsub_flags=``)` or `addprocs(PBSManager(np, qsub_flags))` |
2222
| Scyld | `addprocs_scyld(np::Integer)` or `addprocs(ScyldManager(np))` |
2323
| HTCondor[^1] | `addprocs_htc(np::Integer)` or `addprocs(HTCManager(np))` |
24-
| Slurm | `addprocs_slurm(np::Integer; kwargs...)` or `addprocs(SlurmManager(np); kwargs...)` |
24+
| Slurm (deprecated - consider using [SlurmClusterManager.jl](https://github.com/kleinhenz/SlurmClusterManager.jl) instead) | `addprocs_slurm(np::Integer; kwargs...)` or `addprocs(SlurmManager(np); kwargs...)` |
2525
| Local manager with CPU affinity setting | `addprocs(LocalAffinityManager(;np=CPU_CORES, mode::AffinityMode=BALANCED, affinities=[]); kwargs...)` |
2626

2727
[^1]: HTCondor was previously named Condor.
@@ -93,7 +93,7 @@ julia> From worker 2: compute-6
9393
From worker 3: compute-6
9494
```
9595

96-
Some clusters require the user to specify a list of required resources.
96+
Some clusters require the user to specify a list of required resources.
9797
For example, it may be necessary to specify how much memory will be needed by the job - see this [issue](https://github.com/JuliaLang/julia/issues/10390).
9898
The keyword `qsub_flags` can be used to specify these and other options.
9999
Additionally the keyword `wd` can be used to specify the working directory (which defaults to `ENV["HOME"]`).
@@ -176,10 +176,10 @@ ElasticManager:
176176
Active workers : []
177177
Number of workers to be added : 0
178178
Terminated workers : []
179-
Worker connect command :
179+
Worker connect command :
180180
/home/user/bin/julia --project=/home/user/myproject/Project.toml -e 'using ClusterManagers; ClusterManagers.elastic_worker("4cOSyaYpgSl6BC0C","127.0.1.1",36275)'
181181
```
182182

183-
By default, the printed command uses the absolute path to the current Julia executable and activates the same project as the current session. You can change either of these defaults by passing `printing_kwargs=(absolute_exename=false, same_project=false))` to the first form of the `ElasticManager` constructor.
183+
By default, the printed command uses the absolute path to the current Julia executable and activates the same project as the current session. You can change either of these defaults by passing `printing_kwargs=(absolute_exename=false, same_project=false))` to the first form of the `ElasticManager` constructor.
184184

185-
Once workers are connected, you can print the `em` object again to see them added to the list of active workers.
185+
Once workers are connected, you can print the `em` object again to see them added to the list of active workers.

src/slurm.jl

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,14 @@ end
1515

1616
function launch(manager::SlurmManager, params::Dict, instances_arr::Array,
1717
c::Condition)
18+
let
19+
msg = "`ClusterManagers.addprocs_slurm` and `ClusterManagers.SlurmManager` " *
20+
"(from the `ClusterManagers.jl` package) are deprecated. " *
21+
"Consider using the `SlurmClusterManager.jl` package instead."
22+
funcsym = :addprocs_slurm
23+
force = true
24+
Base.depwarn(msg, funcsym; force)
25+
end
1826
try
1927
exehome = params[:dir]
2028
exename = params[:exename]

0 commit comments

Comments
 (0)