question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Issue with custom realm directory setup

See original GitHub issue

I tried to set custom directory with realm configuration in android. While accessing the path, its simply returning default canonical path.

Is my data saved in custom path or in default path? Please some one help, how to setup custom path to save data?

Expected Results

To know where my data saved

Actual Results

Need to save my data in custom path

Code Sample

Realm.init(this); String path = getFilesDir().getPath(); File realmFile = new File(path); RealmConfiguration realmConfiguration = new RealmConfiguration .Builder() .directory(realmFile) .name(“appname.realm”) .deleteRealmIfMigrationNeeded() .build(); Realm.setDefaultConfiguration(realmConfiguration); Logger.d(“Realm Migration Config Success”, Realm.getDefaultConfiguration().getPath());//Error returning path

Your code here. Bigger samples should ideally be as separate Android Studio project, in gists/repositories or privately at help@realm.io)


#### Version of Realm and tooling
Realm version(s): 4.2.0

Realm sync feature enabled: yes/no

Android Studio version: 3.0

Which Android version and device: ?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
saravanakumarimpigercommented, Nov 28, 2017

Issue seems to be due to the changes happening as part of the MDM wrapping process. We are checking this further and will post a note once we have some findings.

0reactions
beeendercommented, Nov 28, 2017

@saravanakumarimpiger Any updates for this issue? Did you get any response from MDM?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Reconfiguring the WebSphere user realm type - IBM
From the Type of LDAP server list, select your LDAP server. For example, IBM Tivoli Directory Server. Provide the LDAP configuration property values...
Read more >
Customizing the Default Security Configuration
Expand the Security-->Realms nodes. · Click the name of the realm you are configuring (for example, TestRealm). · Expand the Providers-->Authentication Providers ...
Read more >
error while getting Active Directory Realm with Glassfish 3.1
I need to know what that error is it problem in configuration at glassfish or what ? java · glassfish · ldap ·...
Read more >
Firepower Management Center Device Configuration Guide, 7.1
This happens because system assigns a unique ID to every user and group in each realm; therefore, the system cannot definitively identify any ......
Read more >
Configure a cross-realm trust with an Active Directory domain
The only requirement is that the cluster-dedicated KDC can access the Active Directory domain controller. Create a custom route table, add a route...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found