Configure Persistence
Use the REST API endpoint below to configure persistence. A GET request
to the CreateForm URL retrieves both the default parameters and the create
URL. Send a POST request to the create
URL to create the child
MBean.
URL Syntax
For the GET:
/management/weblogic/latest/edit/customResources/sipserver/customResource/persistenceCreateForm
For the POST or DELETE:
/management/weblogic/latest/edit/customResources/sipserver/customResource/persistence
HTTP Methods
- GET
- POST
- DELETE
Parameters
Table 17-12 URL Parameters
Names | Description |
---|---|
links | Set to none if you want to remove
the links from the response. Set to an enumerated list of the links
to return. For
example:
|
fields | Set to an enumerated list of the fields to return.
For
example:
|
Examples
Example 17-37 Get the Persistence CreateForm
curl -u weblogic:<password> \
'http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistenceCreateForm'
Example response:
{
"links": [
{
"rel": "parent",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource"
},
{
"rel": "self",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistenceCreateForm"
},
{
"rel": "canonical",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistenceCreateForm"
},
{
"rel": "create",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistence"
}
],
"geoRemoteT3Url": null,
"dbEnabled": false,
"jmsSendAsIdentity": null,
"geoEnabled": false,
"defaultHandling": null
}
Example 17-38 Create a custom resource
Send a POST request to create the element.
curl -X POST \
-d@config.xml \
-u weblogic:<password> \
-H 'X-Requested-By: MyClient' \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
'http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistence'
The contents of config.json:
{
"geoRemoteT3Url": null,
"dbEnabled": false,
"jmsSendAsIdentity": null,
"geoEnabled": false,
"defaultHandling": "all"
}
Example 17-39 Retrieve the created resource
After the resource has been created, send a GET request to view its links and attributes.
curl -u weblogic:<password> \
'http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistence'
An example response:
{
"links": [
{
"rel": "parent",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource"
},
{
"rel": "self",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistence"
},
{
"rel": "canonical",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistence"
},
{
"rel": "create-form",
"href": "http://10.0.0.1:7001/management/weblogic/latest/edit/customResources/sipserver/customResource/persistenceCreateForm"
}
],
"identity": [
"customResources",
"sipserver",
"customResource",
"persistence"
],
"geoRemoteT3Url": null,
"dbEnabled": false,
"jmsSendAsIdentity": null,
"geoEnabled": false,
"defaultHandling": "all"
}