@Documented @Retention(value=RUNTIME) @Target(value={METHOD,FIELD}) public @interface GridLocalHostResource
GridConfiguration.getLocalHost() or
via GridSystemProperties.GG_LOCAL_HOST system or environment property.
Local node ID can be injected into instances of following classes:
Here is how injection would typically happen:
public class MyGridJob implements GridComputeJob {
...
@GridLocalHostResource
private String locHost;
...
}
or
public class MyGridJob implements GridComputeJob {
...
private String locHost;
...
@GridLocalHostResource
public void setLocalHost(String locHost) {
this.locHost = locHost;
}
...
}
See GridConfiguration.getLocalHost() for Grid configuration details.
Copyright © 2014. All rights reserved.