Synchronize externally changed database with feature service in Portal

5261
9
03-24-2016 03:06 AM
MiguelGonzález
New Contributor III

Hello everbody,

I am stuck with synchronizing a hosted feature service in my organization's Portal.

Framework:

ArcGIS Server, Portal and Oracle-sde are placed on the same virtual server. AGS ist registered as hosted server on Portal, sde is registered as managed database on AGS. AGS and Portal are updated to 10.4.

I am able to publish a feature service as hosted service based on a feature class from sde, integrate this one into a web map and build a web app based on the web map.

Now, I want to change the featureclass within the database externally (load more / delete certain features from script, manipulate database columns with sql, ...) AND have these changes directly synchronized with my feature service and, thus, see the effects of my database changes immediatly in the web app without explicitly overriding the feature service from my mxd.

Is this possible?

The feature class has Global-IDs and versioning is enabled. In my current service configuration only Feature Access (Query, Update and Sync are activated) is enabled.

Any ideas?

Cheers,

Simon

0 Kudos
9 Replies
PaulDavidson1
Occasional Contributor III

I'm watching this with interest.

I would have to say that what you're trying to do is not possible.

If you were changing only the data in the database then I think you might have a shot at it.

But you're talking about making what sound like major schema changes.

How is the mxd/feature service going to know that your schema has undergone changes.

I believe Synch has to do with synching data, not schema changes.

I'm hoping someone proves me wrong but I'll be very surprised if you can pull this off without having to update your mxd and republish your Feature Service.

Best of luck.

0 Kudos
NeilAyres
MVP Alum

Exactly. Adding, moving, deleting data - No problem. The web map / app will reflect the changes.

But changing the schema... No. You will have to re build the service from scratch.

MiguelGonzález
New Contributor III

Hi Paul, hi Neil,

thanks a lot to your comments! (Sorry for being late to answer due to overdue vacation)

Actually, I do not want to change the schema of the data, but only add or change some data points. But if I make some entris to the attribute table or add another point externally, these changes do not appear in the webmap automatically (at the moment I am adding points with ArcMap to the feaure class). Only if I overwrite the existing feature service from ArcMap, the changes are reflected in the WebMap.

If I get you right, this should - in principle - do without explicitly overwrite the service...

Still, I am afraid, I missed some (or even one) important tick in my configuration. Do you have any idea what I could have done wrong?

Thank you!

0 Kudos
NeilAyres
MVP Alum

Hmmm,

What data are you editing and how? Is the data versioned? And reconciled back to default.

0 Kudos
MiguelGonzález
New Contributor III

Thanks Neil!

It's a simple feature class (points):

MyTablespace@MySDE >> MyFeatureDataset >> MyFeatureClass

I did register the feature dataset as versioned to be able to edit the features, but I did not create any version in the first place. Thus, there were no versions to be reconciled.

I played around this morning with creating a version, publish this one, reconcile everything to default, publish the default version again, adding points in every step... no success at all.

Still, I need to override the whole feature service to have the newly added points reflected in the webmap.

Hmpf...

0 Kudos
NeilAyres
MVP Alum

That doesn't make sense.

Just published a service this morn which has a bunch of polygons with a table joined to it.

The table is filtered on a column, example "Active" = "Yes".

The correct polys appear in the portal web map.

Back out in the db side, if you edit the table, the portal web map changes a few seconds later.

Magic.

So, back to your problem.

Are you sure that your service is pointing to the correct schema ie the owner of the data ?

We always have a data loader user "LDR", so the features tables appear like "DBName.LDR.MyFeature".

If you add these same features using a different user, I am not sure the service will work properly.

0 Kudos
PaulDavidson1
Occasional Contributor III

Do you need to have the Feature Service setup for Synching?

I don't know, we're just starting to work on this type of process but maybe that's a requirement for "live" updates?

I also seem to recall something about setting a refresh time?

But I could be confusing that with something else Esri related.

0 Kudos
NeilAyres
MVP Alum

Once the data source is registered with the server I don't think there is anything else required.

As I said, just check which view of the data is in the mxd which publishes the service.

MiguelGonzález
New Contributor III

Hi again - with delay (sorry for that! Just busy holding my head above water...),

seems we are getting to the core, lately: I was wondering if I actually had a "datastore". The SDE seems not to be interpreted as ESRI datastore even though it was registered as managed database.

Now, in the course of redirecting everything I stumbled at another problem: Obviously by magic some strange policies suddenly prevent that I may use UNC-paths on my server (these policies just appeared - strange things happen). Thus, I am in friendly conversation with some admins to rearrange the policy settings and will keep you posted as soon as I may fully access my server again...

Thank you again for your support!

0 Kudos