# Missing properties for 'currentStatus'

**URL:** <https://community.stardog.com/t/missing-properties-for-currentstatus/675>\
**Category:** Bug\
**Created:** [November 6, 2017, 4:25pm UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675 "2017-11-06T16:25:58Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![rnavarropiris](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/rnavarropiris/32/44_2.png) [@rnavarropiris](https://community.stardog.com/u/rnavarropiris)\
**Post date:** [November 6, 2017, 4:25pm UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675/1 "2017-11-06T16:25:58Z")

</div>

# Problem description

Database properties provided on creation are not shown using the [currentStatus API](http://www.stardog.com/docs/java/snarl/com/complexible/stardog/api/admin/adminconnection#currentStatus-boolean-)

# Reproduction

Using Stardog 5.0.5, the database was created with the following command:

```bash
stardog-admin db create -n stardog -v -o versioning.enabled=true preserve.bnode.ids=false

```

The following Java instruction:

```java
System.out.println(connection.admin().currentStatus(true));

```

provides this output:

```auto
{  
   dbms.home=/data,
   dbms.mem.mapped.max=120795955,
   databases.stardog.queries.speed= {  
      mean_rate=0.0,
      max=0.0,
      count=0,
      p50=0.0,
      p95=0.0,
      p98=0.0,
      p75=0.0,
      m1_rate=0.0,
      rate_units=calls/second,
      p99=0.0,
      min=0.0,
      duration_units=seconds,
      mean=0.0,
      p999=0.0,
      stddev=0.0,
      m15_rate=0.0,
      m5_rate=0.0
   },
   dbms.mem.direct.used=26054687,
   dbms.query.timeout=5m,
   dbms.memory.management=NATIVE,
   dbms.query.pp.contexts=false,
   databases.system.planCache.size=3,
   dbms.logging.connection.events.enabled=true,
   system.uptime=28156,
   dbms.mem.system.rss=578326528,
   dbms.memory.monitor.report.threshold=0.9,
   dbms.mem.mapped.used=25165824,
   dbms.upgrade.automatic=false,
   dbms.memory.heap.reserve=,
   databases.system.planCache.ratio=0.25,
   dbms.security.disabled=false,
   dbms.mem.direct.buffer.used=126976,
   dbms.strict.parsing=true,
   dbms.password.length.min=4,
   dbms.rotate.old.tx.logs=false,
   databases.stardog.txns.speed= {  
      mean_rate=0.0,
      max=0.0,
      count=0,
      p50=0.0,
      p95=0.0,
      p98=0.0,
      p75=0.0,
      m1_rate=0.0,
      rate_units=calls/second,
      p99=0.0,
      min=0.0,
      duration_units=seconds,
      mean=0.0,
      p999=0.0,
      stddev=0.0,
      m15_rate=0.0,
      m5_rate=0.0
   },
   dbms.logging.connection.startend.events.enabled=true,
   dbms.memory.mode=DEFAULT,
   dbms.type=Community,
   dbms.mem.heap.max=1029177344,
   dbms.data.dir=/tmp,
   databases.stardog.planCache.size=1,
   dbms.metrics.enabled=true,
   dbms.query.timeout.override.enabled=true,
   dbms.mem.direct.pool.used=0,
   databases.stardog.planCache.ratio=0.0,
   dbms.server.port=5820,
   dbms.pack.enabled=false,
   databases.stardog.queries.running=0,
   system.os=Linux 4.4.89-boot2docker, Java 1.8.0_151,
   dbms.page.cache.ratio=0.49933598937583,
   dbms.version=5.0.5,
   dbms.security.named.graphs=true,
   dbms.spilling.dir=.spilling,
   dbms.security.named.graphs.empty.allows.access=false,
   databases.stardog.openConnections=0,
   system.cpu.usage=0.1281583631184142,
   dbms.memory.managed.direct=,
   dbms.security.realms=stardog,
   dbms.backup.dir=.backup,
   dbms.memory.direct.reserve=,
   dbms.mem.heap.used=34144008,
   dbms.query.all.graphs=true,
   dbms.mem.heap.pool.used=0,
   dbms.page.cache.weight=9232,
   dbms.page.cache.size=2,
   dbms.export.dir=.exports,
   system.arch=amd64,
   dbms.mem.direct.max=1073741824,
   dbms.mem.direct.buffer.max=281857228,
   dbms.cors.allowed.origins= [],
   dbms.mem.direct.pool.max=402653184,
   dbms.memory.managed.heap=,
   dbms.memory.monitor.interval=600000,
   databases.stardog.txns.openTransactions=0,
   dbms.id=47a25594-2bb2-4e18-b05c-ccdadcdd529a,
   dbms.mem.heap.pool.max=0,
   dbms.database.connection.timeout=1h
}

```

Neither `versioning.enabled` nor `preserve.bnode.ids` can be found in the provided map.

Is this a bug or intended behaviour? If so, is there another API to get this information?

Thanks in advance!

Ruben

---

<div class="post-metadata">

**Author:** ![stephen](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/stephen/32/27_2.png) [@stephen](https://community.stardog.com/u/stephen)\
**Post date:** [November 7, 2017, 10:19pm UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675/2 "2017-11-07T22:19:09Z")

</div>

Hi Ruben,

Those values are actually part of the metadata for a given database, which is retrieved via `AdminConnection.get()`. In your case you could do the following:

```java
List<ConfigProperty<Boolean>> aPropsIWant = Arrays.asList(
        DatabaseOptions.PRESERVE_BNODE_IDS,
        VersioningOptions.ENABLED
    );
System.out.println(aConn.admin().get("stardog", aPropsIWant));

```

---

<div class="post-metadata">

**Author:** ![rnavarropiris](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/rnavarropiris/32/44_2.png) [@rnavarropiris](https://community.stardog.com/u/rnavarropiris)\
**Post date:** [November 9, 2017, 10:27am UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675/3 "2017-11-09T10:27:41Z")

</div>

Hi Stephen!

I just tested it and got this output:

```auto
{preserve.bnode.ids=false}

```

Seems like the `VersioningOptions.ENABLED` property was not retreived…

Versioning however is active, I sent updates and the versioning history is consistent.

---

<div class="post-metadata">

**Author:** ![rnavarropiris](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/rnavarropiris/32/44_2.png) [@rnavarropiris](https://community.stardog.com/u/rnavarropiris)\
**Post date:** [December 15, 2017, 2:40pm UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675/4 "2017-12-15T14:40:45Z")

</div>

Hi Stephen!

Any words on when/if this issue is getting addressed to?

---

<div class="post-metadata">

**Author:** ![stephen](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/stephen/32/27_2.png) [@stephen](https://community.stardog.com/u/stephen)\
**Post date:** [December 15, 2017, 7:53pm UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675/5 "2017-12-15T19:53:14Z")

</div>

Hi Ruben,

Sorry about the lack of response on this thread! After some more research I discovered that the Stardog server (5.1.0, at least) is returning the `versioning.enabled` piece of metadata, but the client is ignoring it. I found that if you simply add the line `MetaProperties.register(VersioningOptions.class);` before your `aConn.admin().get()` call it will actually include those options in its output

---

<div class="post-metadata">

**Author:** ![rnavarropiris](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/rnavarropiris/32/44_2.png) [@rnavarropiris](https://community.stardog.com/u/rnavarropiris)\
**Post date:** [January 8, 2018, 3:12pm UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675/6 "2018-01-08T15:12:03Z")

</div>

Hi Stephen!

The workaround works. However, this does not affect the output of `connection.admin().currentStatus(true)`.  
Will this issue be fixed for the next release? Or further down the line?

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![stephen](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/stephen/32/27_2.png) [@stephen](https://community.stardog.com/u/stephen)\
**Post date:** [January 10, 2018, 7:06pm UTC](https://community.stardog.com/t/missing-properties-for-currentstatus/675/7 "2018-01-10T19:06:53Z")

</div>

Ruben,

`connection.admin().currentStatus(true)` returns the _server_ options, while `versioning.enabled` and `preserve.bnode.ids` are _database_-level metadata and therefore can only be retrieved from the `admin().get` method.
