server

Powershell invoke-webrequest not working

心已入冬 提交于 2019-12-05 18:17:47
I have a Powershell script that is supposed to run an Invoke-WebRequest against a site. I want to use this script with PRTG Network Monitor to ensure that a web server is up and running properly. Currently, the script works running from my local machine as well as running with my domain credentials on the probe server. However, it doesn't run when logged in with the local admin credentials which is what PRTG uses. I've narrowed it down to a single line, Invoke-WebRequest $uri -Method POST -Body $body -TimeoutSec 10 It appears that for whatever reason, when using this account, Invoke-WebRequest

How to make the server backend of a mobile app?

限于喜欢 提交于 2019-12-05 17:08:37
问题 I am an Android developer and I want to make an app which shows users on a map and performs tasks based on their location. The whole model of the app has to run in the server. I need an API which: Receives user location Performs calculations based on the location of the users Sends response to specific users with the results The problem is that I have 0 experience in doing server side programming. Can you please suggest me a way of making the server? I checked the Google Colud Platform and

Repository vs. DAO (again)

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-05 16:33:22
In general this back-story does not matter but just to explain the code below: The server handles users and user groups. User groups are able to "discover" places - at this point in time these places are coming exclusively from the Google Places API. Current Implementation Currently, I have a lot of JpaRepository objects, which I call Repository , in my Service Layer. I am stressing " Repository " because in my proposed solution below, they'd be downgraded to DAOs. However, what I do not like in my current code, and also the reason for my question here, is the amount of repositories one can

java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String android.net.Uri.getScheme()'

狂风中的少年 提交于 2019-12-05 13:21:59
I am Trying To upload image to server from gallery and camera.When i Choose image from gallery to upload to server its Work Perfactly.But when i Select camera captured Image for upload to server Its Crash And Showing the error. java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String android.net.Uri.getScheme()' on a null object reference At OnActivityResult. @Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); if (requestCode == PICK_IMAGE && resultCode == RESULT_OK && null !=

Server 2008 (IIS7) HRESULT: 0x800A03EC

时光总嘲笑我的痴心妄想 提交于 2019-12-05 11:04:02
适用环境:Windows Server 2012 iis8及server2008 iis7 解决办法: 1. 1).通过webconfig中增加模拟,加入管理员权限, <identity impersonate="true" userName="系统管理员" password="系统管理员密码"/> 2).这样就能够启动Application进程,操作EXCEL了,能够新建EXCEL,导出EXCEL,但是还是不能打开服务器端的EXCEL文件 2. 在组件服务,DOCM设置 Microsoft Excel Application的属性, 因为是在64位系统上面操作,组件服务中DOCOM中默认是没有的,因为Microsoft Excel Application是32的DCOM配置,所以通过如下方式解决(参考第三步) 3. 1).开始--〉运行--〉cmd 2)命令提示符下面,输入mmc -32,打开32的控制台 3).文件菜单中,添加删除管理单元--〉组件服务 4).在"DCOM配置"中找到"Microsoft Excel 应用程序",在它上面点击右键,然后点击"属性",弹出"Microsoft Excel 应用程序属性"对话框  5).点击"标识"标签,选择"交互式用户"  6).点击"安全"标签,在"启动和激活权限"上点击"自定义",然后点击对应的"编辑"按钮,在弹出的"安全性

Stopping/starting an application pool and site on a server

谁都会走 提交于 2019-12-05 10:26:51
I would like to write a script and run it from my local PC to stop and start an application pool and site that exists on a server. Value of App Pool and Site - Test Value of server - SERVER1 Any guidance would be much appreciated. Daniel Minnaar Run Command Prompt with Administrative rights, and type the following: C:\Windows\System32\inetsrv\appcmd start apppool /apppool.name:"MYAPPPOOLNAME" or use the stop command. You could save this in a batch file, but it must be executed with higher privileges. For the application pool on a remote server, you could use PsExec : Psexec \\{Computer Name of

nginx的log、upstream和server

孤街浪徒 提交于 2019-12-05 09:22:22
nginx的log、upstream和server 一、log 首先一个log格式化的例子。 #配置格式main的log log_format main '$host $status [$time_local] $remote_addr [$time_local] $request_uri ' '"$http_referer" "$http_user_agent" "$http_x_forwarded_for" ' '$bytes_sent $request_time $sent_http_x_cache_hit'; #使用格式为main的log access_log logs/access.log main; 我们看见nginx的参数都是$xxx的形式出现,只要通过给定的参数,我们可以配置很多东西 $arg_PARAMETER HTTP 请求中某个参数的值, Eg:如/index.php?site=www.ttlsa.com,可以用$arg_site取得www.ttlsa.com这个值. $args HTTP 请求中的完整参数。 Eg:例如,在请求/index.php?width=400&height=200 中,$args表示字符串width=400&height=200. $binary_remote_addr 二进制格式的客户端地址。例如:\x0A\xE0B\x0E

What makes something be a request feature in ASP.NET Core?

百般思念 提交于 2019-12-05 07:58:09
There's one point in ASP.NET Core that I believe I didn't fully understand yet and that is the idea of request features. As explained in the docs : Feature interfaces define specific HTTP features that a given request may support. Servers define collections of features, and the initial set of features supported by that server, but middleware can be used to enhance these features. My initial understanding about this was that request features are all things a server should expose to be used on the application pipeline. That is, behaviors that a server should perform like sending a file. On the

Since Android Lollipop 5.0 I am not able to communicate to server (X509TrustManager) via SSL or TLSv1

淺唱寂寞╮ 提交于 2019-12-05 07:47:27
问题 I hope someone can help me here. Since Android Lollipop 5.0 I am not able to communicate to server (X509TrustManager) via SSL. It seems like the app is entering in a infinity loop trying to establish handshake. Here is my code: SSLContext sc; SSLSocket sslsock; Socket sock; // Constructor RfbProto(String h, int p) throws IOException{ host = h; port = p; TrustManager[] trustAllCerts = new TrustManager[] { new X509TrustManager() { public java.security.cert.X509Certificate[] getAcceptedIssuers()

Why node server has to be restart on file change?

大憨熊 提交于 2019-12-05 07:35:53
Why is it necessary to restart a NodeJS server when there is a file change? Do other servers like Apache, IIS, nginx require this as well or can they restart automatically? You don't say which files you're talking about so I'll mention the issues with a couple different types of files. For Javascript files that make up your Javascript code for your node.js server, node.js is a continuously running server. That means when the server starts up, it parses your Javascript code into memory and then starts executing it. That server process stays running until you stop it. Because node.js is a