Hi, I’m trying out geofence REST API to post new rule, I’m able to do so and I 
can also see the rule in geofence data rule , but the layer attributes are not 
getting added.

URL : localhost:8080/geoserver/rest/geofence/rules
Method: POST
Body  : {
    "Rule": {
            "priority": 1,
            "roleName": "poi",
            "addressRange": null,
            "workspace": "sf",
            "layer": "roads",
            "service": null,
            "request": null,
            "access": "ALLOW",
            "limits": null,
            "layerDetails": {
                "layerType": "VECTOR",
                "defaultStyle": null,
                "cqlFilterRead": "cat = 4",
                "cqlFilterWrite": "cat = 4",
                "allowedArea": null,
                "catalogMode": null,
                "allowedStyles": [],
                "attributes": [
                    {
                        "name": "the_geom",
                        "dataType": "org.locationtech.jts.geom.Point",
                        "accessType": "READWRITE"
                    },
                    {
                        "name": "cat",
                        "dataType": "java.lang.Integer",
                        "accessType": "READWRITE"
                    },
                    {
                        "name": "label",
                        "dataType": "java.lang.String",
                        "accessType": "NONE"
                    }
                ]
            }

    }
}

Rule is created but layer attributes are missing

Thank you,
Krishna G. Lodha
http://krishnaglodha.com
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to