I think I found the real problem. It was connected to 
MultipleActiveResultSets=true. 
When I commented some code that was generating "the multiple batches on a 
single connection situation" on starting of the app, the deployment to 
Appengine got successful.
Does Google Cloud SqlServer have problem with it?   

On Monday, October 5, 2020 at 9:21:02 PM UTC+2 George (Cloud Platform 
Support) wrote:

> You mention a proxy? Is your local machine behind a proxy? That would be 
> consistent with the error you keep receiving. Does the situation change if 
> you access App Engine without a proxy, from another network?
>
> It may be worthwhile having a look at Configuring Cloud SDK for use 
> behind a proxy/firewall <https://cloud.google.com/sdk/docs/proxy-settings>
> . 
>
> On Monday, 05 October 2020 at 13:55:34 UTC-4 [email protected] wrote:
>
>> Hi
>> I have this problem when trying to deploy to AppEngine. On local machine 
>> using proxy it works fine.
>>
>> Microsoft.EntityFrameworkCore.Database.Connection[20004]
>> A network-related or instance-specific error occurred while establishing 
>> a connection to SQL Server. The server was not found or was not accessible. 
>> Verify that the instance name is correct and that SQL Server is configured 
>> to allow remote connections. (provider: TCP Provider, error: 40 - Could not 
>> open a connection to SQL Server)
>> An error occurred using the connection to database 'dblivtron' on server 
>> 'cloudsql'.
>>
>> My config:
>> Appengine Flexible API = enabled
>> Cloud SQL Admin API = enabled
>> Instance public address = enabled
>>
>> Instance Connection Name: 
>> livtron-testproject:europe-west1:livtrondbinstance
>> Data base: dblivtron
>>
>> My app.yaml:
>> runtime: custom
>> env: flex
>> manual_scaling:
>>   instances: 1
>> resources:
>>   cpu: 1
>>   memory_gb: 0.5
>>   disk_size_gb: 10
>> beta_settings:
>>   cloud_sql_instances: 
>> livtron-testproject:europe-west1:livtrondbinstance=tcp:3306
>>   
>> My connection string in appsettings.json  
>>   "ConnectionStrings": {
>>     "DefaultConnection": "Server=cloudsql;Database=dblivtron;User 
>> Id=sqlserver;Password=#####;MultipleActiveResultSets=true;Encrypt=false;Pooling=true;"
>>   },
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/2c056e90-6c61-485a-9169-40280809e0bbn%40googlegroups.com.

Reply via email to