You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 6, 2021. It is now read-only.
Hi,
in a perfect world I want to subscribe to a record that does not exist, and have a data provider listening and go and create the record, (ie I want the record to be readonly to the client). Unfortunately this functionality does not exist, it is logged as a potential feature https://github.com/deepstreamIO/deepstream.io/issues/684#issuecomment-304118122
The suggestion I got was to give a user create and read access but not write and delete access. An example permission would look like this, (the server user is what the active data provider will use to set the record).
I used the following code to test, the java client hangs at the setwithack and does not get any error back. So it looks like a bug in the java client ?
Hi,
in a perfect world I want to subscribe to a record that does not exist, and have a data provider listening and go and create the record, (ie I want the record to be readonly to the client). Unfortunately this functionality does not exist, it is logged as a potential feature
https://github.com/deepstreamIO/deepstream.io/issues/684#issuecomment-304118122
The suggestion I got was to give a user create and read access but not write and delete access. An example permission would look like this, (the server user is what the active data provider will use to set the record).
record:
"readonlyrec":
create: "user.id === 'todd'"
write: "user.id === 'server'"
read: true
delete: "user.id === 'server'"
listen: true
I used the following code to test, the java client hangs at the setwithack and does not get any error back. So it looks like a bug in the java client ?
import io.deepstream.DeepstreamClient;
import io.deepstream.Record;
import java.net.URISyntaxException;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import com.google.gson.JsonPrimitive;
import com.google.gson.Gson;
class mytest {
public static void main(String[] args) throws URISyntaxException {
System.out.println("About to run"); // Display the string.
try{
new mytest().run();
} catch(Exception e) {
System.out.println("Error:" + e.getMessage()); // Display the string.
}
}
}
The text was updated successfully, but these errors were encountered: